Upgrading from OpenVPMS 1.5 Beta 1 to Beta 2
Submitted by activet on Fri, 08/07/2011 - 14:55
Hi, this is my first forum post, so I hope I'm doing it right :)
I'm looking for instructions to upgrade my OpenVPMS from 1.5 beta 1 to 1.5 beta 2. I've downloaded and unzipped the file but I could only find notes and scripts on upgrading from 1.4 to 1.5. Can anyone advise if the steps would be different please? Thanks!
Anthony
Re: Upgrading from OpenVPMS 1.5 Beta 1 to Beta 2
Hi Anthony,
Upgrading between beta versions can typically be done as thoughupgrading from a previous pervions, in thsi 1.4. i.e run database upgrade script, load archetypes and install new web application. The database upgrade scripts are typically able to be re-run safely.
In the case of this upgrade you actually don't need to run the database upgrade script if you don't want to as no additional database changes are included. So just load archetypes and new webapp.
Cheers
Tony
Re: Upgrading from OpenVPMS 1.5 Beta 1 to Beta 2
Thanks Tony! While trying to update the web application, the upgrade instruction I could find says to replace the tomcat webapps folder openvpms.war with the war file in the new release. (Referring to http://www.openvpms.org/1.5-beta-1) But I couldn't find any .war file in my existing tomcat webapps folder (\\Program Files\Apache Software Foundation\Tomcat 6.0\webapps\). Is this normal?
Kind regards,
Anthony (ActiVet)
Re: Upgrading from OpenVPMS 1.5 Beta 1 to Beta 2
Hi Anthony,
Yes, we tend to remove the war (which is just like a zip file of the application contents) once deployed. Suggest you stop Tomcat, remove the openvpms folder (essentially the unzip war's contents) in the tomcat webapps folder and deploy the new ersion war. This makes sure you have a nice clean install.
Cheers
Tony
Re: Upgrading from OpenVPMS 1.5 Beta 1 to Beta 2
Hi Tony,
I see! I didn't have winzip on my computer but I used winrar and it was able to unzip the war file. I'll try to install the new webapp directory tomorrow after the clinic closes. Actually, you installed a demo training database for our system before, so should I deploy the update into that webapps openvpms-demo directory as well then?
Kind regards,
Anthony (ActiVet)
Re: Upgrading from OpenVPMS 1.5 Beta 1 to Beta 2
Hi Anthony,
Actually don't need winzip as Tomcat will automatically "unzip" the war on startup but no harm if do it this way.
To update the demo application requires a few more steps.
Firstly we need to load the new archetypes into the existing demo database.
hibernate.connection.url=jdbc:mysql://localhost:3306/openvpms
and save.
The remaining process is described in this forum post. Ignore the first two points which relate to creating the demo database as you already have this database.
Cheers
Tony
Re: Upgrading from OpenVPMS 1.5 Beta 1 to Beta 2
Hi Tony,
Before looking into the demo database, I've encountered some problem when upgrading our main OpenVPMS database. I stopped Tomcat and then ran the archload script in a command prompt but noticed error message coming up as follow (only the first few lines listed here):
C:\OpenVPMS\openvpms-release-1.5-beta-2\bin>archload
0 [main] ERROR org.hibernate.util.JDBCExceptionReporter - Cannot load JDBC driv
er class 'com.mysql.jdbc.Driver'
452 [main] ERROR org.hibernate.util.JDBCExceptionReporter - Cannot load JDBC dr
iver class 'com.mysql.jdbc.Driver'
452 [main] ERROR org.hibernate.util.JDBCExceptionReporter - Cannot load JDBC dr
iver class 'com.mysql.jdbc.Driver'
499 [main] ERROR org.openvpms.tools.archetype.loader.ArchetypeLoader - org.spri
ngframework.beans.factory.BeanCreationException: Error creating bean with name '
archetypeDescriptorCache' defined in file [C:\OpenVPMS\openvpms-release-1.5-beta
-2\bin\..\conf\applicationContext.xml]: Instantiation of bean failed; nested exc
eption is org.springframework.beans.BeanInstantiationException: Could not instan
tiate bean class [org.openvpms.component.business.service.archetype.descriptor.c
ache.ArchetypeDescriptorCacheDB]: Constructor threw exception; nested exception
is org.openvpms.component.business.dao.im.common.IMObjectDAOException: Failed to
find IMObjects for class org.openvpms.component.business.dao.hibernate.im.arche
type.AssertionTypeDescriptorDO with shortName: descriptor.assertionType and inst
anceName: null.
org.springframework.beans.factory.BeanCreationException: Error creating bean wit
h name 'archetypeDescriptorCache' defined in file [C:\OpenVPMS\openvpms-release-
1.5-beta-2\bin\..\conf\applicationContext.xml]: Instantiation of bean failed; ne
sted exception is org.springframework.beans.BeanInstantiationException: Could no
t instantiate bean class [org.openvpms.component.business.service.archetype.desc
riptor.cache.ArchetypeDescriptorCacheDB]: Constructor threw exception; nested ex
ception is org.openvpms.component.business.dao.im.common.IMObjectDAOException: F
ailed to find IMObjects for class org.openvpms.component.business.dao.hibernate.
im.archetype.AssertionTypeDescriptorDO with shortName: descriptor.assertionType
and instanceName: null.
Is there something else I've missed? Please advise! Thank you!
Regards,
Anthony
Kind regards,
Anthony (ActiVet)
Re: Upgrading from OpenVPMS 1.5 Beta 1 to Beta 2
Hi Anthony,
I suspect the mysql connector library is missing from the Tomcat install. Check in the tomcat lib folder (or shared/lib in version 5.5).
You may be close to requiring some professional help I think ;-)
Cheers
Tony
Re: Upgrading from OpenVPMS 1.5 Beta 1 to Beta 2
Hi Tony,
I checked and there is a file called 'mysql-connector-java-5.1.5-bin.jar' in the tomcat lib directory. Is this the file you are referring to?
And yes I would probably need some professional help here.
Cheers
Anthony
Kind regards,
Anthony (ActiVet)
Re: Upgrading from OpenVPMS 1.5 Beta 1 to Beta 2
Hi Anthony,
Sorry I gave you the wrong advice. The issue is actually the mysql connector has not been copied into the new releases lib folder so when you run the archload script it fails because it cannot connect to the database. Copy the mysql connector jar file from the old releases lib folder to the new releases lib folder and all should be well..
Cheers
Tony
Re: Upgrading from OpenVPMS 1.5 Beta 1 to Beta 2
Hi Tony,
I see what you mean now. I completely overlooked that point in the release note so it was really my fault. I'm glad it was a simple easy fix for you :)
>The JDBC driver in the archive is named:
> mysql-connector-java-5.1.<x>-bin.jar.
>
> This needs to be copied to:
>
> * the Apache Tomcat shared library directory: <TOMCAT_HOME>/shared/lib
> * the OpenVPMS library directory: <OPENVPMS_HOME>/lib
Thanks a lot again for your help in fixing the upgrade!
Cheers,
Anthony
Kind regards,
Anthony (ActiVet)