camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From acosent...@apache.org
Subject [3/6] camel git commit: Added Injector docs to Gitbook
Date Sun, 31 Jul 2016 09:57:01 GMT
Added Injector docs to Gitbook


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/ef01a66f
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/ef01a66f
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/ef01a66f

Branch: refs/heads/master
Commit: ef01a66f078315983cc9b295dff7fcd5d379eaf3
Parents: 54ce159
Author: Andrea Cosentino <ancosen@gmail.com>
Authored: Sun Jul 31 11:17:26 2016 +0200
Committer: Andrea Cosentino <ancosen@gmail.com>
Committed: Sun Jul 31 11:17:26 2016 +0200

----------------------------------------------------------------------
 docs/user-manual/en/SUMMARY.md    |  3 +--
 docs/user-manual/en/injector.adoc | 24 ++++++++++++++++++++++++
 2 files changed, 25 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/ef01a66f/docs/user-manual/en/SUMMARY.md
----------------------------------------------------------------------
diff --git a/docs/user-manual/en/SUMMARY.md b/docs/user-manual/en/SUMMARY.md
index 6771ff3..22a1db3 100644
--- a/docs/user-manual/en/SUMMARY.md
+++ b/docs/user-manual/en/SUMMARY.md
@@ -34,13 +34,13 @@
     * [Exchange](exchange.adoc)
     * [Exchange Pattern](exchange-pattern.adoc)
     * [Expression](expression.adoc)
+    * [Injector](injector.adoc)
     * [Intercept](intercept.adoc)
     * [Registry](registry.adoc)
     * [RX](rx.adoc)
     * [Scala DSL](scala-dsl.adoc)
 
 <!--
-    * [Injector](.adoc)
     * [Inversion Of Control With Smart Defaults](.adoc)
     * [Languages](.adoc)
     * [Lifecycle](.adoc)
@@ -64,7 +64,6 @@
     * [Security](.adoc)
     * [UuidGenerator](.adoc)
     * [Binding](.adoc)
-    * [CEP](.adoc)
     * [BacklogTracer](.adoc)
     * [Endpoint Annotations](.adoc)
     * [ComponentConfiguration](.adoc)

http://git-wip-us.apache.org/repos/asf/camel/blob/ef01a66f/docs/user-manual/en/injector.adoc
----------------------------------------------------------------------
diff --git a/docs/user-manual/en/injector.adoc b/docs/user-manual/en/injector.adoc
new file mode 100644
index 0000000..a19a0d7
--- /dev/null
+++ b/docs/user-manual/en/injector.adoc
@@ -0,0 +1,24 @@
+[[Injector-Injector]]
+Injector
+~~~~~~~~
+
+The
+http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/spi/Injector.html[Injector]
+is a pluggable strategy to any IoC container such as
+link:spring.html[Spring] or Guice to be able to create and
+dependency-inject objects of a certain type.
+
+For example if you are using the
+link:inversion-of-control-with-smart-defaults.html[Inversion Of Control
+With Smart Defaults] pattern to minimize your XML dependency; Camel will
+automatically discover and use new endpoints when they are referenced
+via their link:uris.html[URIs] by using the META-INF/services settings.
+You could explicitly configure each link:component.html[Component] and
+link:endpoint.html[Endpoint] in your Spring XML file; or let Camel find
+the defaults then use the Injector to create and inject any of its
+dependencies.
+
+As an example; consider the link:jms.html[JMS] component. Rather than
+explicitly configuring the JMS component in Spring XML you can just
+provide a ConnectionFactory in your Spring XML which the Injector will
+use to properly configure the JmsComponent when it is instantiated.


Mime
View raw message