Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CamelBeanPostProcessor is invoked after routes are already configured #1368

Closed
lburgazzoli opened this issue Jun 17, 2020 · 1 comment · Fixed by #1344
Closed

CamelBeanPostProcessor is invoked after routes are already configured #1368

lburgazzoli opened this issue Jun 17, 2020 · 1 comment · Fixed by #1344
Assignees
Labels
bug Something isn't working
Milestone

Comments

@lburgazzoli
Copy link
Contributor

In CamelMain::postProcessCamelContext, the CamelBeanPostProcessor is invoked after routes are configured which causes the following route to fail as myProcessor is null when bound to the route.

public class MyRoutes extends RouteBuilder {
    @BeanInject("my-processor")
    MyProcessor myProcessor;

    @Override
    public void configure() throws Exception {
        from("timer:tick")
            .process(myProcessor)
            .to("log:info");
    }
}
@lburgazzoli lburgazzoli added the bug Something isn't working label Jun 17, 2020
@lburgazzoli lburgazzoli added this to the 1.0.0-CR3 milestone Jun 17, 2020
@lburgazzoli
Copy link
Contributor Author

Relates to: apache/camel-k-runtime#362

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant