If it is a requirement that we repeatedly process events(not only at start of application) we can create a thread that runs at start of application and in a while loop processes events and then goes to sleep for a while.
Hear is sodo codes:
public Class processor extends Thread{
private sleepTime = 100000;
while(true){
process events(call a stored procedure....);
sleep(sleepTime);
}
}
This thread could be started at a static block and sleepTime could be loaded from a property file.