blob: 165c6b173be39e043828318ed812469635efed85 [file] [log] [blame]
== Camel Example Main
This example shows how to run Camel standalone via the built-in Main class.
The example also demonstrates how you can configure the Camel application
via Camel built-in dependency-injection that supports binding via the
`@BindToRegistry`, `@BeanInject` and `@PropertyInject` annotations.
Also notice how you can configure Camel in the `application.properties` file.
=== Alternative example
The class `StandaloneCamel` is an alternative example that provides a
_public static void main_ method and where you manually set up Camel without
any help from Camel's built-in Main class. However, it shows how to do this
in a _raw style_ without using any _magic_.
=== Build
First compile the example by executing:
[source,sh]
----
$ mvn compile
----
=== How to run
Then you can run this example using
[source,sh]
----
$ mvn camel:run
----
=== How to configure for Camel Textual Route debugging
Several IDEs are providing support for Camel Textual Route debugging. To enable this possibility, you need to launch this example with the profile `camel.debug`.
[source,sh]
----
$ mvn camel:run -Pcamel.debug
----
This profile can also be activated with camel.debug property set to true. For instance, by setting the property from command-line:
[source,sh]
----
$ mvn camel:run -Dcamel.debug=true
----
=== Help and contributions
If you hit any problem using Camel or have some feedback, then please
https://camel.apache.org/community/support/[let us know].
We also love contributors, so
https://camel.apache.org/community/contributing/[get involved] :-)
The Camel riders!