STS 3.2 에 QueryDSL을 pom.xml에 올리다 보니 eclipse에서 오류를 내뱉더군요.

2013-03-17 23:19

You need to run build with JDK or have tools.jar on the classpath.If this occures during eclipse build make sure you run eclipse under JDK as well (com.mysema.maven:apt-maven-plugin:1.0.6:process:default:generate-sources) pom.xml /spring-data line 228 Maven Build Problem

이래저래 좀 시간을 보냈네요. 분명 jdk버전은 모두 정상적인데..왜그렇지..하고.

STS에서 eclipse.ini를 찾아보니 없어서, sts.ini에 -vm option으로 javaw.exe 버전을 강제로 넣어 봤습니다.

근데 오류가 뜨더군요. 오류 내용에서 문제가 발견되었습니다.

javaw.exe를 \windows\system32\javaw.exe를 사용해 sts를 열더군요.아...

jsdk를 설치할때 그냥 jre도 설치 했는데 sts는 그놈을 이용해서 띄우는.. 여튼 jre를 uninstall하고 -vm 옵션을 주고나니 문제는 해결되었습니다.

아래는 관련 내용이기는 한데, 굳이 M2는 손댈 필요가 없습니다.

http://thesolidsnake.wordpress.com/2012/11/10/men-setup-querydsl-di-eclipse/

4개의 의견 from SLiPP

2016-08-12 11:25

@jin윤석진 <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"> 4.0.0 com.skan.potal com.skan.potal war 0.0.1-SNAPSHOT com.dongbu.potal Maven Webapp http://maven.apache.org

<properties>
    <jdk.version>1.8</jdk.version>
    <spring.version>4.2.3.RELEASE</spring.version>
    <spring.security.version>3.2.3.RELEASE</spring.security.version>
    <spring.data.jpa>1.8.0.RELEASE</spring.data.jpa>
    <jstl.version>1.2</jstl.version>
    <javax.servlet.version>3.1.0</javax.servlet.version>
    <querydsl.version>4.0.5</querydsl.version>
</properties>

<!-- ////////////////////////////////////////////////////////////////// 
    // DEPENDENCY ////////////////////////////////////////////////////////////////// -->
