cancel
Showing results for 
Search instead for 
Did you mean: 

Hibernate support

dwestra
Champ in-the-making
Champ in-the-making
Hello,

I read some discussions about Hibernate support and how it seems unlikely that Activiti will support Hibernate. By Hibernate support I mean that it is used to store the complete workflow state like now is done with MyBatis.
In my opinion adding Hibernate support or even making it easy to plug in hibernate is crucial for Activiti to be used.
In our project we use hibernate to communicate with the database. I especially like the fact that it supports so many different databases.
My company has a lot of international companies as clients and they use a big range of different databases. Now because Activiti supports a few databases it essentially isn't usable by us, even though it performs the workflows we designed very well. Furthermore because all the data in our system is already retrieved / stored with Hibernate, it seems only logical to also use it for Activiti.
Even if you still think that Hibernate support is not going to be included would it be possible to plug it in somewhere easy?
2 REPLIES 2

ronald_van_kuij
Champ on-the-rise
Champ on-the-rise
In my opinion adding Hibernate support or even making it easy to plug in hibernate is crucial for Activiti to be used.
Hmm… many people use it without hibernate, so it cannot be crucial don't you think?

In our project we use hibernate to communicate with the database. I especially like the fact that it supports so many different databases….Now because Activiti supports a few databases it essentially isn't usable by us, even though it performs the workflows we designed very well.
MyBatis supports many databases as well, it is just that for some databases Activiti needs custom queries as it would have with Hibernate I think. So the limited number of databases is an Activiti thing, not a Hibernate vs MyBatis issue.

Oh and what is 'limited' ? h2,mysql,oracle,postgres, db2, mssql… With the last 2 being experimental since they are not officially in the Activity QA run. What is missing? Sybase?

Furthermore because all the data in our system is already retrieved / stored with Hibernate, it seems only logical to also use it for Activiti.
Does it? Does this mean that you do not use any other system that accesses a database without Hibernate, so no commercial software etc that does e.g. not even use jdbc? You can share connections between your hibernate sessions and activity or use JTA to have common transactions.

Even if you still think that Hibernate support is not going to be included would it be possible to plug it in somewhere easy?
Easy? Have you ever written an application where you could easily plug in another persistence framework? And I do not mean replacing a JPA compliant persistence implementation? That is almost undoable and not worth the effort considering the things I wrote above (we use Hibernate and MyBatis next to eachother without problems)

But it is 'pluggable' since the source is open, you could rewrite the persistence classes. Would be about 4 weeks work I think (just a guestimate), contributions welcome. But if you go in that direction, then why not try JPA instead?

trademak
Star Contributor
Star Contributor
Hi,

I agree with Ronald. You should regard Activiti as a product and you shouldn't be bothered with the ORM framework used.
I'm very curious which database you're missing from the supported list!

Best regards,