interacting only through db?
The JVM has no shortage of message queue systems unlike other languages. Any language with the enterprise stamp on it will probably have 50 something message queue systems for it.
This approach allows you to hide the data models of both parts of the system from one another so you don't end up back in the hell of integrating via the database, which is what I suspect you were driving at with your question. You obviously can't avoid having to share some information between systems, but in this model you can share message and service contracts rather than database schema.