Which design pattern is suitable illustrated problem below? [closed]How to study design patterns?Does functional programming replace GoF design patterns?What is the difference between Builder Design pattern and Factory Design pattern?Efficiency of Java “Double Brace Initialization”?C++ Singleton design patternExamples of GoF Design Patterns in Java's core librariesDesign Patterns web based applicationsWhich design patterns are used on Android?Java design patternLooking for a Design Pattern or Library
Why is this weapon searching for a new owner?
Writing a love interest for my hero
Bash, import output from command as command
What exactly is a marshrutka (маршрутка)?
How can I locate a missing person abroad?
How do email clients "send later" without storing a password?
Should you only use colons and periods in dialogues?
What was redacted in the Yellowhammer report? (Point 15)
Should I leave the first authorship of our paper to the student who did the project whereas I solved it?
Is there any way to land a rover on the Moon without using any thrusters?
Write a function that returns an iterable object of all valid points 4-directionally adjacent to (x, y)
How do I say "quirky" in German without sounding derogatory?
Which is the current decimal separator?
Can I toggle Do Not Disturb on/off on my Mac as easily as I can on my iPhone?
What is my breathable atmosphere composed of?
Can I fix my boots by gluing the soles back on?
Double it your way
Sol Ⅲ = Earth: What is the origin of this planetary naming scheme?
Diffraction of a wave passing through double slits
Does my opponent need to prove his creature has morph?
The Planck constant for mathematicians
A simple problem about Rule
Where to disclose a zero day vulnerability
What is the mathematical notation for rounding a given number to the nearest integer?
Which design pattern is suitable illustrated problem below? [closed]
How to study design patterns?Does functional programming replace GoF design patterns?What is the difference between Builder Design pattern and Factory Design pattern?Efficiency of Java “Double Brace Initialization”?C++ Singleton design patternExamples of GoF Design Patterns in Java's core librariesDesign Patterns web based applicationsWhich design patterns are used on Android?Java design patternLooking for a Design Pattern or Library
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;
I am developing a project in spring boot. There are common required steps will be used by all classes in development phase. For example to make connectivity through jdbc from java program to database the first step is load the jdbc driver, second step is create connection object and so on.
The problem is design pattern of my project should restrict the new developer of my project to write new classes in such a way that no requires steps would skip in such condition which design pattern should i use??
java design-patterns spring-boot-actuator
closed as too broad by Lino, Seelenvirtuose, piet.t, Eldelshell, Wai Ha Lee Mar 28 at 10:47
Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
add a comment
|
I am developing a project in spring boot. There are common required steps will be used by all classes in development phase. For example to make connectivity through jdbc from java program to database the first step is load the jdbc driver, second step is create connection object and so on.
The problem is design pattern of my project should restrict the new developer of my project to write new classes in such a way that no requires steps would skip in such condition which design pattern should i use??
java design-patterns spring-boot-actuator
closed as too broad by Lino, Seelenvirtuose, piet.t, Eldelshell, Wai Ha Lee Mar 28 at 10:47
Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
add a comment
|
I am developing a project in spring boot. There are common required steps will be used by all classes in development phase. For example to make connectivity through jdbc from java program to database the first step is load the jdbc driver, second step is create connection object and so on.
The problem is design pattern of my project should restrict the new developer of my project to write new classes in such a way that no requires steps would skip in such condition which design pattern should i use??
java design-patterns spring-boot-actuator
I am developing a project in spring boot. There are common required steps will be used by all classes in development phase. For example to make connectivity through jdbc from java program to database the first step is load the jdbc driver, second step is create connection object and so on.
The problem is design pattern of my project should restrict the new developer of my project to write new classes in such a way that no requires steps would skip in such condition which design pattern should i use??
java design-patterns spring-boot-actuator
java design-patterns spring-boot-actuator
asked Mar 28 at 10:20
Sanyam JainSanyam Jain
32 bronze badges
32 bronze badges
closed as too broad by Lino, Seelenvirtuose, piet.t, Eldelshell, Wai Ha Lee Mar 28 at 10:47
Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
closed as too broad by Lino, Seelenvirtuose, piet.t, Eldelshell, Wai Ha Lee Mar 28 at 10:47
Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
closed as too broad by Lino, Seelenvirtuose, piet.t, Eldelshell, Wai Ha Lee Mar 28 at 10:47
Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
add a comment
|
add a comment
|
2 Answers
2
active
oldest
votes
Am not sure about design pattern ,but i suggest to have abstract class /interface with all required methods(or steps as told by you to load the jdbc driver, create connection object and so on) and all new classed should extend or implement above abstract class or interface
add a comment
|
I don't think you need a design pattern for this at all. If you are building your project in Spring Boot, just create a data source once and inject it where it is needed.
Sure, Spring might use the Singleton pattern under the covers to make it happen, but that's not relevant to your problem - the framework solves it for you.
Please add a comment if you downvote an answer. I'd like to understand what's wrong with using Spring to do something that Spring is good at.
– Riaan Nel
Mar 28 at 11:30
add a comment
|
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
Am not sure about design pattern ,but i suggest to have abstract class /interface with all required methods(or steps as told by you to load the jdbc driver, create connection object and so on) and all new classed should extend or implement above abstract class or interface
add a comment
|
Am not sure about design pattern ,but i suggest to have abstract class /interface with all required methods(or steps as told by you to load the jdbc driver, create connection object and so on) and all new classed should extend or implement above abstract class or interface
add a comment
|
Am not sure about design pattern ,but i suggest to have abstract class /interface with all required methods(or steps as told by you to load the jdbc driver, create connection object and so on) and all new classed should extend or implement above abstract class or interface
Am not sure about design pattern ,but i suggest to have abstract class /interface with all required methods(or steps as told by you to load the jdbc driver, create connection object and so on) and all new classed should extend or implement above abstract class or interface
answered Mar 28 at 10:31
GANESH A SGANESH A S
311 bronze badge
311 bronze badge
add a comment
|
add a comment
|
I don't think you need a design pattern for this at all. If you are building your project in Spring Boot, just create a data source once and inject it where it is needed.
Sure, Spring might use the Singleton pattern under the covers to make it happen, but that's not relevant to your problem - the framework solves it for you.
Please add a comment if you downvote an answer. I'd like to understand what's wrong with using Spring to do something that Spring is good at.
– Riaan Nel
Mar 28 at 11:30
add a comment
|
I don't think you need a design pattern for this at all. If you are building your project in Spring Boot, just create a data source once and inject it where it is needed.
Sure, Spring might use the Singleton pattern under the covers to make it happen, but that's not relevant to your problem - the framework solves it for you.
Please add a comment if you downvote an answer. I'd like to understand what's wrong with using Spring to do something that Spring is good at.
– Riaan Nel
Mar 28 at 11:30
add a comment
|
I don't think you need a design pattern for this at all. If you are building your project in Spring Boot, just create a data source once and inject it where it is needed.
Sure, Spring might use the Singleton pattern under the covers to make it happen, but that's not relevant to your problem - the framework solves it for you.
I don't think you need a design pattern for this at all. If you are building your project in Spring Boot, just create a data source once and inject it where it is needed.
Sure, Spring might use the Singleton pattern under the covers to make it happen, but that's not relevant to your problem - the framework solves it for you.
answered Mar 28 at 10:28
Riaan NelRiaan Nel
1,4403 silver badges13 bronze badges
1,4403 silver badges13 bronze badges
Please add a comment if you downvote an answer. I'd like to understand what's wrong with using Spring to do something that Spring is good at.
– Riaan Nel
Mar 28 at 11:30
add a comment
|
Please add a comment if you downvote an answer. I'd like to understand what's wrong with using Spring to do something that Spring is good at.
– Riaan Nel
Mar 28 at 11:30
Please add a comment if you downvote an answer. I'd like to understand what's wrong with using Spring to do something that Spring is good at.
– Riaan Nel
Mar 28 at 11:30
Please add a comment if you downvote an answer. I'd like to understand what's wrong with using Spring to do something that Spring is good at.
– Riaan Nel
Mar 28 at 11:30
add a comment
|