Translate

2014년 11월 18일 화요일

[Maven][Hibernate] Could not get ConfigurationTask 증상 문제



HSQLDB 데이터베이스를 생성하기 위해 Hibernate3 플러그인의 hbm2ddl goal 을 호출 시(mvn hibernate3:hbm2ddl) 다음과 같은 오류가 나왔다.


lucifer@lucifer-Vostro-V13:~/test/maven/simple-parent_ch07/simple-webapp$ mvn hibernate3:hbm2ddl
[INFO] Scanning for projects...
[WARNING] 
[WARNING] Some problems were encountered while building the effective model for org.sonatype.mavenbook.ch07:simple-webapp:war:1-SNAPSHOT
[WARNING] 'build.plugins.plugin.version' for org.mortbay.jetty:maven-jetty-plugin is missing. @ line 61, column 15
[WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-compiler-plugin is missing. @ line 53, column 17
[WARNING] 
[WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
[WARNING] 
[WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
[WARNING] 
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building Chapter 7 Simple Web Application 1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] >>> hibernate3-maven-plugin:2.1:hbm2ddl (default-cli) @ simple-webapp >>>
[INFO] 
[INFO] --- maven-resources-plugin:2.3:resources (default-resources) @ simple-webapp ---
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO] 
[INFO] <<< hibernate3-maven-plugin:2.1:hbm2ddl (default-cli) @ simple-webapp <<<
[INFO] 
[INFO] --- hibernate3-maven-plugin:2.1:hbm2ddl (default-cli) @ simple-webapp ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3.762s
[INFO] Finished at: Tue Nov 18 15:22:27 KST 2014
[INFO] Final Memory: 7M/105M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.codehaus.mojo:hibernate3-maven-plugin:2.1:hbm2ddl (default-cli) on project simple-webapp: Could not get ConfigurationTask. -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
lucifer@lucifer-Vostro-V13:~/test/maven/simple-parent_ch07/simple-webapp$





디버그 모드로 실행 시(mvn hibernate3:hbm2ddl -X) 다음과 같이 자세한 정보를 얻을 수 있다.


   ...
   ...

[DEBUG] -- end configuration --
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3.440s
[INFO] Finished at: Tue Nov 18 15:19:08 KST 2014
[INFO] Final Memory: 6M/105M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.codehaus.mojo:hibernate3-maven-plugin:2.0:hbm2ddl (default-cli) on project simple-webapp: Could not get ConfigurationTask. -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.codehaus.mojo:hibernate3-maven-plugin:2.0:hbm2ddl (default-cli) on project simple-webapp: Could not get ConfigurationTask.
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:217)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:141)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
Caused by: org.apache.maven.plugin.MojoExecutionException: Could not get ConfigurationTask.
at org.codehaus.mojo.hibernate3.HibernateExporterMojo.getComponentConfiguration(HibernateExporterMojo.java:229)
at org.codehaus.mojo.hibernate3.exporter.Hbm2DDLExporterMojo.doExecute(Hbm2DDLExporterMojo.java:87)
at org.codehaus.mojo.hibernate3.HibernateExporterMojo.execute(HibernateExporterMojo.java:140)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
... 19 more
[ERROR] 
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
lucifer@lucifer-Vostro-V13:~/test/maven/simple-parent_ch07/simple-webapp$








http://stackoverflow.com/questions/23270551/maven-by-example-nullpointer-executing-hibernate3hbm2ddl

