From 7d480ab41b15e7be5661c6aea87d3af826c7d0ce Mon Sep 17 00:00:00 2001 From: Dave Syer Date: Thu, 19 Mar 2015 11:52:25 +0000 Subject: [PATCH] Extract former config-client features to a new spring-cloud-context Fixes gh-14 --- docs/pom.xml | 55 +++ docs/src/main/adoc/README.adoc | 3 + docs/src/main/adoc/spring-cloud-commons.adoc | 257 ++++++++++++ pom.xml | 65 +-- .gitignore => spring-cloud-commons/.gitignore | 0 .../.settings.xml | 0 .../.travis.yml | 0 README.md => spring-cloud-commons/README.md | 0 .../eclipse}/eclipse-code-formatter.xml | 0 .../eclipse}/org.eclipse.jdt.core.prefs | 0 .../eclipse}/org.eclipse.jdt.ui.prefs | 0 spring-cloud-commons/pom.xml | 58 +++ .../CommonsClientAutoConfiguration.java | 0 .../cloud/client/DefaultServiceInstance.java | 0 .../cloud/client/ServiceInstance.java | 0 .../cloud/client/SpringCloudApplication.java | 0 .../circuitbreaker/EnableCircuitBreaker.java | 0 .../EnableCircuitBreakerImportSelector.java | 0 .../discovery/AbstractDiscoveryLifecycle.java | 0 .../client/discovery/DiscoveryClient.java | 0 .../client/discovery/DiscoveryLifecycle.java | 0 .../discovery/EnableDiscoveryClient.java | 0 .../EnableDiscoveryClientImportSelector.java | 0 .../discovery/ManagementServerPortUtils.java | 0 .../discovery/event/HeartbeatEvent.java | 0 .../discovery/event/HeartbeatMonitor.java | 0 .../event/InstanceRegisteredEvent.java | 0 .../discovery/event/ParentHeartbeatEvent.java | 0 .../DiscoveryClientHealthIndicator.java | 0 .../DiscoveryCompositeHealthIndicator.java | 0 .../health/DiscoveryHealthIndicator.java | 0 .../discovery/noop/NoopDiscoveryClient.java | 0 .../NoopDiscoveryClientAutoConfiguration.java | 0 .../LoadBalancerAutoConfiguration.java | 0 .../loadbalancer/LoadBalancerClient.java | 0 .../loadbalancer/LoadBalancerInterceptor.java | 0 .../loadbalancer/LoadBalancerRequest.java | 0 .../SingleImplementationImportSelector.java | 0 .../main/resources/META-INF/spring.factories | 5 + ...EnableDiscoveryClientMissingImplTests.java | 0 .../event/HeartbeatMonitorTests.java | 0 ...iscoveryCompositeHealthIndicatorTests.java | 0 ...eryClientConfigurationAdditionalTests.java | 0 ...NoopDiscoveryClientConfigurationTests.java | 0 ...ngleImplementationImportSelectorTests.java | 0 .../resources/application-encrypt.properties | 0 .../test/resources/application.properties | 0 .../resources/bootstrap-encrypt.properties | 0 .../resources/bootstrap-parent.properties | 0 .../src}/test/resources/bootstrap.properties | 0 .../external-properties/bootstrap.properties | 0 .../src}/test/resources/other.properties | 0 .../src}/test/resources/plain.properties | 0 .../src}/test/resources/server.jks | Bin spring-cloud-context/.gitignore | 13 + spring-cloud-context/.settings.xml | 60 +++ spring-cloud-context/.travis.yml | 25 ++ spring-cloud-context/README.md | 3 + .../eclipse/eclipse-code-formatter.xml | 295 +++++++++++++ .../eclipse/org.eclipse.jdt.core.prefs | 389 ++++++++++++++++++ .../eclipse/org.eclipse.jdt.ui.prefs | 125 ++++++ spring-cloud-context/pom.xml | 58 +++ ...LifecycleMvcEndpointAutoConfiguration.java | 0 .../RefreshAutoConfiguration.java | 0 .../BootstrapApplicationListener.java | 0 .../bootstrap/BootstrapConfiguration.java | 0 .../PropertySourceBootstrapConfiguration.java | 0 .../PropertySourceBootstrapProperties.java | 0 .../config/PropertySourceLocator.java | 0 .../bootstrap/config/RefreshEndpoint.java | 0 .../EncryptionBootstrapConfiguration.java | 0 ...ironmentDecryptApplicationInitializer.java | 0 .../bootstrap/encrypt/KeyProperties.java | 0 .../config/BeanLifecycleDecorator.java | 0 .../StandardBeanLifecycleDecorator.java | 0 .../config/annotation/RefreshScope.java | 0 .../context/encrypt/EncryptorFactory.java | 0 .../context/encrypt/KeyFormatException.java | 0 .../environment/EnvironmentChangeEvent.java | 0 .../environment/EnvironmentManager.java | 0 .../EnvironmentManagerMvcEndpoint.java | 0 .../ConfigurationPropertiesRebinder.java | 0 .../context/restart/RestartEndpoint.java | 0 .../context/restart/RestartListener.java | 0 .../context/restart/RestartMvcEndpoint.java | 0 .../cloud/context/scope/GenericScope.java | 0 .../cloud/context/scope/ScopeCache.java | 0 .../context/scope/StandardScopeCache.java | 0 .../context/scope/refresh/RefreshScope.java | 0 .../refresh/RefreshScopeRefreshedEvent.java | 0 .../scope/thread/ThreadLocalScopeCache.java | 0 .../context/scope/thread/ThreadScope.java | 0 .../endpoint/GenericPostableMvcEndpoint.java | 0 .../cloud/logging/LoggingRebinder.java | 0 .../main/resources/META-INF/spring.factories | 3 - ...bledAutoConfigurationIntegrationTests.java | 0 ...ringAutoConfigurationIntegrationTests.java | 0 .../config/BootstrapConfigurationTests.java | 0 ...EncryptionBootstrapConfigurationTests.java | 0 ...onmentDecryptApplicationListenerTests.java | 0 .../EnvironmentManagerIntegrationTests.java | 0 ...ionPropertiesRebinderIntegrationTests.java | 0 .../restart/RestartIntegrationTests.java | 0 .../ImportRefreshScopeIntegrationTests.java | 0 .../MoreRefreshScopeIntegrationTests.java | 0 .../RefreshEndpointIntegrationTests.java | 0 .../refresh/RefreshScopeConcurrencyTests.java | 0 .../RefreshScopeConfigurationTests.java | 0 .../refresh/RefreshScopeIntegrationTests.java | 0 .../RefreshScopeWebIntegrationTests.java | 0 .../cloud/logging/LoggingRebinderTests.java | 0 .../resources/application-encrypt.properties | 1 + .../src/test/resources/application.properties | 5 + .../resources/bootstrap-encrypt.properties | 1 + .../resources/bootstrap-parent.properties | 1 + .../src/test/resources/bootstrap.properties | 2 + .../external-properties/bootstrap.properties | 1 + .../src/test/resources/other.properties | 1 + .../src/test/resources/plain.properties | 1 + .../src/test/resources/server.jks | Bin 0 -> 2239 bytes 120 files changed, 1373 insertions(+), 54 deletions(-) create mode 100644 docs/pom.xml create mode 100644 docs/src/main/adoc/README.adoc create mode 100644 docs/src/main/adoc/spring-cloud-commons.adoc rename .gitignore => spring-cloud-commons/.gitignore (100%) rename .settings.xml => spring-cloud-commons/.settings.xml (100%) rename .travis.yml => spring-cloud-commons/.travis.yml (100%) rename README.md => spring-cloud-commons/README.md (100%) rename {eclipse => spring-cloud-commons/eclipse}/eclipse-code-formatter.xml (100%) rename {eclipse => spring-cloud-commons/eclipse}/org.eclipse.jdt.core.prefs (100%) rename {eclipse => spring-cloud-commons/eclipse}/org.eclipse.jdt.ui.prefs (100%) create mode 100644 spring-cloud-commons/pom.xml rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/CommonsClientAutoConfiguration.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/DefaultServiceInstance.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/ServiceInstance.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/SpringCloudApplication.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/circuitbreaker/EnableCircuitBreaker.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/circuitbreaker/EnableCircuitBreakerImportSelector.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/discovery/AbstractDiscoveryLifecycle.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/discovery/DiscoveryClient.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/discovery/DiscoveryLifecycle.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/discovery/EnableDiscoveryClient.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/discovery/EnableDiscoveryClientImportSelector.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/discovery/ManagementServerPortUtils.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/discovery/event/HeartbeatEvent.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/discovery/event/HeartbeatMonitor.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/discovery/event/InstanceRegisteredEvent.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/discovery/event/ParentHeartbeatEvent.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/discovery/health/DiscoveryClientHealthIndicator.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/discovery/health/DiscoveryCompositeHealthIndicator.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/discovery/health/DiscoveryHealthIndicator.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClient.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClientAutoConfiguration.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerAutoConfiguration.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerClient.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerInterceptor.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerRequest.java (100%) rename {src => spring-cloud-commons/src}/main/java/org/springframework/cloud/util/SingleImplementationImportSelector.java (100%) create mode 100644 spring-cloud-commons/src/main/resources/META-INF/spring.factories rename {src => spring-cloud-commons/src}/test/java/org/springframework/cloud/client/discovery/EnableDiscoveryClientMissingImplTests.java (100%) rename {src => spring-cloud-commons/src}/test/java/org/springframework/cloud/client/discovery/event/HeartbeatMonitorTests.java (100%) rename {src => spring-cloud-commons/src}/test/java/org/springframework/cloud/client/discovery/health/DiscoveryCompositeHealthIndicatorTests.java (100%) rename {src => spring-cloud-commons/src}/test/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClientConfigurationAdditionalTests.java (100%) rename {src => spring-cloud-commons/src}/test/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClientConfigurationTests.java (100%) rename {src => spring-cloud-commons/src}/test/java/org/springframework/cloud/util/SingleImplementationImportSelectorTests.java (100%) rename {src => spring-cloud-commons/src}/test/resources/application-encrypt.properties (100%) rename {src => spring-cloud-commons/src}/test/resources/application.properties (100%) rename {src => spring-cloud-commons/src}/test/resources/bootstrap-encrypt.properties (100%) rename {src => spring-cloud-commons/src}/test/resources/bootstrap-parent.properties (100%) rename {src => spring-cloud-commons/src}/test/resources/bootstrap.properties (100%) rename {src => spring-cloud-commons/src}/test/resources/external-properties/bootstrap.properties (100%) rename {src => spring-cloud-commons/src}/test/resources/other.properties (100%) rename {src => spring-cloud-commons/src}/test/resources/plain.properties (100%) rename {src => spring-cloud-commons/src}/test/resources/server.jks (100%) create mode 100644 spring-cloud-context/.gitignore create mode 100644 spring-cloud-context/.settings.xml create mode 100644 spring-cloud-context/.travis.yml create mode 100644 spring-cloud-context/README.md create mode 100644 spring-cloud-context/eclipse/eclipse-code-formatter.xml create mode 100644 spring-cloud-context/eclipse/org.eclipse.jdt.core.prefs create mode 100644 spring-cloud-context/eclipse/org.eclipse.jdt.ui.prefs create mode 100644 spring-cloud-context/pom.xml rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/autoconfigure/LifecycleMvcEndpointAutoConfiguration.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/autoconfigure/RefreshAutoConfiguration.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/bootstrap/BootstrapApplicationListener.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/bootstrap/BootstrapConfiguration.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/bootstrap/config/PropertySourceBootstrapConfiguration.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/bootstrap/config/PropertySourceBootstrapProperties.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/bootstrap/config/PropertySourceLocator.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/bootstrap/config/RefreshEndpoint.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/bootstrap/encrypt/EncryptionBootstrapConfiguration.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/bootstrap/encrypt/EnvironmentDecryptApplicationInitializer.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/bootstrap/encrypt/KeyProperties.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/config/BeanLifecycleDecorator.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/config/StandardBeanLifecycleDecorator.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/config/annotation/RefreshScope.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/encrypt/EncryptorFactory.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/encrypt/KeyFormatException.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/environment/EnvironmentChangeEvent.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/environment/EnvironmentManager.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/environment/EnvironmentManagerMvcEndpoint.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/properties/ConfigurationPropertiesRebinder.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/restart/RestartEndpoint.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/restart/RestartListener.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/restart/RestartMvcEndpoint.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/scope/GenericScope.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/scope/ScopeCache.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/scope/StandardScopeCache.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/scope/refresh/RefreshScope.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/scope/refresh/RefreshScopeRefreshedEvent.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/scope/thread/ThreadLocalScopeCache.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/context/scope/thread/ThreadScope.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/endpoint/GenericPostableMvcEndpoint.java (100%) rename {src => spring-cloud-context/src}/main/java/org/springframework/cloud/logging/LoggingRebinder.java (100%) rename {src => spring-cloud-context/src}/main/resources/META-INF/spring.factories (75%) rename {src => spring-cloud-context/src}/test/java/org/springframework/cloud/bootstrap/BootstrapDisabledAutoConfigurationIntegrationTests.java (100%) rename {src => spring-cloud-context/src}/test/java/org/springframework/cloud/bootstrap/BootstrapOrderingAutoConfigurationIntegrationTests.java (100%) rename {src => spring-cloud-context/src}/test/java/org/springframework/cloud/bootstrap/config/BootstrapConfigurationTests.java (100%) rename {src => spring-cloud-context/src}/test/java/org/springframework/cloud/bootstrap/encrypt/EncryptionBootstrapConfigurationTests.java (100%) rename {src => spring-cloud-context/src}/test/java/org/springframework/cloud/bootstrap/encrypt/EnvironmentDecryptApplicationListenerTests.java (100%) rename {src => spring-cloud-context/src}/test/java/org/springframework/cloud/context/environment/EnvironmentManagerIntegrationTests.java (100%) rename {src => spring-cloud-context/src}/test/java/org/springframework/cloud/context/properties/ConfigurationPropertiesRebinderIntegrationTests.java (100%) rename {src => spring-cloud-context/src}/test/java/org/springframework/cloud/context/restart/RestartIntegrationTests.java (100%) rename {src => spring-cloud-context/src}/test/java/org/springframework/cloud/context/scope/refresh/ImportRefreshScopeIntegrationTests.java (100%) rename {src => spring-cloud-context/src}/test/java/org/springframework/cloud/context/scope/refresh/MoreRefreshScopeIntegrationTests.java (100%) rename {src => spring-cloud-context/src}/test/java/org/springframework/cloud/context/scope/refresh/RefreshEndpointIntegrationTests.java (100%) rename {src => spring-cloud-context/src}/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeConcurrencyTests.java (100%) rename {src => spring-cloud-context/src}/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeConfigurationTests.java (100%) rename {src => spring-cloud-context/src}/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeIntegrationTests.java (100%) rename {src => spring-cloud-context/src}/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeWebIntegrationTests.java (100%) rename {src => spring-cloud-context/src}/test/java/org/springframework/cloud/logging/LoggingRebinderTests.java (100%) create mode 100644 spring-cloud-context/src/test/resources/application-encrypt.properties create mode 100644 spring-cloud-context/src/test/resources/application.properties create mode 100644 spring-cloud-context/src/test/resources/bootstrap-encrypt.properties create mode 100644 spring-cloud-context/src/test/resources/bootstrap-parent.properties create mode 100644 spring-cloud-context/src/test/resources/bootstrap.properties create mode 100644 spring-cloud-context/src/test/resources/external-properties/bootstrap.properties create mode 100644 spring-cloud-context/src/test/resources/other.properties create mode 100644 spring-cloud-context/src/test/resources/plain.properties create mode 100644 spring-cloud-context/src/test/resources/server.jks diff --git a/docs/pom.xml b/docs/pom.xml new file mode 100644 index 00000000..3546e533 --- /dev/null +++ b/docs/pom.xml @@ -0,0 +1,55 @@ + + + 4.0.0 + org.springframework.cloud + spring-cloud-commons-docs + 1.0.1.BUILD-SNAPSHOT + + org.springframework.cloud + spring-cloud-build + 1.0.1.BUILD-SNAPSHOT + + + pom + Spring Cloud Commons Docs + Spring Cloud Commons Docs + + spring-cloud-commons + ${basedir}/.. + + + + + + maven-deploy-plugin + + true + + + + + + + docs + + + + org.asciidoctor + asciidoctor-maven-plugin + false + + + org.apache.maven.plugins + maven-antrun-plugin + false + + + org.codehaus.mojo + build-helper-maven-plugin + false + + + + + + diff --git a/docs/src/main/adoc/README.adoc b/docs/src/main/adoc/README.adoc new file mode 100644 index 00000000..4a5fff5a --- /dev/null +++ b/docs/src/main/adoc/README.adoc @@ -0,0 +1,3 @@ += Spring Cloud Commons and Context + +Common classes used in different Spring Cloud implementations (eg. Spring Cloud Netflix vs. Spring Cloud Consul). \ No newline at end of file diff --git a/docs/src/main/adoc/spring-cloud-commons.adoc b/docs/src/main/adoc/spring-cloud-commons.adoc new file mode 100644 index 00000000..9a532b35 --- /dev/null +++ b/docs/src/main/adoc/spring-cloud-commons.adoc @@ -0,0 +1,257 @@ +=== Environment Changes + +The application will listen for an `EnvironmentChangedEvent` and react +to the change in a couple of standard ways (additional +`ApplicationListeners` can be added as `@Beans` by the user in the +normal way). When an `EnvironmentChangedEvent` is observed it will +have a list of key values that have changed, and the application will +use those to: + +* Re-bind any `@ConfigurationProperties` beans in the context +* Set the logger levels for any properties in `logging.level.*` + +Note that the Config Client does not by default poll for changes in +the `Environment`, and generally we would not recommend that approach +for detecting changes (although you could set it up with a +`@Scheduled` annotation). If you have a scaled-out client application +then it is better to broadcast the `EnvironmentChangedEvent` to all +the instances instead of having them polling for changes (e.g. using +the https://github.com/spring-cloud/spring-cloud-bus[Spring Cloud +Bus]). + +The `EnvironmentChangedEvent` covers a large class of refresh use +cases, as long as you can actually make a change to the `Environment` +and publish the event (those APIs are public and part of core +Spring). You can verify the changes are bound to +`@ConfigurationProperties` beans by visiting the `/configprops` +endpoint (normal Spring Boot Actuator feature). For instance a +`DataSource` can have its `maxPoolSize` changed at runtime (the +default `DataSource` created by Spring Boot is an +`@ConfigurationProperties` bean) and grow capacity +dynamically. Re-binding `@ConfigurationProperties` does not cover +another large class of use cases, where you need more control over the +refresh, and where you need a change to be atomic over the whole +`ApplicationContext`. To address those concerns we have +`@RefreshScope`. + +=== Refresh Scope + +A Spring `@Bean` that is marked as `@RefreshScope` will get special +treatment when there is a configuration change. This addresses the +problem of stateful beans that only get their configuration injected +when they are initialized. For instance if a `DataSource` has open +connections when the database URL is changed via the `Environment`, we +probably want the holders of those connections to be able to complete +what they are doing. Then the next time someone borrows a connection +from the pool he gets one with the new URL. + +Refresh scope beans are lazy proxies that initialize when they are +used (i.e. when a method is called), and the scope acts as a cache of +initialized values. To force a bean to re-initialize on the next +method call you just need to invalidate its cache entry. + +The `RefreshScope` is a bean in the context and it has a public method +`refreshAll()` to refresh all beans in the scope by clearing the +target cache. There is also a `refresh(String)` method to refresh an +individual bean by name. This functionality is exposed in the +`/refresh` endpoint (over HTTP or JMX). + +NOTE: `@RefreshScope` works (technically) on an `@Configuration` +class, but it might lead to surprising behaviour: e.g. it does *not* +mean that all the `@Beans` defined in that class are themselves +`@RefreshScope`. Specifically, anything that depends on those beans +cannot rely on them being updated when a refresh is initiated, unless +it is itself in `@RefreshScope` (in which it will be rebuilt on a +refresh and its dependencies re-injected, at which point they will be +re-initialized from the refreshed `@Configuration`). + +=== Encryption and Decryption + +The Config Client has an `Environment` pre-processor for decrypting +property values locally. It follows the same rules as the Config +Server, and has the same external configuration via `encrypt.\*`. Thus +you can use encrypted values in the form `{cipher}*` and as long as +there is a valid key then they will be decrypted before the main +application context gets the `Environment`. To use the encryption +features in a client you need to include Spring Security RSA in your +classpath (Maven co-ordinates +"org.springframework.security:spring-security-rsa") and you also need +the full strength JCE extensions in your JVM (google it and download +from Oracle). + +=== Endpoints + +For a Spring Boot Actuator application there are some additional management endpoints: + +* POST to `/env` to update the `Environment` and rebind `@ConfigurationProperties` and log levels +* `/refresh` for re-loading the boot strap context and refreshing the `@RefreshScope` beans +* `/restart` for closing the `ApplicationContext` and restarting it (disabled by default) +* `/pause` and `/resume` for calling the `Lifecycle` methods (`stop()` and `start()` on the `ApplicationContext`) + +=== The Bootstrap Application Context + +The Config Client operates by creating a "bootstrap" application +context, which is a parent context for the main application. Out of +the box it is responsible for loading configuration properties from +the Config Server, and also decrypting properties in the local +external configuration files. The two contexts share an `Environment` +which is the source of external properties for any Spring +application. Bootstrap properties are added with high precedence, so +they cannot be overridden by local configuration. + +The bootstrap context uses a different convention for locating +external configuration than the main application context, so instead +of `application.yml` (or `.properties`) you use `bootstrap.yml`, +keeping the external configuration for bootstrap and main context +nicely separate. Example: + +.bootstrap.yml +---- +spring: + application: + name: foo + cloud: + config: + uri: ${SPRING_CONFIG_URI:http://localhost:8888} +---- + +It is a good idea to set the `spring.application.name` (in +`bootstrap.yml` or `application.yml`) if your application needs any +application-specific configuration from the server. + +You can disable the bootstrap process completely by setting +`spring.cloud.bootstrap.enabled=false` (e.g. in System properties). + +=== Application Context Hierarchies + +If you build an application context from `SpringApplication` or +`SpringApplicationBuilder`, then the Bootstrap context is added as a +parent to that context. It is a feature of Spring that child contexts +inherit property sources and profiles from their parent, so the "main" +application context will contain additional property sources, compared +to building the same context without Spring Cloud Config. The +additional property sources are: + +* "bootstrap": an optional `CompositePropertySource` appears with high +priority if any `PropertySourceLocators` are found in the Bootstrap +context, and they have non-empty properties. An example would be +properties from the Spring Cloud Config Server. See +link:#customizing-bootstrap-property-sources[below] for instructions +on how to customize the contents of this property source. + +* "applicationConfig: [classpath:bootstrap.yml]" (and friends if +Spring profiles are active). If you have a `bootstrap.yml` (or +properties) then those properties are used to configure the Bootstrap +context, and then they get added to the child context when its parent +is set. They have lower precedence than the `application.yml` (or +properties) and any other property sources that are added to the child +as a normal part of the process of creating a Spring Boot +application. See link:#customizing-bootstrap-properties[below] for +instructions on how to customize the contents of these property +sources. + +Because of the ordering rules of property sources the "bootstrap" +entries take precedence, but note that these do not contain any data +from `bootstrap.yml`, which has very low precedence, but can be used +to set defaults. + +You can extend the context hierarchy by simply setting the parent +context of any `ApplicationContext` you create, e.g. using its own +interface, or with the `SpringApplicationBuilder` convenience methods +(`parent()`, `child()` and `sibling()`). The bootstrap context will be +the parent of the most senior ancestor that you create yourself. +Every context in the hierarchy will have its own "bootstrap" property +source (possibly empty) to avoid promoting values inadvertently from +parents down to their descendants. Every context in the hierarchy can +also (in principle) have a different `spring.application.name` and +hence a different remote property source if there is a Config +Server. Normal Spring application context behaviour rules apply to +property resolution: properties from a child context override those in +the parent, by name and also by property source name (if the child has +a property source with the same name as the parent, the one from the +parent is not included in the child). + +Note that the `SpringApplicationBuilder` allows you to share an +`Environment` amongst the whole hierarchy, but that is not the +default. Thus, sibling contexts in particular do not need to have the +same profiles or property sources, even though they will share common +things with their parent. + +[[customizing-bootstrap-properties]] +=== Changing the Location of Bootstrap Properties + +The `bootstrap.yml` (or `.properties) location can be specified using +`spring.cloud.bootstrap.name` (default "bootstrap") or +`spring.cloud.bootstrap.location` (default empty), e.g. in System +properties. Those properties behave like the `spring.config.*` +variants with the same name, in fact they are used to set up the +bootstrap `ApplicationContext` by setting those properties in its +`Environment`. If there is an active profile (from +`spring.profiles.active` or through the `Environment` API in the +context you are building) then properties in that profile will be +loaded as well, just like in a regular Spring Boot app, e.g. from +`bootstrap-development.properties` for a "development" profile. + +=== Customizing the Bootstrap Configuration + +The bootstrap context can be trained to do anything you like by adding +entries to `/META-INF/spring.factories` under the key +`org.springframework.cloud.bootstrap.BootstrapConfiguration`. This is +a comma-separated list of Spring `@Configuration` classes which will +be used to create the context. Any beans that you want to be available +to the main application context for autowiring can be created here, +and also there is a special contract for `@Beans` of type +`ApplicationContextInitializer`. + +The bootstrap process ends by injecting initializers into the main +`SpringApplication` instance (i.e. the normal Spring Boot startup +sequence, whether it is running as a standalone app or deployed in an +application server). First a bootstrap context is created from the +classes found in `spring.factories` and then all `@Beans` of type +`ApplicationContextInitializer` are added to the main +`SpringApplication` before it is started. + +[[customizing-bootstrap-property-sources]] +=== Customizing the Bootstrap Property Sources + +The default property source for external configuration added by the +bootstrap process is the Config Server, but you can add additional +sources by adding beans of type `PropertySourceLocator` to the +bootstrap context (via `spring.factories`). You could use this to +insert additional properties from a different server, or from a +database, for instance. + +As an example, consider the following trivial custom locator: + +[source,java] +---- +@Configuration +public class CustomPropertySourceLocator implements PropertySourceLocator { + + @Override + public PropertySource locate(Environment environment) { + return new MapPropertySource("customProperty", + Collections.singletonMap("property.from.sample.custom.source", "worked as intended")); + } + +} +---- + +The `Environment` that is passed in is the one for the +`ApplicationContext` about to be created, i.e. the one that we are +supplying additional property sources for. It will already have its +normal Spring Boot-provided property sources, so you can use those to +locate a property source specific to this `Environment` (e.g. by +keying it on the `spring.application.name`, as is done in the default +Config Server property source locator). + +If you create a jar with this class in it and then add a +`META-INF/spring.factories` containing: + +---- +org.springframework.cloud.bootstrap.BootstrapConfiguration=sample.custom.CustomPropertySourceLocator +---- + +then the "customProperty" `PropertySource` will show up in any +application that includes that jar on its classpath. + diff --git a/pom.xml b/pom.xml index 93e15e7c..54adb64c 100644 --- a/pom.xml +++ b/pom.xml @@ -1,19 +1,19 @@ - + 4.0.0 - + org.springframework.cloud + spring-cloud-commons-parent + 1.0.1.BUILD-SNAPSHOT + pom + Spring Cloud Commons Parent + Spring Cloud Commons Parent + http://projects.spring.io/spring-cloud/ org.springframework.cloud spring-cloud-build 1.0.1.BUILD-SNAPSHOT - + - spring-cloud-commons - 1.0.1.BUILD-SNAPSHOT - jar - Spring Cloud Commons - Spring Cloud Commons https://github.com/spring-cloud/spring-cloud-commons scm:git:git://github.com/spring-cloud/spring-cloud-commons.git @@ -53,46 +53,9 @@ - - - org.springframework.boot - spring-boot-starter-actuator - true - - - org.springframework.boot - spring-boot-starter-web - true - - - org.springframework.boot - spring-boot-starter-aop - true - - - org.springframework.security - spring-security-crypto - - - org.springframework.security - spring-security-rsa - true - - - org.springframework.integration - spring-integration-jmx - true - - - org.projectlombok - lombok - compile - true - - - org.springframework.boot - spring-boot-starter-test - test - - + + spring-cloud-context + spring-cloud-commons + docs + diff --git a/.gitignore b/spring-cloud-commons/.gitignore similarity index 100% rename from .gitignore rename to spring-cloud-commons/.gitignore diff --git a/.settings.xml b/spring-cloud-commons/.settings.xml similarity index 100% rename from .settings.xml rename to spring-cloud-commons/.settings.xml diff --git a/.travis.yml b/spring-cloud-commons/.travis.yml similarity index 100% rename from .travis.yml rename to spring-cloud-commons/.travis.yml diff --git a/README.md b/spring-cloud-commons/README.md similarity index 100% rename from README.md rename to spring-cloud-commons/README.md diff --git a/eclipse/eclipse-code-formatter.xml b/spring-cloud-commons/eclipse/eclipse-code-formatter.xml similarity index 100% rename from eclipse/eclipse-code-formatter.xml rename to spring-cloud-commons/eclipse/eclipse-code-formatter.xml diff --git a/eclipse/org.eclipse.jdt.core.prefs b/spring-cloud-commons/eclipse/org.eclipse.jdt.core.prefs similarity index 100% rename from eclipse/org.eclipse.jdt.core.prefs rename to spring-cloud-commons/eclipse/org.eclipse.jdt.core.prefs diff --git a/eclipse/org.eclipse.jdt.ui.prefs b/spring-cloud-commons/eclipse/org.eclipse.jdt.ui.prefs similarity index 100% rename from eclipse/org.eclipse.jdt.ui.prefs rename to spring-cloud-commons/eclipse/org.eclipse.jdt.ui.prefs diff --git a/spring-cloud-commons/pom.xml b/spring-cloud-commons/pom.xml new file mode 100644 index 00000000..84d914c9 --- /dev/null +++ b/spring-cloud-commons/pom.xml @@ -0,0 +1,58 @@ + + + 4.0.0 + + + org.springframework.cloud + spring-cloud-commons-parent + 1.0.1.BUILD-SNAPSHOT + .. + + spring-cloud-commons + jar + Spring Cloud Commons + Spring Cloud Commons + + + org.springframework.boot + spring-boot-starter-actuator + true + + + org.springframework.boot + spring-boot-starter-web + true + + + org.springframework.boot + spring-boot-starter-aop + true + + + org.springframework.security + spring-security-crypto + + + org.springframework.security + spring-security-rsa + true + + + org.springframework.integration + spring-integration-jmx + true + + + org.projectlombok + lombok + compile + true + + + org.springframework.boot + spring-boot-starter-test + test + + + diff --git a/src/main/java/org/springframework/cloud/client/CommonsClientAutoConfiguration.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/CommonsClientAutoConfiguration.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/CommonsClientAutoConfiguration.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/CommonsClientAutoConfiguration.java diff --git a/src/main/java/org/springframework/cloud/client/DefaultServiceInstance.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/DefaultServiceInstance.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/DefaultServiceInstance.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/DefaultServiceInstance.java diff --git a/src/main/java/org/springframework/cloud/client/ServiceInstance.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/ServiceInstance.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/ServiceInstance.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/ServiceInstance.java diff --git a/src/main/java/org/springframework/cloud/client/SpringCloudApplication.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/SpringCloudApplication.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/SpringCloudApplication.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/SpringCloudApplication.java diff --git a/src/main/java/org/springframework/cloud/client/circuitbreaker/EnableCircuitBreaker.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/circuitbreaker/EnableCircuitBreaker.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/circuitbreaker/EnableCircuitBreaker.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/circuitbreaker/EnableCircuitBreaker.java diff --git a/src/main/java/org/springframework/cloud/client/circuitbreaker/EnableCircuitBreakerImportSelector.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/circuitbreaker/EnableCircuitBreakerImportSelector.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/circuitbreaker/EnableCircuitBreakerImportSelector.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/circuitbreaker/EnableCircuitBreakerImportSelector.java diff --git a/src/main/java/org/springframework/cloud/client/discovery/AbstractDiscoveryLifecycle.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/AbstractDiscoveryLifecycle.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/discovery/AbstractDiscoveryLifecycle.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/AbstractDiscoveryLifecycle.java diff --git a/src/main/java/org/springframework/cloud/client/discovery/DiscoveryClient.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/DiscoveryClient.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/discovery/DiscoveryClient.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/DiscoveryClient.java diff --git a/src/main/java/org/springframework/cloud/client/discovery/DiscoveryLifecycle.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/DiscoveryLifecycle.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/discovery/DiscoveryLifecycle.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/DiscoveryLifecycle.java diff --git a/src/main/java/org/springframework/cloud/client/discovery/EnableDiscoveryClient.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/EnableDiscoveryClient.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/discovery/EnableDiscoveryClient.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/EnableDiscoveryClient.java diff --git a/src/main/java/org/springframework/cloud/client/discovery/EnableDiscoveryClientImportSelector.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/EnableDiscoveryClientImportSelector.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/discovery/EnableDiscoveryClientImportSelector.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/EnableDiscoveryClientImportSelector.java diff --git a/src/main/java/org/springframework/cloud/client/discovery/ManagementServerPortUtils.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/ManagementServerPortUtils.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/discovery/ManagementServerPortUtils.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/ManagementServerPortUtils.java diff --git a/src/main/java/org/springframework/cloud/client/discovery/event/HeartbeatEvent.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/event/HeartbeatEvent.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/discovery/event/HeartbeatEvent.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/event/HeartbeatEvent.java diff --git a/src/main/java/org/springframework/cloud/client/discovery/event/HeartbeatMonitor.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/event/HeartbeatMonitor.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/discovery/event/HeartbeatMonitor.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/event/HeartbeatMonitor.java diff --git a/src/main/java/org/springframework/cloud/client/discovery/event/InstanceRegisteredEvent.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/event/InstanceRegisteredEvent.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/discovery/event/InstanceRegisteredEvent.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/event/InstanceRegisteredEvent.java diff --git a/src/main/java/org/springframework/cloud/client/discovery/event/ParentHeartbeatEvent.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/event/ParentHeartbeatEvent.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/discovery/event/ParentHeartbeatEvent.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/event/ParentHeartbeatEvent.java diff --git a/src/main/java/org/springframework/cloud/client/discovery/health/DiscoveryClientHealthIndicator.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/health/DiscoveryClientHealthIndicator.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/discovery/health/DiscoveryClientHealthIndicator.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/health/DiscoveryClientHealthIndicator.java diff --git a/src/main/java/org/springframework/cloud/client/discovery/health/DiscoveryCompositeHealthIndicator.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/health/DiscoveryCompositeHealthIndicator.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/discovery/health/DiscoveryCompositeHealthIndicator.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/health/DiscoveryCompositeHealthIndicator.java diff --git a/src/main/java/org/springframework/cloud/client/discovery/health/DiscoveryHealthIndicator.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/health/DiscoveryHealthIndicator.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/discovery/health/DiscoveryHealthIndicator.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/health/DiscoveryHealthIndicator.java diff --git a/src/main/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClient.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClient.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClient.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClient.java diff --git a/src/main/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClientAutoConfiguration.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClientAutoConfiguration.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClientAutoConfiguration.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClientAutoConfiguration.java diff --git a/src/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerAutoConfiguration.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerAutoConfiguration.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerAutoConfiguration.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerAutoConfiguration.java diff --git a/src/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerClient.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerClient.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerClient.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerClient.java diff --git a/src/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerInterceptor.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerInterceptor.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerInterceptor.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerInterceptor.java diff --git a/src/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerRequest.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerRequest.java similarity index 100% rename from src/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerRequest.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/client/loadbalancer/LoadBalancerRequest.java diff --git a/src/main/java/org/springframework/cloud/util/SingleImplementationImportSelector.java b/spring-cloud-commons/src/main/java/org/springframework/cloud/util/SingleImplementationImportSelector.java similarity index 100% rename from src/main/java/org/springframework/cloud/util/SingleImplementationImportSelector.java rename to spring-cloud-commons/src/main/java/org/springframework/cloud/util/SingleImplementationImportSelector.java diff --git a/spring-cloud-commons/src/main/resources/META-INF/spring.factories b/spring-cloud-commons/src/main/resources/META-INF/spring.factories new file mode 100644 index 00000000..0345563f --- /dev/null +++ b/spring-cloud-commons/src/main/resources/META-INF/spring.factories @@ -0,0 +1,5 @@ +# AutoConfiguration +org.springframework.boot.autoconfigure.EnableAutoConfiguration=\ +org.springframework.cloud.client.CommonsClientAutoConfiguration,\ +org.springframework.cloud.client.discovery.noop.NoopDiscoveryClientAutoConfiguration,\ +org.springframework.cloud.client.loadbalancer.LoadBalancerAutoConfiguration diff --git a/src/test/java/org/springframework/cloud/client/discovery/EnableDiscoveryClientMissingImplTests.java b/spring-cloud-commons/src/test/java/org/springframework/cloud/client/discovery/EnableDiscoveryClientMissingImplTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/client/discovery/EnableDiscoveryClientMissingImplTests.java rename to spring-cloud-commons/src/test/java/org/springframework/cloud/client/discovery/EnableDiscoveryClientMissingImplTests.java diff --git a/src/test/java/org/springframework/cloud/client/discovery/event/HeartbeatMonitorTests.java b/spring-cloud-commons/src/test/java/org/springframework/cloud/client/discovery/event/HeartbeatMonitorTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/client/discovery/event/HeartbeatMonitorTests.java rename to spring-cloud-commons/src/test/java/org/springframework/cloud/client/discovery/event/HeartbeatMonitorTests.java diff --git a/src/test/java/org/springframework/cloud/client/discovery/health/DiscoveryCompositeHealthIndicatorTests.java b/spring-cloud-commons/src/test/java/org/springframework/cloud/client/discovery/health/DiscoveryCompositeHealthIndicatorTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/client/discovery/health/DiscoveryCompositeHealthIndicatorTests.java rename to spring-cloud-commons/src/test/java/org/springframework/cloud/client/discovery/health/DiscoveryCompositeHealthIndicatorTests.java diff --git a/src/test/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClientConfigurationAdditionalTests.java b/spring-cloud-commons/src/test/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClientConfigurationAdditionalTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClientConfigurationAdditionalTests.java rename to spring-cloud-commons/src/test/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClientConfigurationAdditionalTests.java diff --git a/src/test/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClientConfigurationTests.java b/spring-cloud-commons/src/test/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClientConfigurationTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClientConfigurationTests.java rename to spring-cloud-commons/src/test/java/org/springframework/cloud/client/discovery/noop/NoopDiscoveryClientConfigurationTests.java diff --git a/src/test/java/org/springframework/cloud/util/SingleImplementationImportSelectorTests.java b/spring-cloud-commons/src/test/java/org/springframework/cloud/util/SingleImplementationImportSelectorTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/util/SingleImplementationImportSelectorTests.java rename to spring-cloud-commons/src/test/java/org/springframework/cloud/util/SingleImplementationImportSelectorTests.java diff --git a/src/test/resources/application-encrypt.properties b/spring-cloud-commons/src/test/resources/application-encrypt.properties similarity index 100% rename from src/test/resources/application-encrypt.properties rename to spring-cloud-commons/src/test/resources/application-encrypt.properties diff --git a/src/test/resources/application.properties b/spring-cloud-commons/src/test/resources/application.properties similarity index 100% rename from src/test/resources/application.properties rename to spring-cloud-commons/src/test/resources/application.properties diff --git a/src/test/resources/bootstrap-encrypt.properties b/spring-cloud-commons/src/test/resources/bootstrap-encrypt.properties similarity index 100% rename from src/test/resources/bootstrap-encrypt.properties rename to spring-cloud-commons/src/test/resources/bootstrap-encrypt.properties diff --git a/src/test/resources/bootstrap-parent.properties b/spring-cloud-commons/src/test/resources/bootstrap-parent.properties similarity index 100% rename from src/test/resources/bootstrap-parent.properties rename to spring-cloud-commons/src/test/resources/bootstrap-parent.properties diff --git a/src/test/resources/bootstrap.properties b/spring-cloud-commons/src/test/resources/bootstrap.properties similarity index 100% rename from src/test/resources/bootstrap.properties rename to spring-cloud-commons/src/test/resources/bootstrap.properties diff --git a/src/test/resources/external-properties/bootstrap.properties b/spring-cloud-commons/src/test/resources/external-properties/bootstrap.properties similarity index 100% rename from src/test/resources/external-properties/bootstrap.properties rename to spring-cloud-commons/src/test/resources/external-properties/bootstrap.properties diff --git a/src/test/resources/other.properties b/spring-cloud-commons/src/test/resources/other.properties similarity index 100% rename from src/test/resources/other.properties rename to spring-cloud-commons/src/test/resources/other.properties diff --git a/src/test/resources/plain.properties b/spring-cloud-commons/src/test/resources/plain.properties similarity index 100% rename from src/test/resources/plain.properties rename to spring-cloud-commons/src/test/resources/plain.properties diff --git a/src/test/resources/server.jks b/spring-cloud-commons/src/test/resources/server.jks similarity index 100% rename from src/test/resources/server.jks rename to spring-cloud-commons/src/test/resources/server.jks diff --git a/spring-cloud-context/.gitignore b/spring-cloud-context/.gitignore new file mode 100644 index 00000000..8c5133e4 --- /dev/null +++ b/spring-cloud-context/.gitignore @@ -0,0 +1,13 @@ +*~ +#* +*# +.#* +.classpath +.project +.settings/ +.springBeans +target/ +_site/ +.idea +*.iml +*.swp diff --git a/spring-cloud-context/.settings.xml b/spring-cloud-context/.settings.xml new file mode 100644 index 00000000..006f51ef --- /dev/null +++ b/spring-cloud-context/.settings.xml @@ -0,0 +1,60 @@ + + + + + repo.spring.io + ${env.CI_DEPLOY_USERNAME} + ${env.CI_DEPLOY_PASSWORD} + + + + + spring + true + + + spring-snapshots + Spring Snapshots + http://repo.spring.io/libs-snapshot-local + + true + + + + spring-milestones + Spring Milestones + http://repo.spring.io/libs-milestone-local + + false + + + + spring-releases + Spring Releases + http://repo.spring.io/release + + false + + + + + + spring-snapshots + Spring Snapshots + http://repo.spring.io/libs-snapshot-local + + true + + + + spring-milestones + Spring Milestones + http://repo.spring.io/libs-milestone-local + + false + + + + + + diff --git a/spring-cloud-context/.travis.yml b/spring-cloud-context/.travis.yml new file mode 100644 index 00000000..d142bde0 --- /dev/null +++ b/spring-cloud-context/.travis.yml @@ -0,0 +1,25 @@ +sudo: false +cache: + directories: + - $HOME/.m2 +language: java +before_install: +- git config user.name "$GIT_NAME" +- git config user.email "$GIT_EMAIL" +- git config credential.helper "store --file=.git/credentials" +- echo "https://$GH_TOKEN:@github.com" > .git/credentials +- gem install asciidoctor +install: +- mvn --settings .settings.xml install -P docs -q -U -DskipTests=true -Dmaven.test.redirectTestOutputToFile=true +#- ./docs/src/main/asciidoc/ghpages.sh +script: +- '[ "${TRAVIS_PULL_REQUEST}" != "false" ] || mvn --settings .settings.xml deploy + -nsu -Dmaven.test.redirectTestOutputToFile=true' +- '[ "${TRAVIS_PULL_REQUEST}" = "false" ] || mvn --settings .settings.xml install + -nsu -Dmaven.test.redirectTestOutputToFile=true' +env: + global: + - GIT_NAME="Spencer Gibb" + - GIT_EMAIL=sgibb@pivotal.io + - CI_DEPLOY_USERNAME=sgibb + - secure: WPmrAQJQGBziwGFKwTiDRGrG1nuy9dvoWOQt7WKHW0RBqDbUpZgGeHq6OD2FcE86eRo+tPDihyunsWltei+sfq5bUECkGFQBLGffcTuxyu2j4lTByVazeYKa3en3j7nOiQjI99MqgCHrdyRwtS9EF1SnYXRuSZXwb0Ic8h4Zns4= diff --git a/spring-cloud-context/README.md b/spring-cloud-context/README.md new file mode 100644 index 00000000..9177f3ee --- /dev/null +++ b/spring-cloud-context/README.md @@ -0,0 +1,3 @@ +## Spring Cloud Context + +Utilities and special services for the `ApplicationContext` of a Spring Cloud application (bootstrap context, encryption, refresh scope and environment endpoints). \ No newline at end of file diff --git a/spring-cloud-context/eclipse/eclipse-code-formatter.xml b/spring-cloud-context/eclipse/eclipse-code-formatter.xml new file mode 100644 index 00000000..4694d7f2 --- /dev/null +++ b/spring-cloud-context/eclipse/eclipse-code-formatter.xml @@ -0,0 +1,295 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/spring-cloud-context/eclipse/org.eclipse.jdt.core.prefs b/spring-cloud-context/eclipse/org.eclipse.jdt.core.prefs new file mode 100644 index 00000000..63d59166 --- /dev/null +++ b/spring-cloud-context/eclipse/org.eclipse.jdt.core.prefs @@ -0,0 +1,389 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.codeComplete.argumentPrefixes= +org.eclipse.jdt.core.codeComplete.argumentSuffixes= +org.eclipse.jdt.core.codeComplete.fieldPrefixes= +org.eclipse.jdt.core.codeComplete.fieldSuffixes= +org.eclipse.jdt.core.codeComplete.localPrefixes= +org.eclipse.jdt.core.codeComplete.localSuffixes= +org.eclipse.jdt.core.codeComplete.staticFieldPrefixes= +org.eclipse.jdt.core.codeComplete.staticFieldSuffixes= +org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes= +org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes= +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 +org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve +org.eclipse.jdt.core.compiler.compliance=1.6 +org.eclipse.jdt.core.compiler.debug.lineNumber=generate +org.eclipse.jdt.core.compiler.debug.localVariable=generate +org.eclipse.jdt.core.compiler.debug.sourceFile=generate +org.eclipse.jdt.core.compiler.doc.comment.support=enabled +org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.autoboxing=ignore +org.eclipse.jdt.core.compiler.problem.comparingIdentical=warning +org.eclipse.jdt.core.compiler.problem.deadCode=warning +org.eclipse.jdt.core.compiler.problem.deprecation=warning +org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled +org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled +org.eclipse.jdt.core.compiler.problem.discouragedReference=warning +org.eclipse.jdt.core.compiler.problem.emptyStatement=ignore +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.problem.fallthroughCase=ignore +org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled +org.eclipse.jdt.core.compiler.problem.fieldHiding=ignore +org.eclipse.jdt.core.compiler.problem.finalParameterBound=warning +org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning +org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning +org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning +org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled +org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning +org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=ignore +org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore +org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning +org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled +org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=disabled +org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled +org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=default +org.eclipse.jdt.core.compiler.problem.localVariableHiding=ignore +org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning +org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=ignore +org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=ignore +org.eclipse.jdt.core.compiler.problem.missingJavadocComments=ignore +org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled +org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public +org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=return_tag +org.eclipse.jdt.core.compiler.problem.missingJavadocTags=ignore +org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled +org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled +org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=private +org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=ignore +org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled +org.eclipse.jdt.core.compiler.problem.missingSerialVersion=ignore +org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=ignore +org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning +org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning +org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore +org.eclipse.jdt.core.compiler.problem.nullReference=ignore +org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning +org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore +org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=ignore +org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore +org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning +org.eclipse.jdt.core.compiler.problem.redundantNullCheck=ignore +org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=ignore +org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore +org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore +org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore +org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled +org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning +org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled +org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled +org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore +org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning +org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=enabled +org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning +org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore +org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning +org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore +org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=warning +org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled +org.eclipse.jdt.core.compiler.problem.unusedImport=warning +org.eclipse.jdt.core.compiler.problem.unusedLabel=warning +org.eclipse.jdt.core.compiler.problem.unusedLocal=warning +org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore +org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore +org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled +org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled +org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled +org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning +org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning +org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning +org.eclipse.jdt.core.compiler.source=1.6 +org.eclipse.jdt.core.formatter.align_type_members_on_columns=false +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_assignment=0 +org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_compact_if=16 +org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80 +org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0 +org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16 +org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0 +org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16 +org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80 +org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=16 +org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16 +org.eclipse.jdt.core.formatter.blank_lines_after_imports=1 +org.eclipse.jdt.core.formatter.blank_lines_after_package=1 +org.eclipse.jdt.core.formatter.blank_lines_before_field=0 +org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0 +org.eclipse.jdt.core.formatter.blank_lines_before_imports=1 +org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1 +org.eclipse.jdt.core.formatter.blank_lines_before_method=1 +org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1 +org.eclipse.jdt.core.formatter.blank_lines_before_package=0 +org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1 +org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1 +org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_lambda_body=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line +org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false +org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false +org.eclipse.jdt.core.formatter.comment.format_block_comments=true +org.eclipse.jdt.core.formatter.comment.format_header=false +org.eclipse.jdt.core.formatter.comment.format_html=true +org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true +org.eclipse.jdt.core.formatter.comment.format_line_comments=true +org.eclipse.jdt.core.formatter.comment.format_source_code=false +org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true +org.eclipse.jdt.core.formatter.comment.indent_root_tags=false +org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=do not insert +org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=do not insert +org.eclipse.jdt.core.formatter.comment.line_length=90 +org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true +org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true +org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false +org.eclipse.jdt.core.formatter.compact_else_if=true +org.eclipse.jdt.core.formatter.continuation_indentation=2 +org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2 +org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off +org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on +org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false +org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true +org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true +org.eclipse.jdt.core.formatter.indent_empty_lines=false +org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true +org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true +org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true +org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false +org.eclipse.jdt.core.formatter.indentation.size=8 +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_after_type_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=insert +org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=insert +org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=insert +org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert +org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert +org.eclipse.jdt.core.formatter.insert_space_after_lambda_arrow=insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert +org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert +org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_lambda_arrow=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert +org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert +org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert +org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.join_lines_in_comments=true +org.eclipse.jdt.core.formatter.join_wrapped_lines=true +org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false +org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false +org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false +org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false +org.eclipse.jdt.core.formatter.lineSplit=90 +org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false +org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false +org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0 +org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1 +org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true +org.eclipse.jdt.core.formatter.tabulation.char=tab +org.eclipse.jdt.core.formatter.tabulation.size=4 +org.eclipse.jdt.core.formatter.use_on_off_tags=false +org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false +org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true +org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true +org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true diff --git a/spring-cloud-context/eclipse/org.eclipse.jdt.ui.prefs b/spring-cloud-context/eclipse/org.eclipse.jdt.ui.prefs new file mode 100644 index 00000000..fb4753fe --- /dev/null +++ b/spring-cloud-context/eclipse/org.eclipse.jdt.ui.prefs @@ -0,0 +1,125 @@ +cleanup.add_default_serial_version_id=true +cleanup.add_generated_serial_version_id=false +cleanup.add_missing_annotations=true +cleanup.add_missing_deprecated_annotations=true +cleanup.add_missing_methods=false +cleanup.add_missing_nls_tags=false +cleanup.add_missing_override_annotations=true +cleanup.add_missing_override_annotations_interface_methods=true +cleanup.add_serial_version_id=false +cleanup.always_use_blocks=true +cleanup.always_use_parentheses_in_expressions=false +cleanup.always_use_this_for_non_static_field_access=true +cleanup.always_use_this_for_non_static_method_access=false +cleanup.convert_functional_interfaces=false +cleanup.convert_to_enhanced_for_loop=false +cleanup.correct_indentation=false +cleanup.format_source_code=true +cleanup.format_source_code_changes_only=false +cleanup.insert_inferred_type_arguments=false +cleanup.make_local_variable_final=false +cleanup.make_parameters_final=false +cleanup.make_private_fields_final=false +cleanup.make_type_abstract_if_missing_method=false +cleanup.make_variable_declarations_final=false +cleanup.never_use_blocks=false +cleanup.never_use_parentheses_in_expressions=true +cleanup.organize_imports=true +cleanup.qualify_static_field_accesses_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true +cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true +cleanup.qualify_static_member_accesses_with_declaring_class=true +cleanup.qualify_static_method_accesses_with_declaring_class=false +cleanup.remove_private_constructors=true +cleanup.remove_redundant_type_arguments=true +cleanup.remove_trailing_whitespaces=true +cleanup.remove_trailing_whitespaces_all=true +cleanup.remove_trailing_whitespaces_ignore_empty=false +cleanup.remove_unnecessary_casts=true +cleanup.remove_unnecessary_nls_tags=false +cleanup.remove_unused_imports=true +cleanup.remove_unused_local_variables=false +cleanup.remove_unused_private_fields=true +cleanup.remove_unused_private_members=false +cleanup.remove_unused_private_methods=true +cleanup.remove_unused_private_types=true +cleanup.sort_members=false +cleanup.sort_members_all=false +cleanup.use_anonymous_class_creation=false +cleanup.use_blocks=true +cleanup.use_blocks_only_for_return_and_throw=false +cleanup.use_lambda=true +cleanup.use_parentheses_in_expressions=false +cleanup.use_this_for_non_static_field_access=true +cleanup.use_this_for_non_static_field_access_only_if_necessary=false +cleanup.use_this_for_non_static_method_access=false +cleanup.use_this_for_non_static_method_access_only_if_necessary=true +cleanup.use_type_arguments=false +cleanup_profile=_Spring Cloud Cleanup Conventions +cleanup_settings_version=2 +eclipse.preferences.version=1 +editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true +formatter_profile=_Spring Cloud Java Conventions +formatter_settings_version=12 +org.eclipse.jdt.ui.exception.name=e +org.eclipse.jdt.ui.gettersetter.use.is=false +org.eclipse.jdt.ui.ignorelowercasenames=true +org.eclipse.jdt.ui.importorder=java;javax;org;com;\#; +org.eclipse.jdt.ui.javadoc=true +org.eclipse.jdt.ui.keywordthis=false +org.eclipse.jdt.ui.ondemandthreshold=9999 +org.eclipse.jdt.ui.overrideannotation=true +org.eclipse.jdt.ui.staticondemandthreshold=9999 +org.eclipse.jdt.ui.text.custom_code_templates= +sp_cleanup.add_default_serial_version_id=true +sp_cleanup.add_generated_serial_version_id=false +sp_cleanup.add_missing_annotations=true +sp_cleanup.add_missing_deprecated_annotations=true +sp_cleanup.add_missing_methods=false +sp_cleanup.add_missing_nls_tags=false +sp_cleanup.add_missing_override_annotations=true +sp_cleanup.add_missing_override_annotations_interface_methods=true +sp_cleanup.add_serial_version_id=false +sp_cleanup.always_use_blocks=true +sp_cleanup.always_use_parentheses_in_expressions=true +sp_cleanup.always_use_this_for_non_static_field_access=true +sp_cleanup.always_use_this_for_non_static_method_access=false +sp_cleanup.convert_to_enhanced_for_loop=false +sp_cleanup.correct_indentation=false +sp_cleanup.format_source_code=true +sp_cleanup.format_source_code_changes_only=false +sp_cleanup.make_local_variable_final=false +sp_cleanup.make_parameters_final=false +sp_cleanup.make_private_fields_final=false +sp_cleanup.make_type_abstract_if_missing_method=false +sp_cleanup.make_variable_declarations_final=false +sp_cleanup.never_use_blocks=false +sp_cleanup.never_use_parentheses_in_expressions=false +sp_cleanup.on_save_use_additional_actions=true +sp_cleanup.organize_imports=true +sp_cleanup.qualify_static_field_accesses_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true +sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true +sp_cleanup.qualify_static_member_accesses_with_declaring_class=true +sp_cleanup.qualify_static_method_accesses_with_declaring_class=false +sp_cleanup.remove_private_constructors=true +sp_cleanup.remove_trailing_whitespaces=true +sp_cleanup.remove_trailing_whitespaces_all=true +sp_cleanup.remove_trailing_whitespaces_ignore_empty=false +sp_cleanup.remove_unnecessary_casts=true +sp_cleanup.remove_unnecessary_nls_tags=false +sp_cleanup.remove_unused_imports=true +sp_cleanup.remove_unused_local_variables=false +sp_cleanup.remove_unused_private_fields=true +sp_cleanup.remove_unused_private_members=false +sp_cleanup.remove_unused_private_methods=true +sp_cleanup.remove_unused_private_types=true +sp_cleanup.sort_members=false +sp_cleanup.sort_members_all=false +sp_cleanup.use_blocks=true +sp_cleanup.use_blocks_only_for_return_and_throw=false +sp_cleanup.use_parentheses_in_expressions=false +sp_cleanup.use_this_for_non_static_field_access=true +sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=false +sp_cleanup.use_this_for_non_static_method_access=false +sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true diff --git a/spring-cloud-context/pom.xml b/spring-cloud-context/pom.xml new file mode 100644 index 00000000..e0046559 --- /dev/null +++ b/spring-cloud-context/pom.xml @@ -0,0 +1,58 @@ + + + 4.0.0 + + + org.springframework.cloud + spring-cloud-commons-parent + 1.0.1.BUILD-SNAPSHOT + .. + + spring-cloud-context + jar + Spring Cloud Context + Spring Cloud Context + + + org.springframework.boot + spring-boot-starter-actuator + true + + + org.springframework.boot + spring-boot-starter-web + true + + + org.springframework.boot + spring-boot-starter-aop + true + + + org.springframework.security + spring-security-crypto + + + org.springframework.security + spring-security-rsa + true + + + org.springframework.integration + spring-integration-jmx + true + + + org.projectlombok + lombok + compile + true + + + org.springframework.boot + spring-boot-starter-test + test + + + diff --git a/src/main/java/org/springframework/cloud/autoconfigure/LifecycleMvcEndpointAutoConfiguration.java b/spring-cloud-context/src/main/java/org/springframework/cloud/autoconfigure/LifecycleMvcEndpointAutoConfiguration.java similarity index 100% rename from src/main/java/org/springframework/cloud/autoconfigure/LifecycleMvcEndpointAutoConfiguration.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/autoconfigure/LifecycleMvcEndpointAutoConfiguration.java diff --git a/src/main/java/org/springframework/cloud/autoconfigure/RefreshAutoConfiguration.java b/spring-cloud-context/src/main/java/org/springframework/cloud/autoconfigure/RefreshAutoConfiguration.java similarity index 100% rename from src/main/java/org/springframework/cloud/autoconfigure/RefreshAutoConfiguration.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/autoconfigure/RefreshAutoConfiguration.java diff --git a/src/main/java/org/springframework/cloud/bootstrap/BootstrapApplicationListener.java b/spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/BootstrapApplicationListener.java similarity index 100% rename from src/main/java/org/springframework/cloud/bootstrap/BootstrapApplicationListener.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/BootstrapApplicationListener.java diff --git a/src/main/java/org/springframework/cloud/bootstrap/BootstrapConfiguration.java b/spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/BootstrapConfiguration.java similarity index 100% rename from src/main/java/org/springframework/cloud/bootstrap/BootstrapConfiguration.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/BootstrapConfiguration.java diff --git a/src/main/java/org/springframework/cloud/bootstrap/config/PropertySourceBootstrapConfiguration.java b/spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/config/PropertySourceBootstrapConfiguration.java similarity index 100% rename from src/main/java/org/springframework/cloud/bootstrap/config/PropertySourceBootstrapConfiguration.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/config/PropertySourceBootstrapConfiguration.java diff --git a/src/main/java/org/springframework/cloud/bootstrap/config/PropertySourceBootstrapProperties.java b/spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/config/PropertySourceBootstrapProperties.java similarity index 100% rename from src/main/java/org/springframework/cloud/bootstrap/config/PropertySourceBootstrapProperties.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/config/PropertySourceBootstrapProperties.java diff --git a/src/main/java/org/springframework/cloud/bootstrap/config/PropertySourceLocator.java b/spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/config/PropertySourceLocator.java similarity index 100% rename from src/main/java/org/springframework/cloud/bootstrap/config/PropertySourceLocator.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/config/PropertySourceLocator.java diff --git a/src/main/java/org/springframework/cloud/bootstrap/config/RefreshEndpoint.java b/spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/config/RefreshEndpoint.java similarity index 100% rename from src/main/java/org/springframework/cloud/bootstrap/config/RefreshEndpoint.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/config/RefreshEndpoint.java diff --git a/src/main/java/org/springframework/cloud/bootstrap/encrypt/EncryptionBootstrapConfiguration.java b/spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/encrypt/EncryptionBootstrapConfiguration.java similarity index 100% rename from src/main/java/org/springframework/cloud/bootstrap/encrypt/EncryptionBootstrapConfiguration.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/encrypt/EncryptionBootstrapConfiguration.java diff --git a/src/main/java/org/springframework/cloud/bootstrap/encrypt/EnvironmentDecryptApplicationInitializer.java b/spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/encrypt/EnvironmentDecryptApplicationInitializer.java similarity index 100% rename from src/main/java/org/springframework/cloud/bootstrap/encrypt/EnvironmentDecryptApplicationInitializer.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/encrypt/EnvironmentDecryptApplicationInitializer.java diff --git a/src/main/java/org/springframework/cloud/bootstrap/encrypt/KeyProperties.java b/spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/encrypt/KeyProperties.java similarity index 100% rename from src/main/java/org/springframework/cloud/bootstrap/encrypt/KeyProperties.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/bootstrap/encrypt/KeyProperties.java diff --git a/src/main/java/org/springframework/cloud/context/config/BeanLifecycleDecorator.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/config/BeanLifecycleDecorator.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/config/BeanLifecycleDecorator.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/config/BeanLifecycleDecorator.java diff --git a/src/main/java/org/springframework/cloud/context/config/StandardBeanLifecycleDecorator.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/config/StandardBeanLifecycleDecorator.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/config/StandardBeanLifecycleDecorator.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/config/StandardBeanLifecycleDecorator.java diff --git a/src/main/java/org/springframework/cloud/context/config/annotation/RefreshScope.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/config/annotation/RefreshScope.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/config/annotation/RefreshScope.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/config/annotation/RefreshScope.java diff --git a/src/main/java/org/springframework/cloud/context/encrypt/EncryptorFactory.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/encrypt/EncryptorFactory.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/encrypt/EncryptorFactory.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/encrypt/EncryptorFactory.java diff --git a/src/main/java/org/springframework/cloud/context/encrypt/KeyFormatException.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/encrypt/KeyFormatException.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/encrypt/KeyFormatException.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/encrypt/KeyFormatException.java diff --git a/src/main/java/org/springframework/cloud/context/environment/EnvironmentChangeEvent.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/environment/EnvironmentChangeEvent.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/environment/EnvironmentChangeEvent.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/environment/EnvironmentChangeEvent.java diff --git a/src/main/java/org/springframework/cloud/context/environment/EnvironmentManager.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/environment/EnvironmentManager.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/environment/EnvironmentManager.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/environment/EnvironmentManager.java diff --git a/src/main/java/org/springframework/cloud/context/environment/EnvironmentManagerMvcEndpoint.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/environment/EnvironmentManagerMvcEndpoint.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/environment/EnvironmentManagerMvcEndpoint.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/environment/EnvironmentManagerMvcEndpoint.java diff --git a/src/main/java/org/springframework/cloud/context/properties/ConfigurationPropertiesRebinder.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/properties/ConfigurationPropertiesRebinder.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/properties/ConfigurationPropertiesRebinder.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/properties/ConfigurationPropertiesRebinder.java diff --git a/src/main/java/org/springframework/cloud/context/restart/RestartEndpoint.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/restart/RestartEndpoint.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/restart/RestartEndpoint.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/restart/RestartEndpoint.java diff --git a/src/main/java/org/springframework/cloud/context/restart/RestartListener.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/restart/RestartListener.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/restart/RestartListener.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/restart/RestartListener.java diff --git a/src/main/java/org/springframework/cloud/context/restart/RestartMvcEndpoint.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/restart/RestartMvcEndpoint.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/restart/RestartMvcEndpoint.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/restart/RestartMvcEndpoint.java diff --git a/src/main/java/org/springframework/cloud/context/scope/GenericScope.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/scope/GenericScope.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/scope/GenericScope.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/scope/GenericScope.java diff --git a/src/main/java/org/springframework/cloud/context/scope/ScopeCache.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/scope/ScopeCache.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/scope/ScopeCache.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/scope/ScopeCache.java diff --git a/src/main/java/org/springframework/cloud/context/scope/StandardScopeCache.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/scope/StandardScopeCache.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/scope/StandardScopeCache.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/scope/StandardScopeCache.java diff --git a/src/main/java/org/springframework/cloud/context/scope/refresh/RefreshScope.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/scope/refresh/RefreshScope.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/scope/refresh/RefreshScope.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/scope/refresh/RefreshScope.java diff --git a/src/main/java/org/springframework/cloud/context/scope/refresh/RefreshScopeRefreshedEvent.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/scope/refresh/RefreshScopeRefreshedEvent.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/scope/refresh/RefreshScopeRefreshedEvent.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/scope/refresh/RefreshScopeRefreshedEvent.java diff --git a/src/main/java/org/springframework/cloud/context/scope/thread/ThreadLocalScopeCache.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/scope/thread/ThreadLocalScopeCache.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/scope/thread/ThreadLocalScopeCache.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/scope/thread/ThreadLocalScopeCache.java diff --git a/src/main/java/org/springframework/cloud/context/scope/thread/ThreadScope.java b/spring-cloud-context/src/main/java/org/springframework/cloud/context/scope/thread/ThreadScope.java similarity index 100% rename from src/main/java/org/springframework/cloud/context/scope/thread/ThreadScope.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/context/scope/thread/ThreadScope.java diff --git a/src/main/java/org/springframework/cloud/endpoint/GenericPostableMvcEndpoint.java b/spring-cloud-context/src/main/java/org/springframework/cloud/endpoint/GenericPostableMvcEndpoint.java similarity index 100% rename from src/main/java/org/springframework/cloud/endpoint/GenericPostableMvcEndpoint.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/endpoint/GenericPostableMvcEndpoint.java diff --git a/src/main/java/org/springframework/cloud/logging/LoggingRebinder.java b/spring-cloud-context/src/main/java/org/springframework/cloud/logging/LoggingRebinder.java similarity index 100% rename from src/main/java/org/springframework/cloud/logging/LoggingRebinder.java rename to spring-cloud-context/src/main/java/org/springframework/cloud/logging/LoggingRebinder.java diff --git a/src/main/resources/META-INF/spring.factories b/spring-cloud-context/src/main/resources/META-INF/spring.factories similarity index 75% rename from src/main/resources/META-INF/spring.factories rename to spring-cloud-context/src/main/resources/META-INF/spring.factories index 372a099f..f49c0d6e 100644 --- a/src/main/resources/META-INF/spring.factories +++ b/spring-cloud-context/src/main/resources/META-INF/spring.factories @@ -1,8 +1,5 @@ # AutoConfiguration org.springframework.boot.autoconfigure.EnableAutoConfiguration=\ -org.springframework.cloud.client.CommonsClientAutoConfiguration,\ -org.springframework.cloud.client.discovery.noop.NoopDiscoveryClientAutoConfiguration,\ -org.springframework.cloud.client.loadbalancer.LoadBalancerAutoConfiguration,\ org.springframework.cloud.autoconfigure.RefreshAutoConfiguration,\ org.springframework.cloud.autoconfigure.LifecycleMvcEndpointAutoConfiguration diff --git a/src/test/java/org/springframework/cloud/bootstrap/BootstrapDisabledAutoConfigurationIntegrationTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/bootstrap/BootstrapDisabledAutoConfigurationIntegrationTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/bootstrap/BootstrapDisabledAutoConfigurationIntegrationTests.java rename to spring-cloud-context/src/test/java/org/springframework/cloud/bootstrap/BootstrapDisabledAutoConfigurationIntegrationTests.java diff --git a/src/test/java/org/springframework/cloud/bootstrap/BootstrapOrderingAutoConfigurationIntegrationTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/bootstrap/BootstrapOrderingAutoConfigurationIntegrationTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/bootstrap/BootstrapOrderingAutoConfigurationIntegrationTests.java rename to spring-cloud-context/src/test/java/org/springframework/cloud/bootstrap/BootstrapOrderingAutoConfigurationIntegrationTests.java diff --git a/src/test/java/org/springframework/cloud/bootstrap/config/BootstrapConfigurationTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/bootstrap/config/BootstrapConfigurationTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/bootstrap/config/BootstrapConfigurationTests.java rename to spring-cloud-context/src/test/java/org/springframework/cloud/bootstrap/config/BootstrapConfigurationTests.java diff --git a/src/test/java/org/springframework/cloud/bootstrap/encrypt/EncryptionBootstrapConfigurationTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/bootstrap/encrypt/EncryptionBootstrapConfigurationTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/bootstrap/encrypt/EncryptionBootstrapConfigurationTests.java rename to spring-cloud-context/src/test/java/org/springframework/cloud/bootstrap/encrypt/EncryptionBootstrapConfigurationTests.java diff --git a/src/test/java/org/springframework/cloud/bootstrap/encrypt/EnvironmentDecryptApplicationListenerTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/bootstrap/encrypt/EnvironmentDecryptApplicationListenerTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/bootstrap/encrypt/EnvironmentDecryptApplicationListenerTests.java rename to spring-cloud-context/src/test/java/org/springframework/cloud/bootstrap/encrypt/EnvironmentDecryptApplicationListenerTests.java diff --git a/src/test/java/org/springframework/cloud/context/environment/EnvironmentManagerIntegrationTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/context/environment/EnvironmentManagerIntegrationTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/context/environment/EnvironmentManagerIntegrationTests.java rename to spring-cloud-context/src/test/java/org/springframework/cloud/context/environment/EnvironmentManagerIntegrationTests.java diff --git a/src/test/java/org/springframework/cloud/context/properties/ConfigurationPropertiesRebinderIntegrationTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/context/properties/ConfigurationPropertiesRebinderIntegrationTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/context/properties/ConfigurationPropertiesRebinderIntegrationTests.java rename to spring-cloud-context/src/test/java/org/springframework/cloud/context/properties/ConfigurationPropertiesRebinderIntegrationTests.java diff --git a/src/test/java/org/springframework/cloud/context/restart/RestartIntegrationTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/context/restart/RestartIntegrationTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/context/restart/RestartIntegrationTests.java rename to spring-cloud-context/src/test/java/org/springframework/cloud/context/restart/RestartIntegrationTests.java diff --git a/src/test/java/org/springframework/cloud/context/scope/refresh/ImportRefreshScopeIntegrationTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/context/scope/refresh/ImportRefreshScopeIntegrationTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/context/scope/refresh/ImportRefreshScopeIntegrationTests.java rename to spring-cloud-context/src/test/java/org/springframework/cloud/context/scope/refresh/ImportRefreshScopeIntegrationTests.java diff --git a/src/test/java/org/springframework/cloud/context/scope/refresh/MoreRefreshScopeIntegrationTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/context/scope/refresh/MoreRefreshScopeIntegrationTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/context/scope/refresh/MoreRefreshScopeIntegrationTests.java rename to spring-cloud-context/src/test/java/org/springframework/cloud/context/scope/refresh/MoreRefreshScopeIntegrationTests.java diff --git a/src/test/java/org/springframework/cloud/context/scope/refresh/RefreshEndpointIntegrationTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/context/scope/refresh/RefreshEndpointIntegrationTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/context/scope/refresh/RefreshEndpointIntegrationTests.java rename to spring-cloud-context/src/test/java/org/springframework/cloud/context/scope/refresh/RefreshEndpointIntegrationTests.java diff --git a/src/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeConcurrencyTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeConcurrencyTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeConcurrencyTests.java rename to spring-cloud-context/src/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeConcurrencyTests.java diff --git a/src/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeConfigurationTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeConfigurationTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeConfigurationTests.java rename to spring-cloud-context/src/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeConfigurationTests.java diff --git a/src/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeIntegrationTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeIntegrationTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeIntegrationTests.java rename to spring-cloud-context/src/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeIntegrationTests.java diff --git a/src/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeWebIntegrationTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeWebIntegrationTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeWebIntegrationTests.java rename to spring-cloud-context/src/test/java/org/springframework/cloud/context/scope/refresh/RefreshScopeWebIntegrationTests.java diff --git a/src/test/java/org/springframework/cloud/logging/LoggingRebinderTests.java b/spring-cloud-context/src/test/java/org/springframework/cloud/logging/LoggingRebinderTests.java similarity index 100% rename from src/test/java/org/springframework/cloud/logging/LoggingRebinderTests.java rename to spring-cloud-context/src/test/java/org/springframework/cloud/logging/LoggingRebinderTests.java diff --git a/spring-cloud-context/src/test/resources/application-encrypt.properties b/spring-cloud-context/src/test/resources/application-encrypt.properties new file mode 100644 index 00000000..b1329f64 --- /dev/null +++ b/spring-cloud-context/src/test/resources/application-encrypt.properties @@ -0,0 +1 @@ +foo: {cipher}e4e061f9fe39ba5b14d8012d2f17d39775606039409b71ed4be0fdd033d5324a diff --git a/spring-cloud-context/src/test/resources/application.properties b/spring-cloud-context/src/test/resources/application.properties new file mode 100644 index 00000000..961e7d22 --- /dev/null +++ b/spring-cloud-context/src/test/resources/application.properties @@ -0,0 +1,5 @@ +message: Hello scope! +delay: 0 +debug: true +#logging.level.org.springframework.web: DEBUG +#logging.level.org.springframework.context.annotation: DEBUG \ No newline at end of file diff --git a/spring-cloud-context/src/test/resources/bootstrap-encrypt.properties b/spring-cloud-context/src/test/resources/bootstrap-encrypt.properties new file mode 100644 index 00000000..3035e009 --- /dev/null +++ b/spring-cloud-context/src/test/resources/bootstrap-encrypt.properties @@ -0,0 +1 @@ +bar: {cipher}6154ca04d4bb6144d672c4e3d750b5147116dd381946d51fa44f8bc25dc256f4 \ No newline at end of file diff --git a/spring-cloud-context/src/test/resources/bootstrap-parent.properties b/spring-cloud-context/src/test/resources/bootstrap-parent.properties new file mode 100644 index 00000000..0c36bbdd --- /dev/null +++ b/spring-cloud-context/src/test/resources/bootstrap-parent.properties @@ -0,0 +1 @@ +info.name: parent \ No newline at end of file diff --git a/spring-cloud-context/src/test/resources/bootstrap.properties b/spring-cloud-context/src/test/resources/bootstrap.properties new file mode 100644 index 00000000..9ec10bf9 --- /dev/null +++ b/spring-cloud-context/src/test/resources/bootstrap.properties @@ -0,0 +1,2 @@ +spring.main.sources: org.springframework.cloud.bootstrap.config.BootstrapConfigurationTests.PropertySourceConfiguration +info.name: child diff --git a/spring-cloud-context/src/test/resources/external-properties/bootstrap.properties b/spring-cloud-context/src/test/resources/external-properties/bootstrap.properties new file mode 100644 index 00000000..925265df --- /dev/null +++ b/spring-cloud-context/src/test/resources/external-properties/bootstrap.properties @@ -0,0 +1 @@ +info.name: externalPropertiesInfoName \ No newline at end of file diff --git a/spring-cloud-context/src/test/resources/other.properties b/spring-cloud-context/src/test/resources/other.properties new file mode 100644 index 00000000..dc756282 --- /dev/null +++ b/spring-cloud-context/src/test/resources/other.properties @@ -0,0 +1 @@ +spring.application.name: main \ No newline at end of file diff --git a/spring-cloud-context/src/test/resources/plain.properties b/spring-cloud-context/src/test/resources/plain.properties new file mode 100644 index 00000000..aa8f5408 --- /dev/null +++ b/spring-cloud-context/src/test/resources/plain.properties @@ -0,0 +1 @@ +spring.application.name: app diff --git a/spring-cloud-context/src/test/resources/server.jks b/spring-cloud-context/src/test/resources/server.jks new file mode 100644 index 0000000000000000000000000000000000000000..560be5fed77efd4c75d2ca49a33bc6eb616b1af4 GIT binary patch literal 2239 zcmchY`8yPh7RP7C%rIjJLzY)zELn=NhDi1$y_4*e8X9X^Cu0pmj2Ow9$i74&`!?Ci zOPb7;C2J95j2C4a*OIP!?tPy3FStLPA3o>#{&1e}InVbTtsSia007W&0e=_lZYUlX zg!jRP9(ODO>AD#J00fLCLI7xPC|m&w1Ow$kyg(oX049Q0e@x9;9QG?AIP}u(CND%g zNL5^8ki_Z1zB6X`UVR^kr^@)Za%CW-5U~S{(x=E5SHze8uy8g$xVXbqb9SqI-=~O@ zDZ-raMhb2A?eA;^2tpvt&n0=Tv~MNkS+5cI%2ij=N0R1?xp!A9C1<%SwZ8R?wlAsRHE9}}VzAy?cNnNwj3mGJ ztO-#a(awjYi`pB4QZ3Sa>N48Czr(&Q=D8EzCsp2oRlI1!@Jy_}uMmM35Rjvce76Rn{sAPO-#KSC6*SKdCs(y+|98led18K-}~uxm*ZA&V^CZTUPC=1H?jjd$lM3^4l7AqAr-bX7jb``=cD5 zIMw4W+r|afp*>WF;-%HTL*$lgBv>W;L8@p+@?Kk>K6P2+eo?#rDto48>|$m{!Mv~| zZTB|eUT&A*oNw=a){D@F+($ge__?FdLyRjz*lRDez{=JYg4t z?T~Nt7#sXK7fcsAcfuQGw6HUwEVz3Mz5@Lwa*Hl=t%Lmw?4Z9v8jwg8nK}#Sqj)?@ z+BHxVUHV)dfenu1h-K@``b@EO8Sw3V_&_T`&^p}|BI4Vx{pNX5ssPQYGTg0~$E>ZZ zxZ>hl6L&y&)hn3)$)D@C!aF_SboqQait#%U_4yu{^2MAuH>-}q#;M{-yd1sEc}}h! z!#R{Sd)}9cwF7759L{M(#|V;PRF~2@PreCz|3njzoAGE%6!otuPeTYZZ^g%Z#3eRn zfshtdY)|?AhZHX!nd2(_w=WHNxPONdAds*OoAny-|6E(ZSi8K@(5{zd?hjA#*fa0A5i#N z%rmW5VdEX0hc-bhk02~eAijXoC+$e9-XlfzUF})OwsJnHR0sF zfatDpl0ix+$9?M5TCe{>$N+shXTFzo#jerT+q%)Oc~h}D?gBV^5n;FCWxdgBw&;N7 zN{wjk`x>K^_Es|RoSRFxBcx{L(Kp#025&_laa2I;_fiG}I zpoS4qhz7VB4~TLti;qdy^LItOQ4{U3yu8ra=~pg66Esfh%l#1~{PL5Y`|o&!I4G*4 zwEzIN05p;9E}96kEo1`$K_Kvn{YyP)E+|Ys-YkBX3kc*q4onYaPBaY4W($TQLAKV) z+-Srv;6OsG@mM@gnG4PNi`kK2Loa-&vH%+S3*krvCeQ=x>lKE@d-?hPPsND@+xmLp zm62%PUn({v+#csDZjB2J#s#8J3vwx|qgBybDk^9VRb{8&sDVEJU;O_KLIk4zX~OZB zU?T!g0MJAr97F^H0j<}O_wE`aZ!*0iCzaqH1hqf0+fr9?67F{Ebpew?$mhB&83hK4 zbBl&033s?#ah`4>B<<81CH3DC00DJZ)gi+s=F+}Lxi@H@0y83l;?Cqd`eXQ#9@lj+ z*#y&cb7JoMR$hRii5{jpak1L`W0@XCEZzJ8f+a?)$YvmD!kR3%;Q7;6H~C=qL9xcN zE25LR2KygI@^3lUo~-IaK@~>Y$IDilLxP+&>l4NrZp_yWTXyE$WaCT@$hiIBImvxD zhhd8Uq1WXUQzT+lYPkC>XO}>?TQ5vITGGgjB1B6T{_EE0gL2hVwBV}8_iuk9*`Z*d znazx?DX@+`hz$q;mPnw*(5H^Kc#0c*63j1Km`l&8nC&gig1yvy+y)X=VB!C1;_)RN zn+OCro@z?g7#s%qHRrwC^N|V3zjS?-I9tyi;S%$8bY$=6&e`}fp~OZ z|EKLrH4p2BRMUw)`_g&D+e3dF>4S>M{md%)*Au18*)bhS+QV7_<))PO@Rl^c)wbtG z4`Se;rC}V&=!-~igc?GjgpvaLkU=Y6o=rx%ZUo5@86BYt%_zS7>8*CS==nH7KCXF7 z&o@r*mXjiJChyy>&-+zlxc9rzJuA5g3ev~OryKWVMcd_O(`6AD4W$M$SEiOftl^v?Ht^0YZuAWk}0Qx X87oqp`%q!o8#z_2ZOluhie~)>Rnq1* literal 0 HcmV?d00001