user1892837
user1892837

Reputation:

eclipse : gwt +maven +hibernate

I am really baffled. I've been fighting against hibernate for a long time now and with no success passing run time. I got runtime exceptions when I tried it running it alone. Then I decided I should try integrating it with gwt(the original project was a gwt without hibernate) and maven. I have gwt and hibernate plugins installed via update site and maven for eclipse wtp via marketplace I've done a right click and converted the gwt+hibernate project into a maven project now I get the following error The output directory for the project should be set to /BGUSched/war/WEB-INF/classes this is my auto generated pom.xml (located in top level directory - BGUSched)

<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/xsd/maven-4.0.0.xsd">
  <modelVersion>4.0.0</modelVersion>
  <groupId>BGUSched</groupId>
  <artifactId>BGUSched</artifactId>
  <version>0.0.1-SNAPSHOT</version>
  <build>
    <sourceDirectory>src</sourceDirectory>
    <testSourceDirectory>test</testSourceDirectory>
    <resources>
      <resource>
        <directory>src</directory>
        <excludes>
          <exclude>**/*.java</exclude>
        </excludes>
      </resource>
    </resources>
    <plugins>
      <plugin>
        <artifactId>maven-compiler-plugin</artifactId>
        <version>2.3.2</version>
        <configuration>
          <source>1.7</source>
          <target>1.7</target>
        </configuration>
      </plugin>
    </plugins>
  </build>
</project>

my classpath: -hibernate (as user library):
-antlr-2.7.6.jar
-commons-collections-3.1.jar
-dom4j-1.6.1.jar
-hibernate3.jar
-hibernate-jpa-2.0-api-1.0.0.Final.jar
-javassist-3.9.0.GA.jar
-slf4j-api-1.5.8.jar
-slf4j-simple-1.5.8.jar

gwt:

-appengine-api-1.0-sdk-1.6.3
-appengine-api-1.0-sdk-1.6.4
-appengine-api-1.0-sdk-1.7.0
-appengine-api-labs-1.6.3
-appengine-api-labs-1.6.4
-appengine-jsr107cache-1.6.3
-appengine-jsr107cache-1.6.4
-appengine-local-runtime-shared
-appengine-tools-api
-BGUSched.jar (my project's jar)
-commons-codec-1.3
-commons-fileupload-1.2.2
-commons-io-2.1
-commons-logging-1.03
-datanucleus-appengine-1.0.10.final
-datanucleus-core-1.1.5
-datanucleus-jpa-1.1.5
-el-api
-facebook4gwt-1.0.8
-geronimo-jpa_3.0_spec-1.1.1
-geronimo-jta_1.1_spec-1.1.1
-guice-2.0
-gwt-cal-0.9.3 (some other project embedded in mine)
-gwt-dev
-gwt-dnd-3.1.2
-gwt-log-3.1.8-javadoc
-gwt-plus-v1-0.2-alpha
-gwt-servlet
-gwt-user
-httpclient-4.0
-httpcore-4.0.1
-jdo2-api-2.3-eb
-JOpenId-1.08-sources
-jsp-api
-jsr107cache-1.1
-nekohtml-1.9.14
-openid4java-0.9.6
-repackaged-appengine-ant-1.7.1
-repackaged-appengine-ant-launcher-1.7.1
-repackaged-appengine-jasper-6.0.29
repackaged-appengine-jasper-el-6.0.29
repackaged-appengine-tomcat-juli-6.0.29
servlet-api
spring4gwt-0.0.1
validation-api-1.0.0.GA
validation-api-1.0.0.GA-sources
xercesImpl-2.8.1

GWT SDK (2.5.0)
gwt-user
gwt-dev
validation-api-1.0.0.GA-sources
validation-api-1.0.0.GA

other jars:
junit
mysql-connector-java-5.1.6-bin
ojdbc5

hope i'm not making a mess here and that you guys can help me out

Upvotes: 0

Views: 516

Answers (2)

Fabio Benedetti
Fabio Benedetti

Reputation: 317

You can use the archeotype from:

Mojo gwt-maven-plugin

then add in the pom.xml the Hibernate dependencies.

Upvotes: 0

appbootup
appbootup

Reputation: 9537

Just right click on your project - Navigate to Build Path - Configure -> Java Build Path -> Source Tab -> Set up Default Output folder to BGUSched/war/WEB-INF/classes

enter image description here

Upvotes: 0

Related Questions