15 Running and deploying Camel
This chapter covers
- Starting and stopping Camel safely
- Adding and removing routes at runtime
- Deploying Camel
- Running standalone
- Running in web containers
- Running in Java EE servers
- Running with OSGi
- Running with CDI
In chapter 14, you learned all about securing Camel. We’ll now shift focus to another topic that’s important to master: running and deploying Camel applications.
We’ll begin with starting Camel. You need to fully understand how to start, run, and shut down Camel reliably and safely, which is imperative in a production environment. We’ll also review various options you can use to tweak the way Camel and routes are started. We’ll continue on this path, looking at how to dynamically start and stop routes at runtime. Your applications won’t run forever, so we’ll spend time focusing on how to shut down Camel safely.
The other part of this chapter covers various strategies for deploying Camel. We’ll take a look at five common runtime environments supported by Camel. Two other popular runtimes, Spring Boot and WildFly Swarm, are covered in chapter 7, where we discuss microservices.
As we discuss these topics, we’ll work through an example involving Rider Auto Parts: you’ve been asked to help move a recently developed application safely into production. The application receives inventory updates from suppliers, provided via a web service or files. Figure 15.1 shows a high-level diagram of the application.