Repository: camel Updated Branches: refs/heads/master 5d95d0fff -> d22b0d7cd
CAMEL-9918: update documentation Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/d22b0d7c Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/d22b0d7c Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/d22b0d7c Branch: refs/heads/master Commit: d22b0d7cd4e99ed90d8fe5c1665c31d09afabdf2 Parents: 5d95d0f Author: Antonin Stefanutti <anto...@stefanutti.fr> Authored: Thu Apr 28 09:34:20 2016 +0200 Committer: Antonin Stefanutti <anto...@stefanutti.fr> Committed: Thu Apr 28 09:34:20 2016 +0200 ---------------------------------------------------------------------- components/camel-cdi/src/main/docs/cdi.adoc | 13 +++++++++++++ 1 file changed, 13 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/camel/blob/d22b0d7c/components/camel-cdi/src/main/docs/cdi.adoc ---------------------------------------------------------------------- diff --git a/components/camel-cdi/src/main/docs/cdi.adoc b/components/camel-cdi/src/main/docs/cdi.adoc index ac09327..8f49cf9 100644 --- a/components/camel-cdi/src/main/docs/cdi.adoc +++ b/components/camel-cdi/src/main/docs/cdi.adoc @@ -573,6 +573,19 @@ void onContextStarting(@Observes CamelContextStartingEvent event) { } ---- +As of Camel 2.18, it is possible to observe events for a particular route (`RouteAddedEvent`, +`RouteStartedEvent`, `RouteStoppedEvent` and `RouteRemovedEvent`) should it have +an explicit defined, e.g.: + +[source,java] +---- +from("...").routeId("foo").to("..."); + +void onRouteStarted(@Observes @Named("foo") RouteStartedEvent event) { + // Called after the route "foo" has started +} +---- + When multiple Camel contexts exist in the CDI container, the Camel context bean qualifiers, like `@ContextName`, can be used to refine the observer method resolution to a particular Camel context as specified