{"action":"created","issue":{"url":"https://api.github.com/repos/spring-cloud/spring-cloud-stream/issues/227","labels_url":"https://api.github.com/repos/spring-cloud/spring-cloud-stream/issues/227/labels{/name}","comments_url":"https://api.github.com/repos/spring-cloud/spring-cloud-stream/issues/227/comments","events_url":"https://api.github.com/repos/spring-cloud/spring-cloud-stream/issues/227/events","html_url":"https://github.com/spring-cloud/spring-cloud-stream/issues/227","id":121356077,"number":227,"title":"Potential issue with JMX","user":{"login":"TabberGit","id":1644417,"avatar_url":"https://avatars.githubusercontent.com/u/1644417?v=3","gravatar_id":"","url":"https://api.github.com/users/TabberGit","html_url":"https://github.com/TabberGit","followers_url":"https://api.github.com/users/TabberGit/followers","following_url":"https://api.github.com/users/TabberGit/following{/other_user}","gists_url":"https://api.github.com/users/TabberGit/gists{/gist_id}","starred_url":"https://api.github.com/users/TabberGit/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TabberGit/subscriptions","organizations_url":"https://api.github.com/users/TabberGit/orgs","repos_url":"https://api.github.com/users/TabberGit/repos","events_url":"https://api.github.com/users/TabberGit/events{/privacy}","received_events_url":"https://api.github.com/users/TabberGit/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-12-09T22:31:52Z","updated_at":"2015-12-09T22:53:16Z","closed_at":null,"body":"Have a new issue with spring-boot applications (e.g. spring-cloud-config-server & spring-cloud-eureka-server) where the same JMX bean is getting registered twice causing a failure.\r\n\r\nSeems that the initial registration is coming from a call on the spring-boot app startup into\r\n\r\n**org.springframework.boot.admin.SpringApplicationAdminMXBeanRegistrar**\r\n\r\nand the later call comes from the ChannelBindingService.\r\n\r\nUsing the **1.0.0.BUILD-SNAPSHOT** for spring-cloud-stream, the **1.1.0.BUILD-SNAPSHOT** for the spring-cloud-starter, and the **1.3.0.BUILD_SNAPSHOT** for spring-boot\r\n\r\nStacktrace for ref of the fail on the ChannelBindingService call to afterPropertiesSet():\r\n\r\n    Caused by: javax.management.InstanceAlreadyExistsException: org.springframework.boot:type=Admin,name=SpringApplication\r\n\tat com.sun.jmx.mbeanserver.Repository.addMBean(Repository.java:437) ~[na:1.8.0_60]\r\n\tat com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerWithRepository(DefaultMBeanServerInterceptor.java:1898) ~[na:1.8.0_60]\r\n\tat com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerDynamicMBean(DefaultMBeanServerInterceptor.java:966) ~[na:1.8.0_60]\r\n\tat com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerObject(DefaultMBeanServerInterceptor.java:900) ~[na:1.8.0_60]\r\n\tat com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.registerMBean(DefaultMBeanServerInterceptor.java:324) ~[na:1.8.0_60]\r\n\tat com.sun.jmx.mbeanserver.JmxMBeanServer.registerMBean(JmxMBeanServer.java:522) ~[na:1.8.0_60]\r\n\tat org.springframework.boot.admin.SpringApplicationAdminMXBeanRegistrar.afterPropertiesSet(SpringApplicationAdminMXBeanRegistrar.java:89) ~[spring-boot-1.3.0.BUILD-SNAPSHOT.jar:1.3.0.BUILD-SNAPSHOT]\r\n\tat org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1637) ~[spring-beans-4.2.3.RELEASE.jar:4.2.3.RELEASE]\r\n\tat org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1574) ~[spring-beans-4.2.3.RELEASE.jar:4.2.3.RELEASE]\r\n"},"comment":{"url":"https://api.github.com/repos/spring-cloud/spring-cloud-stream/issues/comments/163426841","html_url":"https://github.com/spring-cloud/spring-cloud-stream/issues/227#issuecomment-163426841","issue_url":"https://api.github.com/repos/spring-cloud/spring-cloud-stream/issues/227","id":163426841,"user":{"login":"TabberGit","id":1644417,"avatar_url":"https://avatars.githubusercontent.com/u/1644417?v=3","gravatar_id":"","url":"https://api.github.com/users/TabberGit","html_url":"https://github.com/TabberGit","followers_url":"https://api.github.com/users/TabberGit/followers","following_url":"https://api.github.com/users/TabberGit/following{/other_user}","gists_url":"https://api.github.com/users/TabberGit/gists{/gist_id}","starred_url":"https://api.github.com/users/TabberGit/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TabberGit/subscriptions","organizations_url":"https://api.github.com/users/TabberGit/orgs","repos_url":"https://api.github.com/users/TabberGit/repos","events_url":"https://api.github.com/users/TabberGit/events{/privacy}","received_events_url":"https://api.github.com/users/TabberGit/received_events","type":"User","site_admin":false},"created_at":"2015-12-09T22:53:16Z","updated_at":"2015-12-09T22:53:16Z","body":"Still need the code?  I can post a fat-jar if you'd like"}}