You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@continuum.apache.org by "Napoleon Esmundo C. Ramirez" <na...@gmail.com> on 2009/01/15 18:45:06 UTC

DB Migration Tool in Continuum 1.2.3 not working

Hello,

Has anyone tried the db migration tool in continuum 1.2.3 using the
instructions in
http://continuum.apache.org/docs/1.2.3/installation/upgrade.html?  I tried
the same procedure in a 1.2.3 database to import to a 1.3.0 (not yet
released) database, but I'm having the following error:

$ java -Xmx512m -jar data-management-cli-1.2.3-app.jar -buildsJdbcUrl
jdbc:derby:/tmp/apache-continuum-1.2.3/data/databases/continuum -mode EXPORT
-directory backups
Exception in thread "main" java.lang.NoClassDefFoundError:
org/apache/continuum/management/DataManagementCli
$

Then I checked the MANIFEST.MF, only to see that:
Main-Class: org.apache.continuum.management.DataManagementCli

should be (configured in the pom.xml):
Main-Class: org.apache.*maven*.continuum.management.DataManagementCli

I built the codes, but what I'm having next is:
$ java -Xmx512m -jar data-management-cli-1.2.3-app.jar -buildsJdbcUrl
jdbc:derby:/tmp/apache-continuum-1.2.3/data/databases/continuum -mode EXPORT
-directory backups
Exception in thread "main" java.lang.NoClassDefFoundError:
org/codehaus/plexus/PlexusContainer

Looks like it needed plexus-container-default in it, so I added
plexus-container-default-1.0-alpha-9-stable-1, the container that
continuum's maven uses.  Unfortunately, it contains a banned dependency
blocked by the enforcer plugin.  So I incremented until I found something
that built, alpha-16.  I rebuilt the data-management project from the tags,
and tried again.  The next error I encountered is:
$ java -Xmx512m -jar data-management-cli-1.2.3-app.jar -buildsJdbcUrl
jdbc:derby:/tmp/apache-continuum-1.2.3/data/databases/continuum -mode EXPORT
-directory backups
0 [main] INFO org.apache.maven.continuum.management.DataManagementCli  -
Processing Continuum database...
Exception in thread "main" java.lang.NullPointerException
        at java.util.Properties$LineReader.readLine(Properties.java:365)
        at java.util.Properties.load(Properties.java:293)
        at
org.apache.maven.continuum.management.DataManagementCli.getVersion(DataManagementCli.java:443)
        at
org.apache.maven.continuum.management.DataManagementCli.processDatabase(DataManagementCli.java:188)
        at
org.apache.maven.continuum.management.DataManagementCli.main(DataManagementCli.java:170)
$

A line of code looks for:
properties.load( DataManagementCli.class.getResourceAsStream(
"/META-INF/maven/org.apache.*maven*.continuum/data-management-api/pom.properties"
) );

that should be:
properties.load( DataManagementCli.class.getResourceAsStream(
"/META-INF/maven/org.apache.continuum/data-management-api/pom.properties" )
);

I rebuilt the data-management project again.  But now, I'm having this:
$ java -Xmx512m -jar data-management-cli-1.2.3-app.jar -buildsJdbcUrl
jdbc:derby:/tmp/apache-continuum-1.2.3/data/databases/continuum -mode EXPORT
-directory backups
0 [main] INFO org.apache.maven.continuum.management.DataManagementCli  -
Processing Continuum database...
Exception in thread "main" java.lang.NoSuchMethodError:
org.codehaus.plexus.component.repository.ComponentDescriptor.getComponentKey()Ljava/lang/String;
        at
org.codehaus.plexus.component.composition.DefaultCompositionResolver.addComponentDescriptor(DefaultCompositionResolver.java:41)
        at
org.codehaus.plexus.component.repository.DefaultComponentRepository.addComponentDescriptor(DefaultComponentRepository.java:302)
        at
org.codehaus.plexus.component.repository.DefaultComponentRepository.addComponentDescriptor(DefaultComponentRepository.java:235)
        at
org.codehaus.plexus.component.repository.DefaultComponentRepository.initializeComponentDescriptorsFromUserConfiguration(DefaultComponentRepository.java:211)
        at
org.codehaus.plexus.component.repository.DefaultComponentRepository.initializeComponentDescriptors(DefaultComponentRepository.java:201)
        at
