Oracle® Containers for J2EE Enterprise JavaBeans Developer's Guide 10g (10.1.3.1.0) Part Number B28221-02 |
|
|
View PDF |
When you use an MDB, it is blocked in a receive state waiting for incoming messages. In a non-Windows environment, if you shut down OC4J while the MDB is in a wait state, OC4J shuts down in a timely fashion.
If you are using message-driven beans with the OEMS JMS Database provider (see "OEMS JMS Database: Advanced Queueing (AQ)-Based Provider") and OC4J is running in a Windows environment, or when the back-end database is running in a Windows environment and you shutdown OC4J while an MDB is in a wait state, then the OC4J instance cannot be stopped and the MDB cannot be undeployed in a timely manner: in this case, the OC4J process will hang for at least 2.5 hours
Using the oracle.mdb.fastUndeploy
system property (see "Using System Properties"), you can modify the behavior of the MDB in the Windows environment to ensure that your message-driven beans can be undeployed, and OC4J can be shut down, in a timely manner, when necessary.
The oracle.mdb.fastUndeploy
system property is set to the frequency, as an integer number of seconds, at which OC4J polls the database (requiring a database round-trip) to determine whether or not the session is shut down when an MDB is not processing incoming messages and in a wait state.
For optimal performance, a reasonable value should be 120 seconds or more.
If you set this property to 120 (seconds), then every 120 seconds, OC4J will poll the database.