Home > Back-end >  Each master, please give little brother a train of thought, thanks a lot...
Each master, please give little brother a train of thought, thanks a lot...

Time:10-07

Masters, you ask a question, is there a SpringBoot development platform for the Web project, the platform in the project not only service the Java code, and js, HTML, and so on, leading to the platform project packaged into a jar package as basic components, and other projects can introduce the jars for integrated development platform, could you tell me how to achieve this? Trouble masters to you a little, if any instance is best, thank you very much!
I have three questions:
1, if packed into a jar package integrated to other projects, service in the jars, logic the spring bean have to think of some way to put in the spring of the new project?
2, the platform web project packaged into a jar package, including HTML pages, js code can run in the new project?
3, platform web project application. Some of the properties platform using the configuration parameters, this package to the jar package, and the application of the new project. The properties of conflict?

CodePudding user response:

Have difficulty, SpringBoot mainly deployed as a single web application (webapp), or would you consider for micro service

Directly open the most worry, let others do the secondary development based on your code

CodePudding user response:

Just integration once, and we are into war bag, jar package js, HTML and other static resources can use;
Using Maven WAR Plugin & lt; Overlays> Name, integration, whether can be configured to ignore the bean in the package, but it is ok to add a scan path;

But such debugging very troublesome, but led to do didn't also the way

CodePudding user response:

Since it is packaged into components for others, why js, HTML? With maven directly into jars in pom reference line, the application, the properties do not conflict but multiple log files is expected to conflict,

CodePudding user response:

refer to the second floor dkwuxiang response:
just once, we are into war bag, jar package js, HTML and other static resources can use;
Using Maven WAR Plugin & lt; Overlays> Name, integration, whether can be configured to ignore the bean in the package, but it is ok to add a scan path;

But such debugging very troublesome, but led to do didn't also the way


There are a few problems under the consultation, the problem is a little bit more, thank you very much for your help:
1, before the merge, put to merge the war package also in the warehouse?
2, merge springboot projects and to merge springboot project name, there will be some such as application, properties, application - dev. The properties, etc., you can set the file does not cover the same name? If it is not covered, with the content of the command file will be automatically merged together?
3, to merge in the project has a lot of a lot of beans, excuse me these beans are you through what way to host in the spring container to merge project? If I can look at the sample code, thank you very much!
4, the two after the merge of the project, if merge project calls to merge in the bean method, hardly breakpoint single-step debugging? What do you mean by debugging very troublesome is mainly refers to what?

CodePudding user response:

refer to the second floor dkwuxiang response:
just once, we are into war bag, jar package js, HTML and other static resources can use;
Using Maven WAR Plugin & lt; Overlays> Name, integration, whether can be configured to ignore the bean in the package, but it is ok to add a scan path;

But such debugging very troublesome, but led to do didn't also the way


There are a few problems under the consultation, the problem is a little bit more, thank you very much for your help:
1, before the merge, put to merge the war package also in the warehouse?
2, merge springboot projects and to merge springboot project name, there will be some such as application, properties, application - dev. The properties, etc., you can set the file does not cover the same name? If it is not covered, with the content of the command file will be automatically merged together?
3, to merge in the project has a lot of a lot of beans, excuse me these beans are you through what way to host in the spring container to merge project? If I can look at the sample code, thank you very much!
4, the two after the merge of the project, if merge project calls to merge in the bean method, hardly breakpoint single-step debugging? What do you mean by debugging very troublesome is mainly refers to what?

CodePudding user response:

reference qq_21985711 reply: 3/f
since be packaged into components for others, why js, HTML? Use maven directly into jars in pom reference line, the application, the properties do not conflict but multiple log files is expected to conflict,


Sorry, hair wrong, is that our platform is the online program, batch process, management software, etc, each program is a separate project engineering, leading to this a few projects are independent, as components, behind this platform have change, we just update the component versions, and sent to rely on the application can be used, also to say, of the two is the background code, no page, js file, better integration,
But management application, logic, both the background and the front desk page, the leadership let this also as components, I didn't think a good way,,,

CodePudding user response:

Background code can be blended into the jar, provide maven coordinates for other projects, but HTML, js best writing on the use of engineering

CodePudding user response:

references on 5 floor response:
Quote: refer to the second floor dkwuxiang response:

Just integration once, and we are into war bag, jar package js, HTML and other static resources can use;
Using Maven WAR Plugin & lt; Overlays> Name, integration, whether can be configured to ignore the bean in the package, but it is ok to add a scan path;

But such debugging very troublesome, but led to do didn't also the way


There are a few problems under the consultation, the problem is a little bit more, thank you very much for your help:
1, before the merge, put to merge the war package also in the warehouse?
2, merge springboot projects and to merge springboot project name, there will be some such as application, properties, application - dev. The properties, etc., you can set the file does not cover the same name? If it is not covered, with the content of the command file will be automatically merged together?
3, to merge in the project has a lot of a lot of beans, excuse me these beans are you through what way to host in the spring container to merge project? If I can look at the sample code, thank you very much!
4, the two after the merge of the project, if merge project calls to merge in the bean method, hardly breakpoint single-step debugging? What do you mean by debugging very troublesome is mainly refers to what?



1. Yes;
Name will cover
2.3. Such as the configuration class annotation @ ComponentScan scanning to merge project package
4. Mainly refers to the main program debugging cannot access components page, I am alone will additional qualifications to the sub-project of the resource path changed to debugging (after packaging no this problem)

CodePudding user response:

1, if packed into a jar package integrated to other projects, service in the jars, logic the spring bean have to think of some way to put in the spring of the new project?
Scanning, and write in their project didn't difference between
2, the platform web project packaged into a jar package, including HTML pages, js code can run in the new project?
Static resource is written in the resources \ meta-inf \ resources, this is very simple, under webconfig specify static resource directory, understand WebMvcConfigurer
3, platform web project application. Some of the properties platform using the configuration parameters, this package to the jar package, and the application of the new project. The properties of conflict?
Since platform web provide jars, there should be no more then application. The properties, configuration files are provided by the dependent jar service, or have you

CodePudding user response:

refer to the eighth floor dkwuxiang response:
Quote: reference on 5 floor response:

Quote: refer to the second floor dkwuxiang response:

Just integration once, and we are into war bag, jar package js, HTML and other static resources can use;
Using Maven WAR Plugin & lt; Overlays> Name, integration, whether can be configured to ignore the bean in the package, but it is ok to add a scan path;

But such debugging very troublesome, but led to do didn't also the way


There are a few problems under the consultation, the problem is a little bit more, thank you very much for your help:
1, before the merge, put to merge the war package also in the warehouse?
2, merge springboot projects and to merge springboot project name, there will be some such as application, properties, application - dev. The properties, etc., you can set the file does not cover the same name? If it is not covered, with the content of the command file will be automatically merged together?
nullnullnullnullnullnullnullnullnullnullnullnullnullnullnull
  • Related