Skip to content

Commit

Permalink
Merge pull request spring-projects#12725 from izeye:destroy-method
Browse files Browse the repository at this point in the history
* pr/12725:
  Remove destroyMethod attribute in @bean for MeterRegistry
  • Loading branch information
snicoll committed Apr 3, 2018
2 parents 3568019 + 4ab4398 commit 958f3d5
Show file tree
Hide file tree
Showing 10 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ public String get(String k) {
@Import(BaseConfiguration.class)
static class CustomRegistryConfiguration {

@Bean(destroyMethod = "stop")
@Bean
public AtlasMeterRegistry customRegistry(AtlasConfig config, Clock clock) {
return new AtlasMeterRegistry(config, clock);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ public String get(String k) {
@Import(BaseConfiguration.class)
static class CustomRegistryConfiguration {

@Bean(destroyMethod = "stop")
@Bean
public DatadogMeterRegistry customRegistry(DatadogConfig config, Clock clock) {
return new DatadogMeterRegistry(config, clock);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ public String get(String k) {
@Import(BaseConfiguration.class)
static class CustomRegistryConfiguration {

@Bean(destroyMethod = "stop")
@Bean
public GangliaMeterRegistry customRegistry(GangliaConfig config, Clock clock) {
return new GangliaMeterRegistry(config, clock);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ public String get(String k) {
@Import(BaseConfiguration.class)
static class CustomRegistryConfiguration {

@Bean(destroyMethod = "stop")
@Bean
public GraphiteMeterRegistry customRegistry(GraphiteConfig config, Clock clock) {
return new GraphiteMeterRegistry(config, clock);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ public String get(String k) {
@Import(BaseConfiguration.class)
static class CustomRegistryConfiguration {

@Bean(destroyMethod = "stop")
@Bean
public InfluxMeterRegistry customRegistry(InfluxConfig config, Clock clock) {
return new InfluxMeterRegistry(config, clock);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ public String get(String k) {
@Import(BaseConfiguration.class)
static class CustomRegistryConfiguration {

@Bean(destroyMethod = "stop")
@Bean
public JmxMeterRegistry customRegistry(JmxConfig config, Clock clock) {
return new JmxMeterRegistry(config, clock);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ public String get(String k) {
@Import(BaseConfiguration.class)
static class CustomRegistryConfiguration {

@Bean(destroyMethod = "stop")
@Bean
public NewRelicMeterRegistry customRegistry(NewRelicConfig config, Clock clock) {
return new NewRelicMeterRegistry(config, clock);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ public String get(String k) {
@Import(BaseConfiguration.class)
static class CustomRegistryConfiguration {

@Bean(destroyMethod = "stop")
@Bean
public SignalFxMeterRegistry customRegistry(SignalFxConfig config, Clock clock) {
return new SignalFxMeterRegistry(config, clock);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ public String get(String k) {
@Import(BaseConfiguration.class)
static class CustomRegistryConfiguration {

@Bean(destroyMethod = "stop")
@Bean
public StatsdMeterRegistry customRegistry(StatsdConfig config, Clock clock) {
return new StatsdMeterRegistry(config, clock);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ public String uri() {
@Import(BaseConfiguration.class)
static class CustomRegistryConfiguration {

@Bean(destroyMethod = "stop")
@Bean
public WavefrontMeterRegistry customRegistry(WavefrontConfig config,
Clock clock) {
return new WavefrontMeterRegistry(config, clock);
Expand Down

0 comments on commit 958f3d5

Please sign in to comment.