You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Christian Ribeaud (JIRA)" <ji...@apache.org> on 2018/07/25 09:42:00 UTC

[jira] [Created] (CAMEL-12682) Custom ApplicationContextRegistry extension NOT discovered

Christian Ribeaud created CAMEL-12682:
-----------------------------------------

             Summary: Custom ApplicationContextRegistry extension NOT discovered
                 Key: CAMEL-12682
                 URL: https://issues.apache.org/jira/browse/CAMEL-12682
             Project: Camel
          Issue Type: Improvement
          Components: camel-spring
    Affects Versions: 2.21.1
            Reporter: Christian Ribeaud


Up to this documentation [page|http://camel.apache.org/advanced-configuration-of-camelcontext-using-spring.html], I got the impression that following code snippet:
{code:java}
@Bean
public static Registry createMyApplicationContextRegistry(ApplicationContext applicationContext) {
  return new MyApplicationContextRegistry(applicationContext);
}
{code}
in my *Spring* {{Application.java}} startup class should override the default {{ApplicationContextRegistry}} used.
This does NOT work in my case. What works is annotating (with {{@Bean}}) my custom {{SpringCamelContext}} extension, which then overrides the {{createRegistry}} method.




--
This message was sent by Atlassian JIRA
(v7.6.3#76005)