Skip to main content
Student Resources

Running Alfresco 3.3 With Embedded Database (H2 In PostgreSQL Compatibility Mode)

By June 13, 2018No Comments

Alfresco is a very good open source content management system, however there is only one problem with Alfresco, testing. Testing is a headache, writing an integration test, forget it. You will end up with functional testing, fire up an Alfresco instance use one of the existing interfaces to setup some test data and do your test.

Unfortunately you cannot do it starting from 3.2 and why?

Because of the outdated scripts starting from version 3.2, Alfresco is not working with in memory databases, not with Derby not with hsqldb…not with Derby not with hsqldb…

Luckily we have h2database and it can impersonate –thanks to compatibility mode– other databases that Alfresco has support for.

All you have to do is to add h2database to your classpath and change your driver, jdbc url and dialect. I did not test Oracle or MySQL compatibility modes but it is working with PostgreSQL.


By this way you can still do your automated tests.

Leave a Reply