There is no standard way to do this.
JBoss allows at least two ways to do this.
1) Deploy an MBean in the ear that depends
on the ejb.
In start/startService() write your code.
2) You can do a similar thing with the new
bean shell deployer.
Thanks for your information.
Any simple example of your two suggested solutions ?
And what is the new bean shell deployer ???
There are plenty of explantations of mbeans
and the service lifecyle in the jmx forum.