org.codehaus.plexus.component.repository.DefaultComponentRepository.initialize(DefaultComponentRepository.java:195)
        at
org.codehaus.plexus.container.initialization.InitializeComponentRepositoryPhase.initializeCoreComponent(InitializeComponentRepositoryPhase.java:43)
        at
org.codehaus.plexus.container.initialization.AbstractCoreComponentInitializationPhase.execute(AbstractCoreComponentInitializationPhase.java:37)
        at
org.codehaus.plexus.DefaultPlexusContainer.initializePhases(DefaultPlexusContainer.java:928)
        at
org.codehaus.plexus.DefaultPlexusContainer.initialize(DefaultPlexusContainer.java:876)
        at
org.codehaus.plexus.DefaultPlexusContainer.construct(DefaultPlexusContainer.java:853)
        at
org.codehaus.plexus.DefaultPlexusContainer.<init>(DefaultPlexusContainer.java:204)
        at
org.apache.maven.continuum.management.DataManagementCli.processDatabase(DataManagementCli.java:193)
        at
org.apache.maven.continuum.management.DataManagementCli.main(DataManagementCli.java:170)

I figured it's the plexus container again, so I tried upgrading versions,
incrementing until finding alpha-19.  After rebuilding and testing again, I
now have this:
$ java -Xmx512m -jar data-management-cli-1.2.3-app.jar -buildsJdbcUrl
jdbc:derby:/tmp/apache-continuum-1.2.3/data/databases/continuum -mode EXPORT
-directory backups
0 [main] INFO org.apache.maven.continuum.management.DataManagementCli  -
Processing Continuum
database...

Exception in thread "main"
org.apache.maven.artifact.resolver.MultipleArtifactsNotFoundException:
Missing:

----------

1) org.apache.maven.continuum:data-management
jdo:jar:1.2.3


  Try downloading the file manually from the project website.

  Then, install it using the command:
      mvn install:install-file -DgroupId=org.apache.maven.continuum
-DartifactId=data-management-jdo -Dversion=1.2.3 -Dpackaging=jar
-Dfile=/path/to/file

  Alternatively, if you host your own repository you can deploy the file
there:
      mvn deploy:deploy-file -DgroupId=org.apache.maven.continuum
-DartifactId=data-management-jdo -Dversion=1.2.3 -Dpackaging=jar
-Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]

  Path to dependency:
        1) dummy:dummy:pom:1.0
        2) org.apache.maven.continuum:data-management-jdo:jar:1.2.3

----------
1 required artifact is missing.

for artifact:
  dummy:dummy:pom:1.0

from the specified remote repositories:
  central (http://repo1.maven.org/maven2)

        at
org.apache.maven.artifact.resolver.DefaultArtifactResolver.resolveTransitively(DefaultArtifactResolver.java:324)
        at
org.apache.maven.artifact.resolver.DefaultArtifactResolver.resolveTransitively(DefaultArtifactResolver.java:288)
        at
org.apache.maven.artifact.resolver.DefaultArtifactResolver.resolveTransitively(DefaultArtifactResolver.java:259)
        at
org.apache.maven.continuum.management.DataManagementCli.downloadArtifact(DataManagementCli.java:401)
        at
org.apache.maven.continuum.management.DataManagementCli.processDatabase(DataManagementCli.java:200)
        at
org.apache.maven.continuum.management.DataManagementCli.main(DataManagementCli.java:170)
$

Now it's gotten too complicated.  I'll stop for now, maybe you have better
ideas.

Thanks,
Nap

Re: DB Migration Tool in Continuum 1.2.3 not working

Posted by Wendy Smoak <ws...@gmail.com>.
On Thu, Jan 15, 2009 at 10:45 AM, Napoleon Esmundo C. Ramirez

> Has anyone tried the db migration tool in continuum 1.2.3 using the
> instructions in
> http://continuum.apache.org/docs/1.2.3/installation/upgrade.html?  I tried
> the same procedure in a 1.2.3 database to import to a 1.3.0 (not yet
> released) database, but I'm having the following error:

There is no 1.3.0; it was tagged but never released as the vote didn't
pass.  I assume you're trying to upgrade to 1.3.1-SNAPSHOT on trunk?
If so, please come join us on the dev list as we try to keep the user
list focused on the released versions. :)

-- 
Wendy