Using FastSwap to reduce deployment time
To speed up the deployment process, we can enable the FastSwap feature, instructing the container to update bytecode without dropping the existing instances of the affected classes or reloading the classloader. This means that a class binary can be loaded into the container's memory without dropping the class' instances that are already in use—it's like updating a static file using the exploded directory archive (explained in the previous section) and making it immediately available to the container, but we're actually replacing binaries.
Note
Remember that this doesn't mean you don't have to publish a project after changing the source code—FastSwap only makes the deployment process quicker, but you still have to command Eclipse to execute the deployment procedure (if automatic publishing is disabled, obviously).
Not every change made to a class is a candidate to use the FastSwap feature, though. Here are a few requirements and constraints we need to...