<dependencies>


    <dependency>
       <groupId>com.fasterxml.jackson.core</groupId>
       <artifactId>jackson-databind</artifactId>
       <version>2.2.0</version>
    </dependency>

    <!-- /////////////////////////////////////////////////////////////////////////// 
       // JSON /////////////////////////////////////////////////////////////////////////// -->
    <dependency>
       <groupId>org.codehaus.jackson</groupId>
       <artifactId>jackson-mapper-asl</artifactId>
       <version>1.9.12</version>
    </dependency>
    <dependency>
       <groupId>org.codehaus.jackson</groupId>
       <artifactId>jackson-core-asl</artifactId>
       <version>1.9.12</version>
    </dependency>


    <!-- ////////////////////////////////////////////////////////////////// 
       // APACHE ////////////////////////////////////////////////////////////////// -->
    <dependency>
       <groupId>commons-codec</groupId>
       <artifactId>commons-codec</artifactId>
       <version>1.8</version>
    </dependency>

    <dependency>
       <groupId>commons-lang</groupId>
       <artifactId>commons-lang</artifactId>
       <version>2.6</version>
    </dependency>

    <dependency>
       <groupId>commons-io</groupId>
       <artifactId>commons-io</artifactId>
       <version>2.4</version>
    </dependency>

    <dependency>
       <groupId>commons-beanutils</groupId>
       <artifactId>commons-beanutils</artifactId>
       <version>1.8.3</version>
    </dependency>

    <dependency>
       <groupId>commons-io</groupId>
       <artifactId>commons-io</artifactId>
       <version>2.4</version>
    </dependency>

    <dependency>
       <groupId>commons-logging</groupId>
       <artifactId>commons-logging</artifactId>
       <version>1.1.3</version>
    </dependency>


    <dependency>
       <groupId>commons-collections</groupId>
       <artifactId>commons-collections</artifactId>
       <version>3.2.1</version>
    </dependency>

    <dependency>
       <groupId>org.apache.commons</groupId>
       <artifactId>commons-compress</artifactId>
       <version>1.6</version>
    </dependency>

    <dependency>
       <groupId>commons-fileupload</groupId>
       <artifactId>commons-fileupload</artifactId>
       <version>1.3</version>
    </dependency>

    <dependency>
       <groupId>org.apache.tiles</groupId>
       <artifactId>tiles-core</artifactId>
       <version>3.0.4</version>
    </dependency>

    <dependency>
       <groupId>org.apache.tiles</groupId>
       <artifactId>tiles-servlet</artifactId>
       <version>3.0.4</version>
    </dependency>

    <dependency>
       <groupId>org.apache.tiles</groupId>
       <artifactId>tiles-jsp</artifactId>
       <version>3.0.4</version>
    </dependency>
    <dependency>
       <groupId>org.apache.tiles</groupId>
       <artifactId>tiles-el</artifactId>
       <version>3.0.4</version>
    </dependency>

    <dependency>
       <groupId>commons-configuration</groupId>
       <artifactId>commons-configuration</artifactId>
       <version>1.8</version>
       <exclusions>
         <exclusion>
          <groupId>commons-beanutils</groupId>
          <artifactId>commons-beanutils</artifactId>
         </exclusion>
         <exclusion>
          <groupId>commons-digester</groupId>
          <artifactId>commons-digester</artifactId>
         </exclusion>
         <exclusion>
          <groupId>commons-collections</groupId>
          <artifactId>commons-collections</artifactId>
         </exclusion>
         <exclusion>
          <groupId>commons-codec</groupId>
          <artifactId>commons-codec</artifactId>
         </exclusion>
         <exclusion>
          <groupId>commons-jxpath</groupId>
          <artifactId>commons-jxpath</artifactId>
         </exclusion>
         <exclusion>
          <groupId>xml-resolver</groupId>
          <artifactId>xml-resolver</artifactId>
         </exclusion>
         <exclusion>
          <groupId>javax.servlet</groupId>
          <artifactId>servlet-api</artifactId>
         </exclusion>
         <exclusion>
          <groupId>commons-jexl</groupId>
          <artifactId>commons-jexl</artifactId>
         </exclusion>
         <exclusion>
          <groupId>commons-vfs2</groupId>
          <artifactId>commons-vfs2</artifactId>
         </exclusion>
         <exclusion>
          <groupId>log4j</groupId>
          <artifactId>log4j</artifactId>
         </exclusion>
         <exclusion>
          <groupId>xml-apis</groupId>
          <artifactId>xml-apis</artifactId>
         </exclusion>
         <exclusion>
          <groupId>commons-logging</groupId>
          <artifactId>commons-logging</artifactId>
         </exclusion>
       </exclusions>
    </dependency>

    <dependency>
       <groupId>commons-pool</groupId>
       <artifactId>commons-pool</artifactId>
       <version>1.6</version>
    </dependency>

    <dependency>
       <groupId>commons-dbcp</groupId>
       <artifactId>commons-dbcp</artifactId>
       <version>1.4</version>
    </dependency>

    <dependency>
       <groupId>taglibs</groupId>
       <artifactId>standard</artifactId>
       <version>1.1.2</version>
    </dependency>

    <!-- ////////////////////////////////////////////////////////////////// 
       // JAVA ////////////////////////////////////////////////////////////////// -->
    <dependency>
       <groupId>javax.servlet</groupId>
       <artifactId>javax.servlet-api</artifactId>
       <version>3.1.0</version>
    </dependency>

    <dependency>
       <groupId>javax.servlet.jsp</groupId>
       <artifactId>jsp-api</artifactId>
       <version>2.2</version>
    </dependency>

    <dependency>
       <groupId>javax.servlet</groupId>
       <artifactId>jstl</artifactId>
       <version>1.2</version>
    </dependency>

    <dependency>
       <groupId>javax.mail</groupId>
       <artifactId>mail</artifactId>
       <version>1.4.1</version>
    </dependency>

    <!-- ////////////////////////////////////////////////////////////////// 
       // SPRINGFRAMEWORK ////////////////////////////////////////////////////////////////// -->
    <dependency>
       <groupId>org.springframework</groupId>
       <artifactId>spring-jdbc</artifactId>
       <version>${spring.version}</version>
    </dependency>

    <dependency>
       <groupId>org.springframework</groupId>
       <artifactId>spring-orm</artifactId>
       <version>${spring.version}</version>
    </dependency>


    <dependency>
       <groupId>org.springframework</groupId>
       <artifactId>spring-beans</artifactId>
       <version>${spring.version}</version>
    </dependency>

    <dependency>
       <groupId>org.springframework</groupId>
       <artifactId>spring-context</artifactId>
       <version>${spring.version}</version>
    </dependency>

    <dependency>
       <groupId>org.springframework</groupId>
       <artifactId>spring-context-support</artifactId>
       <version>${spring.version}</version>
    </dependency>


    <dependency>
       <groupId>org.springframework</groupId>
       <artifactId>spring-core</artifactId>
       <version>${spring.version}</version>
    </dependency>

    <dependency>
       <groupId>org.springframework</groupId>
       <artifactId>spring-expression</artifactId>
       <version>${spring.version}</version>
    </dependency>

    <dependency>
       <groupId>org.springframework</groupId>
       <artifactId>spring-web</artifactId>
       <version>${spring.version}</version>
    </dependency>

    <dependency>
       <groupId>org.springframework</groupId>
       <artifactId>spring-webmvc</artifactId>
       <version>${spring.version}</version>
    </dependency>
    <dependency>
       <groupId>org.springframework</groupId>
       <artifactId>spring-test</artifactId>
       <version>${spring.version}</version>
    </dependency>



    <!-- ////////////////////////////////////////////////////////////////// 
       // SPRINGFRAMEWORK - SECURITY ////////////////////////////////////////////////////////////////// -->
    <dependency>
       <groupId>org.springframework.security</groupId>
       <artifactId>spring-security-core</artifactId>
       <version>${spring.security.version}</version>
    </dependency>
    <dependency>
       <groupId>org.springframework.security</groupId>
       <artifactId>spring-security-web</artifactId>
       <version>${spring.security.version}</version>
    </dependency>
    <dependency>
       <groupId>org.springframework.security</groupId>
       <artifactId>spring-security-config</artifactId>
       <version>${spring.security.version}</version>
    </dependency>
    <dependency>
       <groupId>org.springframework.security</groupId>
       <artifactId>spring-security-taglibs</artifactId>
       <version>${spring.security.version}</version>
       <exclusions>
         <exclusion>
          <artifactId>spring-aop</artifactId>
          <groupId>org.springframework</groupId>
         </exclusion>
       </exclusions>
    </dependency>


    <!-- ////////////////////////////////////////////////////////////////// 
       // SPRINGFRAMEWORK - AOP ////////////////////////////////////////////////////////////////// 
       <dependency> <groupId>org.springframework</groupId> <artifactId>spring-aop</artifactId> 
       <version>${springVersion}</version> </dependency> <dependency> <groupId>aopalliance</groupId> 
       <artifactId>aopalliance</artifactId> <version>1.0</version> </dependency> 
       <dependency> <groupId>org.aspectj</groupId> <artifactId>aspectjweaver</artifactId> 
       <version>1.7.0</version> </dependency> <dependency> <groupId>org.aspectj</groupId> 
       <artifactId>aspectjrt</artifactId> <version>1.7.0</version> </dependency> -->


    <!-- /////////////////////////////////////////////////////////////////////////// 
       // FREEMAKER /////////////////////////////////////////////////////////////////////////// -->
    <dependency>
       <groupId>org.freemarker</groupId>
       <artifactId>freemarker</artifactId>
       <version>2.3.14</version>
    </dependency>

    <!-- /////////////////////////////////////////////////////////////////////////// 
       // MyBatis /////////////////////////////////////////////////////////////////////////// -->
    <dependency>
       <groupId>org.mybatis</groupId>
       <artifactId>mybatis-spring</artifactId>
       <version>1.1.1</version>
    </dependency>

    <dependency>
       <groupId>org.mybatis</groupId>
       <artifactId>mybatis</artifactId>
       <version>3.2.1</version>
    </dependency>


    <!-- ////////////////////////////////////////////////////////////// // 
       OSGI ////////////////////////////////////////////////////////////// <dependency> 
       <groupId>org.eclipse.osgi</groupId> <artifactId>org.eclipse.osgi</artifactId> 
       <version>3.8.0.v20120529-1548</version> </dependency> -->

    <!-- ////////////////////////////////////////////////////////////// // 
       LOGGING ////////////////////////////////////////////////////////////// -->
    <dependency>
       <groupId>org.slf4j</groupId>
       <artifactId>slf4j-api</artifactId>
       <version>1.7.12</version>
    </dependency>
    <dependency>
       <groupId>org.slf4j</groupId>
       <artifactId>jcl-over-slf4j</artifactId>
       <version>1.7.14</version>
    </dependency>

    <dependency>
       <groupId>ch.qos.logback</groupId>
       <artifactId>logback-classic</artifactId>
       <version>1.1.3</version>
    </dependency>
    <dependency>
       <groupId>ch.qos.logback</groupId>
       <artifactId>logback-core</artifactId>
       <version>1.1.3</version>
    </dependency>

    <!-- ////////////////////////////////////////////////////////////////// 
       // validator ////////////////////////////////////////////////////////////////// -->
    <dependency>
       <groupId>javax.validation</groupId>
       <artifactId>validation-api</artifactId>
       <version>1.1.0.Final</version>
    </dependency>
    <dependency>
       <groupId>org.hibernate</groupId>
       <artifactId>hibernate-validator</artifactId>
       <version>5.1.0.Final</version>
    </dependency>

    <dependency>
       <groupId>javax.el</groupId>
       <artifactId>javax.el-api</artifactId>
       <version>3.0.0</version>
    </dependency>


    <!-- ////////////////////////////////////////////////////////////////// 
       // Apache POI lib ////////////////////////////////////////////////////////////////// -->
    <dependency>
       <groupId>org.apache.poi</groupId>
       <artifactId>poi</artifactId>
       <version>3.10-FINAL</version>
    </dependency>
    <dependency>
       <groupId>org.apache.poi</groupId>
       <artifactId>poi-ooxml</artifactId>
       <version>3.10-FINAL</version>
    </dependency>
    <dependency>
       <groupId>org.apache.poi</groupId>
       <artifactId>poi-ooxml-schemas</artifactId>
       <version>3.10-FINAL</version>
    </dependency>
    <dependency>
       <groupId>org.apache.poi</groupId>
       <artifactId>poi-scratchpad</artifactId>
       <version>3.10-FINAL</version>
    </dependency>

    <dependency>
       <groupId>org.apache.commons</groupId>
       <artifactId>commons-jexl</artifactId>
       <version>2.1.1</version>
    </dependency>

    <!-- ////////////////////////////////////////////////////////////////// 
       // jxls ////////////////////////////////////////////////////////////////// -->
    <dependency>
       <groupId>net.sf.jxls</groupId>
       <artifactId>jxls-core</artifactId>
       <version>1.0.5</version>
    </dependency>

    <dependency>
       <groupId>net.sf.jxls</groupId>
       <artifactId>jxls-reader</artifactId>
       <version>1.0.5</version>
    </dependency>


    <dependency>
       <groupId>org.hibernate</groupId>
       <artifactId>hibernate-core</artifactId>
       <version>4.3.11.Final</version>
    </dependency>
    <dependency>
       <groupId>org.hibernate</groupId>
       <artifactId>hibernate-entitymanager</artifactId>
       <version>4.3.11.Final</version>
    </dependency>
    <dependency>
       <groupId>javax.transaction</groupId>
       <artifactId>jta</artifactId>
       <version>1.1</version>
    </dependency>


    <!-- ////////////////////////////////////////////////////////////////// 
       // SPRING JPA ////////////////////////////////////////////////////////////////// -->

    <dependency>
       <groupId>org.springframework.data</groupId>
       <artifactId>spring-data-jpa</artifactId>
       <version>${spring.data.jpa}</version>
       <!-- <exclusions> -->
       <!-- <exclusion> -->
       <!-- <artifactId>spring-asm</artifactId> -->
       <!-- <groupId>org.springframework</groupId> -->
       <!-- </exclusion> -->
       <!-- </exclusions> -->
    </dependency>

    <!-- ////////////////////////////////////////////////////////////////// 
       // QUERY DSL ////////////////////////////////////////////////////////////////// -->

    <dependency>
       <groupId>com.mysema.querydsl</groupId>
       <artifactId>querydsl-apt</artifactId>
       <version>3.6.5</version>
       <scope>provided</scope>
    </dependency>

    <dependency>
       <groupId>com.mysema.querydsl</groupId>
       <artifactId>querydsl-jpa</artifactId>
       <version>3.6.5</version>
    </dependency>

    <!-- <dependency> -->
    <!-- <groupId>com.querydsl</groupId> -->
    <!-- <artifactId>querydsl-jpa</artifactId> -->
    <!-- <version>${querydsl.version}</version> -->
    <!-- </dependency> -->

    <!-- <dependency> -->
    <!-- <groupId>org.slf4j</groupId> -->
    <!-- <artifactId>slf4j-log4j12</artifactId> -->
    <!-- <version>1.6.1</version> -->
    <!-- </dependency> -->

    <!-- ////////////////////////////////////////////////////////////////// 
       // JDBC ////////////////////////////////////////////////////////////////// -->

    <dependency>
       <groupId>org.postgresql</groupId>
       <artifactId>postgresql</artifactId>
       <version>9.3-1100-jdbc41</version>
    </dependency>


    <!-- ////////////////////////////////////////////////////////////////// 
       // TEST ////////////////////////////////////////////////////////////////// -->
    <dependency>
       <groupId>junit</groupId>
       <artifactId>junit</artifactId>
       <version>4.11</version>
       <scope>test</scope>
    </dependency>
