WSO2 APIM Shutdown Events

If you are using WSO2 API Manager for managing the API's lifecycle, it's important to understand the flow when API Manager gets shutdown. So, whether you're running WSO2 API Manager in production or a test environment, it's critical to understand how it shuts down. A graceful shutdown ensures that no in-flight API requests are abruptly cut off, database connections are properly closed, and services stop cleanly. In this post, we’ll break down the sequence of events that occur when you shut down WSO2 API Manager, and why it matters. So, what Triggers the Shutdown? Shutdown can be initiated in several ways: Pressing Ctrl + C on the terminal 1. Running the shutdown script: ./wso2server.sh stop Or ./api-manager.sh stop 2. Sending a termination signal: kill -15 <PID> Any of these methods initiate a graceful shutdown via a JVM shutdown hook, which delegates the shutdown process to the Carbon runtime environment WSO2 is built upon. Series of Events : Behind the Scenes 1...