mirror of https://github.com/elunez/eladmin
benchmark for monolithic vs modular vs microServices
parent
5af1fc2f0b
commit
05d845c6f9
|
@ -32,9 +32,7 @@ import org.springframework.boot.actuate.endpoint.web.annotation.ControllerEndpoi
|
|||
import org.springframework.boot.actuate.endpoint.web.annotation.ServletEndpointsSupplier;
|
||||
import org.springframework.boot.actuate.endpoint.web.servlet.WebMvcEndpointHandlerMapping;
|
||||
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||
import org.springframework.boot.builder.SpringApplicationBuilder;
|
||||
import org.springframework.boot.context.ApplicationPidFileWriter;
|
||||
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.core.env.Environment;
|
||||
import org.springframework.data.jpa.repository.config.EnableJpaAuditing;
|
||||
|
@ -42,7 +40,6 @@ import org.springframework.scheduling.annotation.EnableAsync;
|
|||
import org.springframework.transaction.annotation.EnableTransactionManagement;
|
||||
import org.springframework.util.StringUtils;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.web.servlet.config.annotation.EnableWebMvc;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
|
@ -60,7 +57,7 @@ import java.util.List;
|
|||
@SpringBootApplication
|
||||
@EnableTransactionManagement
|
||||
@EnableJpaAuditing(auditorAwareRef = "auditorAware")
|
||||
public class BaseAppRun extends SpringBootServletInitializer {
|
||||
public class BaseAppRun {
|
||||
|
||||
public static void main(String[] args) {
|
||||
SpringApplication springApplication = new SpringApplication(BaseAppRun.class);
|
||||
|
@ -116,8 +113,4 @@ public class BaseAppRun extends SpringBootServletInitializer {
|
|||
ManagementPortType.get(environment).equals(ManagementPortType.DIFFERENT));
|
||||
}
|
||||
|
||||
@Override
|
||||
protected SpringApplicationBuilder configure(SpringApplicationBuilder builder) {
|
||||
return builder.sources(BaseAppRun.class);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -63,4 +63,4 @@ code:
|
|||
|
||||
#密码加密传输,前端公钥加密,后端私钥解密
|
||||
rsa:
|
||||
private_key: MIIBUwIBADANBgkqhkiG9w0BAQEFAASCAT0wggE5AgEAAkEA0vfvyTdGJkdbHkB8mp0f3FE0GYP3AYPaJF7jUd1M0XxFSE2ceK3k2kw20YvQ09NJKk+OMjWQl9WitG9pB6tSCQIDAQABAkA2SimBrWC2/wvauBuYqjCFwLvYiRYqZKThUS3MZlebXJiLB+Ue/gUifAAKIg1avttUZsHBHrop4qfJCwAI0+YRAiEA+W3NK/RaXtnRqmoUUkb59zsZUBLpvZgQPfj1MhyHDz0CIQDYhsAhPJ3mgS64NbUZmGWuuNKp5coY2GIj/zYDMJp6vQIgUueLFXv/eZ1ekgz2Oi67MNCk5jeTF2BurZqNLR3MSmUCIFT3Q6uHMtsB9Eha4u7hS31tj1UWE+D+ADzp59MGnoftAiBeHT7gDMuqeJHPL4b+kC+gzV4FGTfhR9q3tTbklZkD2A==
|
||||
private_key: MIIBUwIBADANBgkqhkiG9w0BAQEFAASCAT0wggE5AgEAAkEA0vfvyTdGJkdbHkB8mp0f3FE0GYP3AYPaJF7jUd1M0XxFSE2ceK3k2kw20YvQ09NJKk+OMjWQl9WitG9pB6tSCQIDAQABAkA2SimBrWC2/wvauBuYqjCFwLvYiRYqZKThUS3MZlebXJiLB+Ue/gUifAAKIg1avttUZsHBHrop4qfJCwAI0+YRAiEA+W3NK/RaXtnRqmoUUkb59zsZUBLpvZgQPfj1MhyHDz0CIQDYhsAhPJ3mgS64NbUZmGWuuNKp5coY2GIj/zYDMJp6vQIgUueLFXv/eZ1ekgz2Oi67MNCk5jeTF2BurZqNLR3MSmUCIFT3Q6uHMtsB9Eha4u7hS31tj1UWE+D+ADzp59MGnoftAiBeHT7gDMuqeJHPL4b+kC+gzV4FGTfhR9q3tTbklZkD2A==
|
||||
|
|
|
@ -1,18 +0,0 @@
|
|||
package me.zhengjie.config;
|
||||
|
||||
import com.alipay.sofa.koupleless.common.api.SpringBeanFinder;
|
||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
|
||||
import javax.activation.DataSource;
|
||||
|
||||
@Configuration
|
||||
public class DatasourceConfig {
|
||||
|
||||
@Bean(name = "dataSource")
|
||||
@ConditionalOnMissingBean
|
||||
public DataSource dataSource() {
|
||||
return (DataSource) SpringBeanFinder.getBaseBean("dataSource");
|
||||
}
|
||||
}
|
|
@ -1,18 +0,0 @@
|
|||
package me.zhengjie.config;
|
||||
|
||||
import com.alipay.sofa.koupleless.common.api.SpringBeanFinder;
|
||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
|
||||
import javax.activation.DataSource;
|
||||
|
||||
@Configuration
|
||||
public class DatasourceConfig {
|
||||
|
||||
@Bean(name = "dataSource")
|
||||
@ConditionalOnMissingBean
|
||||
public DataSource dataSource() {
|
||||
return (DataSource) SpringBeanFinder.getBaseBean("dataSource");
|
||||
}
|
||||
}
|
|
@ -1,18 +0,0 @@
|
|||
package me.zhengjie.config;
|
||||
|
||||
import com.alipay.sofa.koupleless.common.api.SpringBeanFinder;
|
||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
|
||||
import javax.activation.DataSource;
|
||||
|
||||
@Configuration
|
||||
public class DatasourceConfig {
|
||||
|
||||
@Bean(name = "dataSource")
|
||||
@ConditionalOnMissingBean
|
||||
public DataSource dataSource() {
|
||||
return (DataSource) SpringBeanFinder.getBaseBean("dataSource");
|
||||
}
|
||||
}
|
4
pom.xml
4
pom.xml
|
@ -41,8 +41,8 @@
|
|||
<druid.version>1.2.8</druid.version>
|
||||
<commons-pool2.version>2.11.1</commons-pool2.version>
|
||||
<mapstruct.version>1.4.2.Final</mapstruct.version>
|
||||
<sofa.ark.version>2.2.9</sofa.ark.version>
|
||||
<koupleless.runtime.version>1.2.0-SNAPSHOT</koupleless.runtime.version>
|
||||
<sofa.ark.version>2.2.10</sofa.ark.version>
|
||||
<koupleless.runtime.version>1.2.0</koupleless.runtime.version>
|
||||
</properties>
|
||||
|
||||
<dependencies>
|
||||
|
|
Loading…
Reference in New Issue