Hi,

I am in the process of moving to multi-module an existing AppFuse maven
project.

I have succeded in having core and web modules.
To run jetty in the web module, I learned I have to do mvn install from core
module before.
Ok.
Now, if I do mvn jetty:run from web module, everything is fine, except that
in the next mvn jetty:run, I get an error beacause of the previous run did
some database insertions.

Could it be that I need from web subproject to run core dbunit ? And how?

Josep


> mvn jetty:run
Listening for transport dt_socket at address: 4000
[INFO] Scanning for projects...
[INFO]
------------------------------------------------------------------------
[INFO] Building PortaSigma - Web
[INFO]    task-segment: [jetty:run]
[INFO]
------------------------------------------------------------------------
[INFO] Preparing jetty:run
[INFO] [native2ascii:native2ascii {execution: native2ascii-utf8}]
[INFO] [native2ascii:native2ascii {execution: native2ascii-8859_1}]
[INFO] [resources:resources {execution: default-resources}]
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 36 resources
[INFO] Copying 52 resources
[INFO] Copying 127 resources
[INFO] Copying 127 resources
[WARNING] POM for 'es.isigma.firmaqui:portasigma-core:pom:1.1:compile' is
invalid.

Its dependencies (if any) will NOT be available to the current build.
[INFO] [compiler:compile {execution: default-compile}]
[INFO] Nothing to compile - all classes are up to date
[INFO] [resources:testResources {execution: default-testResources}]
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 6 resources
[INFO] Copying 1 resource
[INFO] Copying 11 resources
[INFO] [compiler:testCompile {execution: default-testCompile}]
[INFO] Nothing to compile - all classes are up to date
[INFO] [dbunit:operation {execution: test-compile}]
108 [main] INFO org.dbunit.database.DatabaseDataSet -
        database name=MySQL
        database version=5.1.41-community
        database major version=5
        database minor version=1
        jdbc driver name=MySQL-AB JDBC Driver
        jdbc driver version=mysql-connector-java-5.0.5 ( $Date: 2007-03-01
00:01:06 +0100 (Thu, 01 Mar 2007) $, $Revision: 6329 $ )
        jdbc driver major version=5
        jdbc driver minor version=0

[INFO]
------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO]
------------------------------------------------------------------------
[INFO] Error executing database operation: CLEAN_INSERT

Embedded error:
com.mysql.jdbc.exceptions.MySQLIntegrityConstraintViolationException: Cannot
delete or update a parent row: a foreig
n key constraint fails (`portasigma`.`document`, CONSTRAINT
`FK_DOCUMENT_USER` FOREIGN KEY (`owner_id`) REFERENCES `app_user` (`id`)
)

Reply via email to