뭐.. 이유는 잘 모르겠지만 위의 글을 읽고 hibernate3-maven-plugin 의 버전을 2.0 => 2.2 로 변경 후 정상 적으로 되는것을 확인했다.

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
  <modelVersion>4.0.0</modelVersion>
  <parent>
    <groupId>org.sonatype.mavenbook.ch07</groupId>
    <artifactId>simple-parent</artifactId>
    <version>1-SNAPSHOT</version>
  </parent>

  <artifactId>simple-webapp</artifactId>
  <packaging>war</packaging>
  <name>Chapter 7 Simple Web Application</name>
  <dependencies>
    <dependency>
      <groupId>org.apache.geronimo.specs</groupId>
      <artifactId>geronimo-servlet_2.4_spec</artifactId>
      <version>1.1.1</version>
    </dependency>
    <dependency>
      <groupId>org.sonatype.mavenbook.ch07</groupId>
      <artifactId>simple-weather</artifactId>
      <version>1-SNAPSHOT</version>
    </dependency>
    <dependency>
      <groupId>org.sonatype.mavenbook.ch07</groupId>
      <artifactId>simple-persist</artifactId>
      <version>1-SNAPSHOT</version>
    </dependency>
    <dependency>
      <groupId>org.springframework</groupId>
      <artifactId>spring</artifactId>
      <version>2.0.7</version>
    </dependency>
    <dependency>
      <groupId>javax.servlet</groupId>
      <artifactId>jstl</artifactId>
      <version>1.1.2</version>
    </dependency>
    <dependency>
      <groupId>taglibs</groupId>
      <artifactId>standard</artifactId>
      <version>1.1.2</version>
    </dependency>
    <dependency>
      <groupId>org.apache.velocity</groupId>
      <artifactId>velocity</artifactId>
      <version>1.5</version>
    </dependency>
  </dependencies>
  <build>
    <finalName>simple-webapp</finalName>
    <plugins>
      <plugin>
        <groupId>org.mortbay.jetty</groupId>
        <artifactId>maven-jetty-plugin</artifactId>
        <dependencies>
          <dependency>
            <groupId>hsqldb</groupId>
            <artifactId>hsqldb</artifactId>
            <version>1.8.0.7</version>
          </dependency>
        </dependencies>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>hibernate3-maven-plugin</artifactId>
        <version>2.2</version>
        <configuration>
          <components>
            <component>
              <name>hbm2ddl</name>
              <implementation>annotationconfiguration</implementation>
            </component>
          </components>
        </configuration>
        <dependencies>
          <dependency>
            <groupId>hsqldb</groupId>
            <artifactId>hsqldb</artifactId>
            <version>1.8.0.7</version>
          </dependency>
        </dependencies>
      </plugin>
    </plugins>
  </build>
</project>





