首页>代码>Spring Boot配置@Profile注解加载不同环境的配置文件实例>/profiles/src/main/java/com/memorynotfound/springboot/ProductionConfiguration.java
package com.memorynotfound.springboot;
import org.springframework.context.annotation.Profile;
import org.springframework.stereotype.Service;
@Service
@Profile({"prod"})
public class ProductionConfiguration implements Configuration {
@Override
public String getName() {
return "production profile";
}
}

最近下载
最近浏览
