bsautner
bsautner

Reputation: 4802

datanucleus jdo 3.1.2 migrate to 4.x

We build and run a jdo app both on J2EE Servers and Google App Engine. We seem stuck on datanucleus 3.1.2 though and when I try to upgrade our maven configs to 4.1 I always get classpath or compile errors.

I'm hoping to get some migration help. My maven pom.xml is below, what do i need to change to get onto 4.x? It seems that just switching to the latest versions doesn't work. The version combination below works just fine. What is the 4.x equivalent? thanks!

 <dependency>
        <groupId>javax.jdo</groupId>
        <artifactId>jdo-api</artifactId>
        <version>3.0.1</version>
    </dependency>
    <dependency>
        <groupId>org.datanucleus</groupId>
        <artifactId>datanucleus-core</artifactId>
        <version>3.1.1</version>
        <scope>runtime</scope>
    </dependency>
    <dependency>
        <groupId>org.datanucleus</groupId>
        <artifactId>datanucleus-api-jdo</artifactId>
        <version>3.1.2</version>

    </dependency>
    <dependency>
        <groupId>org.datanucleus</groupId>
        <artifactId>datanucleus-rdbms</artifactId>
        <version>3.1.2</version>
    </dependency>
    <dependency>
        <groupId>org.datanucleus</groupId>
        <artifactId>datanucleus-cache</artifactId>
        <version>3.1.2</version>
    </dependency>


 <plugin>
                <groupId>org.datanucleus</groupId>
                <artifactId>maven-datanucleus-plugin</artifactId>
                <version>3.1.2</version>
                <configuration>
                    <verbose>false</verbose>
                    <fork>false</fork>
                </configuration>
                <executions>
                    <execution>
                        <phase>process-classes</phase>
                        <goals>
                            <goal>enhance</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

Upvotes: 0

Views: 51

Answers (1)

Neil Stockton
Neil Stockton

Reputation: 11531

If using RDBMS (and not Google AppEngine) then you upgrade all jars to the latest from 4.0 or 4.1 or 4.2 depending on what version you intend to use. That's all there is, and follow the DataNucleus projects migration guide of course. You don't state what your compilation/classpath errors are so have to assume you haven't done it right or as per the documentation of those versions of DataNucleus

If using Google AppEngine, then you can't, since Google haven't provided updates to their persistence software that uses some of DataNucleus code.

Upvotes: 1

Related Questions