lucifer@lucifer-Vostro-V13:~/test/maven/simple-parent_ch07/simple-webapp$ mvn hibernate3:hbm2ddl
[INFO] Scanning for projects...
[WARNING] 
[WARNING] Some problems were encountered while building the effective model for org.sonatype.mavenbook.ch07:simple-webapp:war:1-SNAPSHOT
[WARNING] 'build.plugins.plugin.version' for org.mortbay.jetty:maven-jetty-plugin is missing. @ line 61, column 15
[WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-compiler-plugin is missing. @ line 53, column 17
[WARNING] 
[WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
[WARNING] 
[WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
[WARNING] 
Downloading: http://repo.maven.apache.org/maven2/org/codehaus/mojo/mojo-parent/20/mojo-parent-20.pom
Downloaded: http://repo.maven.apache.org/maven2/org/codehaus/mojo/mojo-parent/20/mojo-parent-20.pom (19 KB at 12.2 KB/sec)
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building Chapter 7 Simple Web Application 1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] >>> hibernate3-maven-plugin:2.2:hbm2ddl (default-cli) @ simple-webapp >>>
[INFO] 
[INFO] --- maven-resources-plugin:2.3:resources (default-resources) @ simple-webapp ---
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO] 
[INFO] <<< hibernate3-maven-plugin:2.2:hbm2ddl (default-cli) @ simple-webapp <<<
[INFO] 
[INFO] --- hibernate3-maven-plugin:2.2:hbm2ddl (default-cli) @ simple-webapp ---
Downloading: http://repo.maven.apache.org/maven2/org/codehaus/mojo/hibernate3/maven-hibernate3-jdk15/2.2/maven-hibernate3-jdk15-2.2.pom
Downloaded: http://repo.maven.apache.org/maven2/org/codehaus/mojo/hibernate3/maven-hibernate3-jdk15/2.2/maven-hibernate3-jdk15-2.2.pom (3 KB at 5.0 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/org/hibernate/hibernate-entitymanager/3.4.0.GA/hibernate-entitymanager-3.4.0.GA.pom
Downloaded: http://repo.maven.apache.org/maven2/org/hibernate/hibernate-entitymanager/3.4.0.GA/hibernate-entitymanager-3.4.0.GA.pom (2 KB at 4.4 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/org/hibernate/ejb3-persistence/1.0.2.GA/ejb3-persistence-1.0.2.GA.pom
Downloaded: http://repo.maven.apache.org/maven2/org/hibernate/ejb3-persistence/1.0.2.GA/ejb3-persistence-1.0.2.GA.pom (534 B at 1.2 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/org/hibernate/hibernate-commons-annotations/3.1.0.GA/hibernate-commons-annotations-3.1.0.GA.pom
Downloaded: http://repo.maven.apache.org/maven2/org/hibernate/hibernate-commons-annotations/3.1.0.GA/hibernate-commons-annotations-3.1.0.GA.pom (2 KB at 2.5 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/org/hibernate/hibernate-annotations/3.4.0.GA/hibernate-annotations-3.4.0.GA.pom
Downloaded: http://repo.maven.apache.org/maven2/org/hibernate/hibernate-annotations/3.4.0.GA/hibernate-annotations-3.4.0.GA.pom (2 KB at 3.5 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/javax/transaction/jta/1.1/jta-1.1.pom
Downloaded: http://repo.maven.apache.org/maven2/javax/transaction/jta/1.1/jta-1.1.pom (598 B at 1.4 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/javassist/javassist/3.4.GA/javassist-3.4.GA.pom
Downloaded: http://repo.maven.apache.org/maven2/javassist/javassist/3.4.GA/javassist-3.4.GA.pom (485 B at 1.2 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/jboss/jboss-common/4.0.2/jboss-common-4.0.2.pom
Downloaded: http://repo.maven.apache.org/maven2/jboss/jboss-common/4.0.2/jboss-common-4.0.2.pom (915 B at 2.2 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/slide/webdavlib/2.0/webdavlib-2.0.pom
Downloaded: http://repo.maven.apache.org/maven2/slide/webdavlib/2.0/webdavlib-2.0.pom (146 B at 0.4 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/org/hibernate/hibernate-tools/3.2.3.GA/hibernate-tools-3.2.3.GA.jar
Downloading: http://repo.maven.apache.org/maven2/org/hibernate/hibernate-core/3.3.1.GA/hibernate-core-3.3.1.GA.jar
Downloading: http://repo.maven.apache.org/maven2/org/codehaus/mojo/hibernate3/maven-hibernate3-api/2.2/maven-hibernate3-api-2.2.jar
Downloading: http://repo.maven.apache.org/maven2/org/slf4j/slf4j-log4j12/1.5.6/slf4j-log4j12-1.5.6.jar
Downloading: http://repo.maven.apache.org/maven2/org/codehaus/mojo/hibernate3/maven-hibernate3-jdk14/2.2/maven-hibernate3-jdk14-2.2.jar
Downloaded: http://repo.maven.apache.org/maven2/org/codehaus/mojo/hibernate3/maven-hibernate3-jdk14/2.2/maven-hibernate3-jdk14-2.2.jar (7 KB at 10.7 KB/sec)
Downloaded: http://repo.maven.apache.org/maven2/org/slf4j/slf4j-log4j12/1.5.6/slf4j-log4j12-1.5.6.jar (10 KB at 15.5 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/org/codehaus/mojo/hibernate3/maven-hibernate3-jdk15/2.2/maven-hibernate3-jdk15-2.2.jar
Downloading: http://repo.maven.apache.org/maven2/org/hibernate/hibernate-entitymanager/3.4.0.GA/hibernate-entitymanager-3.4.0.GA.jar
Downloaded: http://repo.maven.apache.org/maven2/org/codehaus/mojo/hibernate3/maven-hibernate3-api/2.2/maven-hibernate3-api-2.2.jar (9 KB at 13.1 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/org/hibernate/hibernate-commons-annotations/3.1.0.GA/hibernate-commons-annotations-3.1.0.GA.jar
Downloaded: http://repo.maven.apache.org/maven2/org/codehaus/mojo/hibernate3/maven-hibernate3-jdk15/2.2/maven-hibernate3-jdk15-2.2.jar (9 KB at 21.0 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/javax/transaction/jta/1.1/jta-1.1.jar
Downloaded: http://repo.maven.apache.org/maven2/javax/transaction/jta/1.1/jta-1.1.jar (15 KB at 23.8 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/org/hibernate/ejb3-persistence/1.0.2.GA/ejb3-persistence-1.0.2.GA.jar
Downloaded: http://repo.maven.apache.org/maven2/org/hibernate/hibernate-commons-annotations/3.1.0.GA/hibernate-commons-annotations-3.1.0.GA.jar (66 KB at 62.5 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/org/hibernate/hibernate-annotations/3.4.0.GA/hibernate-annotations-3.4.0.GA.jar
Downloaded: http://repo.maven.apache.org/maven2/org/hibernate/hibernate-tools/3.2.3.GA/hibernate-tools-3.2.3.GA.jar (343 KB at 193.0 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/jboss/jboss-common/4.0.2/jboss-common-4.0.2.jar
Downloaded: http://repo.maven.apache.org/maven2/org/hibernate/hibernate-entitymanager/3.4.0.GA/hibernate-entitymanager-3.4.0.GA.jar (117 KB at 92.9 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/slide/webdavlib/2.0/webdavlib-2.0.jar
Downloaded: http://repo.maven.apache.org/maven2/org/hibernate/ejb3-persistence/1.0.2.GA/ejb3-persistence-1.0.2.GA.jar (50 KB at 55.0 KB/sec)
Downloading: http://repo.maven.apache.org/maven2/javassist/javassist/3.4.GA/javassist-3.4.GA.jar
Downloaded: http://repo.maven.apache.org/maven2/slide/webdavlib/2.0/webdavlib-2.0.jar (129 KB at 124.3 KB/sec)
Downloaded: http://repo.maven.apache.org/maven2/org/hibernate/hibernate-annotations/3.4.0.GA/hibernate-annotations-3.4.0.GA.jar (274 KB at 147.8 KB/sec)
Downloaded: http://repo.maven.apache.org/maven2/jboss/jboss-common/4.0.2/jboss-common-4.0.2.jar (458 KB at 252.5 KB/sec)
Downloaded: http://repo.maven.apache.org/maven2/javassist/javassist/3.4.GA/javassist-3.4.GA.jar (460 KB at 181.6 KB/sec)
Downloaded: http://repo.maven.apache.org/maven2/org/hibernate/hibernate-core/3.3.1.GA/hibernate-core-3.3.1.GA.jar (2223 KB at 399.3 KB/sec)
[INFO] Configuration XML file loaded: jar:file:/home/lucifer/.m2/repository/org/sonatype/mavenbook/ch07/simple-persist/1-SNAPSHOT/simple-persist-1-SNAPSHOT.jar!/hibernate.cfg.xml
15:35:19,110  INFO org.hibernate.cfg.annotations.Version - Hibernate Annotations 3.4.0.GA
15:35:19,166  INFO org.hibernate.cfg.Environment - Hibernate 3.3.1.GA
15:35:19,189  INFO org.hibernate.cfg.Environment - hibernate.properties not found
15:35:19,206  INFO org.hibernate.cfg.Environment - Bytecode provider name : javassist
15:35:19,223  INFO org.hibernate.cfg.Environment - using JDK 1.4 java.sql.Timestamp handling
15:35:19,405  INFO org.hibernate.annotations.common.Version - Hibernate Commons Annotations 3.1.0.GA
[INFO] Configuration XML file loaded: jar:file:/home/lucifer/.m2/repository/org/sonatype/mavenbook/ch07/simple-persist/1-SNAPSHOT/simple-persist-1-SNAPSHOT.jar!/hibernate.cfg.xml
15:35:19,426  INFO org.hibernate.cfg.Configuration - configuring from url: jar:file:/home/lucifer/.m2/repository/org/sonatype/mavenbook/ch07/simple-persist/1-SNAPSHOT/simple-persist-1-SNAPSHOT.jar!/hibernate.cfg.xml
15:35:20,066  INFO org.hibernate.cfg.Configuration - Configured SessionFactory: null
[INFO] No hibernate properties file loaded.
15:35:20,185  INFO org.hibernate.cfg.AnnotationBinder - Binding entity from annotated class: org.sonatype.mavenbook.weather.model.Atmosphere
15:35:20,250  INFO org.hibernate.cfg.annotations.EntityBinder - Bind entity org.sonatype.mavenbook.weather.model.Atmosphere on table Atmosphere
15:35:20,352  INFO org.hibernate.cfg.AnnotationBinder - Binding entity from annotated class: org.sonatype.mavenbook.weather.model.Condition
15:35:20,353  INFO org.hibernate.cfg.annotations.EntityBinder - Bind entity org.sonatype.mavenbook.weather.model.Condition on table Condition
15:35:20,357  INFO org.hibernate.cfg.AnnotationBinder - Binding entity from annotated class: org.sonatype.mavenbook.weather.model.Location
15:35:20,359  INFO org.hibernate.cfg.annotations.QueryBinder - Binding Named query: Location.uniqueByZip => from Location l where l.zip = :zip
15:35:20,359  INFO org.hibernate.cfg.annotations.EntityBinder - Bind entity org.sonatype.mavenbook.weather.model.Location on table Location
15:35:20,361  INFO org.hibernate.cfg.AnnotationBinder - Binding entity from annotated class: org.sonatype.mavenbook.weather.model.Weather
15:35:20,362  INFO org.hibernate.cfg.annotations.QueryBinder - Binding Named query: Weather.byLocation => from Weather w where w.location = :location
15:35:20,362  INFO org.hibernate.cfg.annotations.EntityBinder - Bind entity org.sonatype.mavenbook.weather.model.Weather on table Weather
15:35:20,374  INFO org.hibernate.cfg.AnnotationBinder - Binding entity from annotated class: org.sonatype.mavenbook.weather.model.Wind
15:35:20,375  INFO org.hibernate.cfg.annotations.EntityBinder - Bind entity org.sonatype.mavenbook.weather.model.Wind on table Wind
15:35:20,475  INFO org.hibernate.cfg.AnnotationConfiguration - Hibernate Validator not found: ignoring
15:35:20,511  INFO org.hibernate.dialect.Dialect - Using dialect: org.hibernate.dialect.HSQLDialect
15:35:20,569  INFO org.hibernate.tool.hbm2ddl.SchemaExport - Running hbm2ddl schema export
15:35:20,571  INFO org.hibernate.tool.hbm2ddl.SchemaExport - exporting generated schema to database
15:35:20,576  INFO org.hibernate.connection.DriverManagerConnectionProvider - Using Hibernate built-in connection pool (not for production use!)
15:35:20,577  INFO org.hibernate.connection.DriverManagerConnectionProvider - Hibernate connection pool size: 1
15:35:20,577  INFO org.hibernate.connection.DriverManagerConnectionProvider - autocommit mode: false
15:35:20,591  INFO org.hibernate.connection.DriverManagerConnectionProvider - using driver: org.hsqldb.jdbcDriver at URL: jdbc:hsqldb:data/weather
15:35:20,591  INFO org.hibernate.connection.DriverManagerConnectionProvider - connection properties: {user=sa, password=****, shutdown=true}
create table Atmosphere (id integer generated by default as identity (start with 1), humidity varchar(255), pressure varchar(255), rising varchar(255), visibility varchar(255), weather_id integer not null, primary key (id));
create table Condition (id integer generated by default as identity (start with 1), code varchar(255), date varchar(255), temp varchar(255), text varchar(255), weather_id integer not null, primary key (id));
create table Location (zip varchar(255) not null, city varchar(255), country varchar(255), region varchar(255), primary key (zip));
create table Weather (id integer generated by default as identity (start with 1), date timestamp, location_zip varchar(255), primary key (id));
create table Wind (id integer generated by default as identity (start with 1), chill varchar(255), direction varchar(255), speed varchar(255), weather_id integer not null, primary key (id));
alter table Atmosphere add constraint FK2AF43942E377EE06 foreign key (weather_id) references Weather;
alter table Condition add constraint FK441B8CFBE377EE06 foreign key (weather_id) references Weather;
alter table Weather add constraint FKAC24CFD41D328C00 foreign key (location_zip) references Location;
alter table Wind add constraint FK292428E377EE06 foreign key (weather_id) references Weather;
15:35:21,004  INFO org.hibernate.tool.hbm2ddl.SchemaExport - schema export complete
15:35:21,006  INFO org.hibernate.connection.DriverManagerConnectionProvider - cleaning up connection pool: jdbc:hsqldb:data/weather
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 18.103s
[INFO] Finished at: Tue Nov 18 15:35:21 KST 2014
[INFO] Final Memory: 15M/171M
[INFO] ------------------------------------------------------------------------
lucifer@lucifer-Vostro-V13:~/test/maven/simple-parent_ch07/simple-webapp$ 





mvn 및 JAVA_HOME 같은 정보는 다음과 같다.


lucifer@lucifer-Vostro-V13:~$ mvn -v
Apache Maven 3.0.4
Maven home: /usr/share/maven
Java version: 1.7.0_45, vendor: Oracle Corporation
Java home: /opt/jdk1.7.0_45/jre
Default locale: ko_KR, platform encoding: UTF-8
OS name: "linux", version: "3.11.0-20-generic", arch: "amd64", family: "unix"
lucifer@lucifer-Vostro-V13:~$






Hibernate 써보지도 않았고..
앞으로 쓸일이 있을지도 잘 몰라서..;;
2.2 미만의 버전에는 어떻게 설정을 해야 하는지는 귀찮아서 찾아보지 않았다.





댓글 없음 :

댓글 쓰기