Skip to content

Instantly share code, notes, and snippets.

@songyunlu
Created January 8, 2015 03:14
Show Gist options
  • Save songyunlu/26e2e958506292c33542 to your computer and use it in GitHub Desktop.
Save songyunlu/26e2e958506292c33542 to your computer and use it in GitHub Desktop.
main class of config server.
@SpringBootApplication
@EnableConfigServer
public class ConfigServerApp {
@Bean
public EnvironmentRepository repository() {
return new CassandraEnvironmentRepository();
//return new ZooKeeperEnvironmentRepository();
}
public static void main(String[] args) {
List<String> arguments = Lists.asList("--spring.cloud.bootstrap.enabled=false", args);
SpringApplication.run(ConfigServerApp.class, arguments.toArray(new String[arguments.size()]));
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment