We did a great mistake and have a production environment with Tomcat7 and MySQL. Now we wan’t to migrate the system to a PostgreSQL database. First I tried the migration on my testsytem on my local windows-computer.
First I imported the MySQL-Data into a PostgreSQL-Database and then I changed my old Mysql-Testsystem:
I changed the vendor in the setenv.bat
I installed the postgresql-9.4.1207.jar in the lib
I changed the bonita.xml and the bitronix-resources.properties to the PostgreSQl-Database
By starting the application I got following error:
Node not started. Method ‘org.bonitasoft.engine.api.LoginAPI.login’ cannot be called until node has been started (PlatformAPI.startNode()). Exact class: org.bonitasoft.engine.api.impl.LoginAPIImpl
Can you give me a tip, what I can do?
Many thanks !
as Antoine commented in the previous answer, the migration tool is designed to move from one version to a newer one, without changing anything in your stack. So it is out of scope for your need to move from mysql to postgresql.
I suggest you to test this:
start a postgres bundle (same version as your mysql one)
stop it
disable all foreign keys on your postgresql database
empty all tables
use any ETL you want to transfert data (all tables, one by one) binding field by field from mysql to postgres database. at the end of this step you must have same data on both part, but with some column type differences
enable all foreign keys
copy bonita home folder from mysql bundle to postgresql
apply required modifications to fit new db vendor setup (include copy JDBC drivers)
start postgres instance and check all
the main issue is that even if regardless of db vendor, the bonita SQL schema is the same, some column type have different flavors across supported db vendor. So you need to ensure that postgresql schema is created in the right way: this is the purpose of steps 1-3
purpose of steps 3 and 6 is to avoid A-Z issues when moving data.
and apply same method on business data DB if you use it.
many thanks for your help.
After doing all steps you described I’m able to login and to see all task, processes ect.
Unfortunately I can’t see the process-variables in the administrator view of the case and when I call a task, bonita doesn’t found the connectors of the tasks. I checked the connectors, they are lying in the bonita container in the right path.
Current error seems to be related to one of your class: de.lehnert.auftrag.CreateAuftragsUebersicht that cannot be found. Do you know in which jar file this class is packaged? Are you sure this jar file is deployed (as part of the process definition .bar file or in application server classloader)?
the class “de.lehnert.auftrag.CreateAuftragsUebersicht” is part of the „lehnert.jar“ lib and when I searched for this file in the bonita directory, I found the „lehnert.jar“ in the two directories:
**directory 1: ** c:\web702_postgr\bonita\client\tenants\1\work\forms\Auftragsbearbeitung–1.6\1450688219494\lib\lehnert.jar
and directory 2: c:\web702_postgr\bonita\engine-server\work\tenants\1\processes\5780618622248971170\classpath\lehnert.jar
When I have I look into the database into the table process_instance, then it seams that the 2 directories are related to the processDefinitionId (directory 2) and the startDate (directory 1).
The content of the fields are (in both versions MySQL Und PostgreSQL):
processDefinitionId: 5780618622248971170
startDate: 1450688391460
Could it be, that there is a different interpretation of the startDate, which is a bigint-field, in Mysql and the PostgreSql-Version and that is the reason why bonita doesn’t find the jar-file?
It seems that you may re-deploy your process and ensure deployed connector version is up to date with your process definition.
I’m not sure your problem is related to this officially unsupported db vendor migration you did, considering you may loose some items while coppying needed folders & files from your previous bonita-home folder in order to keep them align with the database
Have you also consider that http://www.bonitasoft.com provides professional support and professional services to help you to solve this kind of issues ?
You might want to reconsider…as MySQL is now officially supported as of 7.1.5 with MySQL 5.5.27. Still needs to be set up as INNODB. But The migration will probably be much easier than doing the PostgreSQL stuff.
The documentation is still not clear on this but the following post is very easy to understand…
Bonitasoft empowers development teams with Bonita, the open-source and extensible platform to solve the most demanding process automation use cases. The Bonita platform accelerates delivery of complex applications with clear separation between capabilities for visual programming and for coding. Bonita integrates with existing solutions, orchestrates heterogeneous systems, and provides deep visibility into processes across the organization.