Browse Source

Rename spring.{profile}.active => {profiles}

Same for spring.profiles.default
pull/7/head
Chris Beams 14 years ago
parent
commit
c5063004eb
  1. 4
      org.springframework.beans/src/main/resources/org/springframework/beans/factory/xml/spring-beans-3.1.xsd
  2. 2
      org.springframework.context/src/main/java/org/springframework/context/annotation/Profile.java
  3. 4
      org.springframework.core/src/main/java/org/springframework/core/env/AbstractEnvironment.java
  4. 2
      org.springframework.core/src/main/java/org/springframework/core/env/Environment.java

4
org.springframework.beans/src/main/resources/org/springframework/beans/factory/xml/spring-beans-3.1.xsd

@ -94,8 +94,8 @@ @@ -94,8 +94,8 @@
ConfigurableEnvironment#setDefaultProfiles(String...)
Properties (typically through -D system properties, environment variables, or servlet context init params):
spring.profile.active=p1,p2
spring.profile.default=p1,p2
spring.profiles.active=p1,p2
spring.profiles.default=p1,p2
]]></xsd:documentation>
</xsd:annotation>
</xsd:attribute>

2
org.springframework.context/src/main/java/org/springframework/context/annotation/Profile.java

@ -30,7 +30,7 @@ import org.springframework.core.env.ConfigurableEnvironment; @@ -30,7 +30,7 @@ import org.springframework.core.env.ConfigurableEnvironment;
*
* <p>A <em>profile</em> is a named logical grouping that may be activated programatically via
* {@link ConfigurableEnvironment#setActiveProfiles} or declaratively through setting the
* {@link AbstractEnvironment#ACTIVE_PROFILES_PROPERTY_NAME spring.profile.active} property,
* {@link AbstractEnvironment#ACTIVE_PROFILES_PROPERTY_NAME spring.profiles.active} property,
* usually through JVM system properties, as an environment variable, or for web applications
* as a Servlet context parameter in {@code web.xml}.
*

4
org.springframework.core/src/main/java/org/springframework/core/env/AbstractEnvironment.java vendored

@ -45,13 +45,13 @@ public abstract class AbstractEnvironment implements ConfigurableEnvironment { @@ -45,13 +45,13 @@ public abstract class AbstractEnvironment implements ConfigurableEnvironment {
* Name of property to set to specify active profiles: {@value}. May be comma delimited.
* @see ConfigurableEnvironment#setActiveProfiles
*/
public static final String ACTIVE_PROFILES_PROPERTY_NAME = "spring.profile.active";
public static final String ACTIVE_PROFILES_PROPERTY_NAME = "spring.profiles.active";
/**
* Name of property to set to specify default profiles: {@value}. May be comma delimited.
* @see ConfigurableEnvironment#setDefaultProfiles
*/
public static final String DEFAULT_PROFILES_PROPERTY_NAME = "spring.profile.default";
public static final String DEFAULT_PROFILES_PROPERTY_NAME = "spring.profiles.default";
protected final Log logger = LogFactory.getLog(getClass());

2
org.springframework.core/src/main/java/org/springframework/core/env/Environment.java vendored

@ -69,7 +69,7 @@ public interface Environment extends PropertyResolver { @@ -69,7 +69,7 @@ public interface Environment extends PropertyResolver {
* Return the set of profiles explicitly made active for this environment. Profiles are used for
* creating logical groupings of bean definitions to be registered conditionally, often based on
* deployment environment. Profiles can be activated by setting {@linkplain
* AbstractEnvironment#ACTIVE_PROFILES_PROPERTY_NAME "spring.profile.active"} as a system property
* AbstractEnvironment#ACTIVE_PROFILES_PROPERTY_NAME "spring.profiles.active"} as a system property
* or by calling {@link ConfigurableEnvironment#setActiveProfiles(String...)}.
*
* <p>If no profiles have explicitly been specified as active, then any 'default' profiles will implicitly

Loading…
Cancel
Save