Do you use plain JDBC with EJB or WEB application?
To restart the application the dependency must be set correct. In my case the dependency is set because the jar file with the EJB2-CMP beans contains a dependency entry within the deployment descriptor.
You must set such in your application, then the EAR/WAR will not deployed as long as the *-ds is not ready and in case of restart DS the application is also redeployed.