</dependencies>

<repositories>
    <!-- Repository for bringing the Eclipse JPA / NoSQL dependency -->
    <repository>
       <id>EclipseLink</id>
       <url>http://download.eclipse.org/rt/eclipselink/maven.repo</url>
    </repository>
</repositories>


<build>
    <finalName>com.skan.potal</finalName>
    <plugins>
       <plugin>
         <artifactId>maven-compiler-plugin</artifactId>
         <version>3.1</version>
         <configuration>
          <source>1.8</source>
          <target>1.8</target>
         </configuration>
       </plugin>
       <!-- <plugin> -->
       <!-- <groupId>org.apache.maven.plugins</groupId> -->
       <!-- <artifactId>maven-war-plugin</artifactId> -->
       <!-- <configuration> -->
       <!-- <packagingExcludes>WEB-INF/lib/com.softforum.bundles.jdbc*.jar,WEB-INF/lib/test*.jar</packagingExcludes> -->
       <!-- <archive> -->
       <!-- <manifestFile>src/main/resources/META-INF/MANIFEST.MF</manifestFile> -->
       <!-- </archive> -->
       <!-- </configuration> -->
       <!-- </plugin> -->
       <plugin>
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-resources-plugin</artifactId>
         <configuration>
          <nonFilteredFileExtensions>
              <nonFilteredFileExtension>xls</nonFilteredFileExtension>
              <nonFilteredFileExtension>xlsx</nonFilteredFileExtension>
              <nonFilteredFileExtension>properties</nonFilteredFileExtension>
          </nonFilteredFileExtensions>
         </configuration>
       </plugin>

       <plugin>
         <groupId>com.mysema.maven</groupId>
         <artifactId>apt-maven-plugin</artifactId>
         <version>1.1.3</version>
         <executions>
          <execution>
              <goals>
                 <goal>process</goal>
              </goals>
              <configuration>
                 <outputDirectory>target/generated-sources/java</outputDirectory>
                 <processor>com.mysema.query.apt.jpa.JPAAnnotationProcessor</processor>
              </configuration>
          </execution>
         </executions>
       </plugin>

       <!-- junit skip -->
       <plugin>
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-surefire-plugin</artifactId>
         <configuration>
          <skipTests>true</skipTests>
         </configuration>
       </plugin>

    </plugins>
    <resources>
         <resource>
         <directory>src/main/resources</directory>
       </resource>
       <resource>
         <filtering>false</filtering>
         <directory>src/main/java</directory>
         <includes>
          <include>**/*.xls</include>
         </includes>
       </resource>
       <resource>
         <filtering>false</filtering>
         <directory>src/main/resources</directory>
         <includes>
          <include>**/*.properties</include>
         </includes>
       </resource>
    </resources>
    <pluginManagement>
       <plugins>
         <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-surefire-plugin</artifactId>
          <version>2.17</version>
         </plugin>
       </plugins>
    </pluginManagement>
</build>

의견 추가하기

연관태그

← 목록으로