{"action":"closed","issue":{"url":"https://api.github.com/repos/apache/dubbo/issues/4690","repository_url":"https://api.github.com/repos/apache/dubbo","labels_url":"https://api.github.com/repos/apache/dubbo/issues/4690/labels{/name}","comments_url":"https://api.github.com/repos/apache/dubbo/issues/4690/comments","events_url":"https://api.github.com/repos/apache/dubbo/issues/4690/events","html_url":"https://github.com/apache/dubbo/issues/4690","id":474038382,"node_id":"MDU6SXNzdWU0NzQwMzgzODI=","number":4690,"title":"[Issue] AnnotatedBeanDefinitionRegistryUtils#registerBeans can't remove the duplicated bean definitions","user":{"login":"mercyblitz","id":533114,"node_id":"MDQ6VXNlcjUzMzExNA==","avatar_url":"https://avatars0.githubusercontent.com/u/533114?v=4","gravatar_id":"","url":"https://api.github.com/users/mercyblitz","html_url":"https://github.com/mercyblitz","followers_url":"https://api.github.com/users/mercyblitz/followers","following_url":"https://api.github.com/users/mercyblitz/following{/other_user}","gists_url":"https://api.github.com/users/mercyblitz/gists{/gist_id}","starred_url":"https://api.github.com/users/mercyblitz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mercyblitz/subscriptions","organizations_url":"https://api.github.com/users/mercyblitz/orgs","repos_url":"https://api.github.com/users/mercyblitz/repos","events_url":"https://api.github.com/users/mercyblitz/events{/privacy}","received_events_url":"https://api.github.com/users/mercyblitz/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":{"login":"mercyblitz","id":533114,"node_id":"MDQ6VXNlcjUzMzExNA==","avatar_url":"https://avatars0.githubusercontent.com/u/533114?v=4","gravatar_id":"","url":"https://api.github.com/users/mercyblitz","html_url":"https://github.com/mercyblitz","followers_url":"https://api.github.com/users/mercyblitz/followers","following_url":"https://api.github.com/users/mercyblitz/following{/other_user}","gists_url":"https://api.github.com/users/mercyblitz/gists{/gist_id}","starred_url":"https://api.github.com/users/mercyblitz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mercyblitz/subscriptions","organizations_url":"https://api.github.com/users/mercyblitz/orgs","repos_url":"https://api.github.com/users/mercyblitz/repos","events_url":"https://api.github.com/users/mercyblitz/events{/privacy}","received_events_url":"https://api.github.com/users/mercyblitz/received_events","type":"User","site_admin":false},"assignees":[{"login":"mercyblitz","id":533114,"node_id":"MDQ6VXNlcjUzMzExNA==","avatar_url":"https://avatars0.githubusercontent.com/u/533114?v=4","gravatar_id":"","url":"https://api.github.com/users/mercyblitz","html_url":"https://github.com/mercyblitz","followers_url":"https://api.github.com/users/mercyblitz/followers","following_url":"https://api.github.com/users/mercyblitz/following{/other_user}","gists_url":"https://api.github.com/users/mercyblitz/gists{/gist_id}","starred_url":"https://api.github.com/users/mercyblitz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mercyblitz/subscriptions","organizations_url":"https://api.github.com/users/mercyblitz/orgs","repos_url":"https://api.github.com/users/mercyblitz/repos","events_url":"https://api.github.com/users/mercyblitz/events{/privacy}","received_events_url":"https://api.github.com/users/mercyblitz/received_events","type":"User","site_admin":false}],"milestone":{"url":"https://api.github.com/repos/apache/dubbo/milestones/27","html_url":"https://github.com/apache/dubbo/milestone/27","labels_url":"https://api.github.com/repos/apache/dubbo/milestones/27/labels","id":4418980,"node_id":"MDk6TWlsZXN0b25lNDQxODk4MA==","number":27,"title":"2.7.4","description":"","creator":{"login":"chickenlj","id":18097545,"node_id":"MDQ6VXNlcjE4MDk3NTQ1","avatar_url":"https://avatars1.githubusercontent.com/u/18097545?v=4","gravatar_id":"","url":"https://api.github.com/users/chickenlj","html_url":"https://github.com/chickenlj","followers_url":"https://api.github.com/users/chickenlj/followers","following_url":"https://api.github.com/users/chickenlj/following{/other_user}","gists_url":"https://api.github.com/users/chickenlj/gists{/gist_id}","starred_url":"https://api.github.com/users/chickenlj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chickenlj/subscriptions","organizations_url":"https://api.github.com/users/chickenlj/orgs","repos_url":"https://api.github.com/users/chickenlj/repos","events_url":"https://api.github.com/users/chickenlj/events{/privacy}","received_events_url":"https://api.github.com/users/chickenlj/received_events","type":"User","site_admin":false},"open_issues":68,"closed_issues":80,"state":"open","created_at":"2019-06-18T07:07:16Z","updated_at":"2019-08-21T08:07:08Z","due_on":"2019-08-31T07:00:00Z","closed_at":null},"comments":0,"created_at":"2019-07-29T13:01:03Z","updated_at":"2019-08-21T08:07:08Z","closed_at":"2019-08-21T08:07:08Z","author_association":"CONTRIBUTOR","body":"`org.apache.dubbo.config.spring.util.AnnotatedBeanDefinitionRegistryUtils#registerBeans` method :\r\n\r\n```java\r\n    public static void registerBeans(BeanDefinitionRegistry registry, Class<?>... annotatedClasses) {\r\n\r\n        if (ObjectUtils.isEmpty(annotatedClasses)) {\r\n            return;\r\n        }\r\n\r\n        boolean debugEnabled = logger.isDebugEnabled();\r\n\r\n        // Remove all annotated-classes that have been registered\r\n        Iterator<Class<?>> iterator = new ArrayList<>(asList(annotatedClasses)).iterator();\r\n\r\n        while (iterator.hasNext()) {\r\n            Class<?> annotatedClass = iterator.next();\r\n            if (isPresentBean(registry, annotatedClass)) {\r\n                iterator.remove();\r\n            }\r\n        }\r\n\r\n        AnnotatedBeanDefinitionReader reader = new AnnotatedBeanDefinitionReader(registry);\r\n\r\n        if (debugEnabled) {\r\n            logger.debug(registry.getClass().getSimpleName() + \" will register annotated classes : \" + asList(annotatedClasses) + \" .\");\r\n        }\r\n\r\n        reader.register(annotatedClasses); // here is an issue\r\n\r\n    }\r\n```"}}
{"actor":{"display_login":"mercyblitz"}}