2014-11-27 16 views
0

새로운 javax.faces.jar 및 javax.을 복사하여 glassfish 3.1.2.2를 Mojarra 2.2.8-03으로 업데이트했습니다. el.jar를 $ GLASSFISH_HOME/glassfish/modules 디렉토리로 복사하십시오. 응용 프로그램을 재배포 한 후 concat 함수가 더 이상 해석되지 않는다는 것을 알았습니다.이 코드로 JSF 페이지를 렌더링하려고하면 다음 오류가 발생합니다. 어디서 잘못했는지 궁금 해서요. 도서관이나 프로젝트 pom.xml을 잊어 버렸다고 생각합니다. 이것은 devbe 컴퓨터에 넷빈을 사용하여 배포합니다.glassfish 3.1.2.2를 Mojara 2.2.8-03으로 업그레이드했습니다. 복합 기능의 EL 기능이 작동을 멈 춥니 다.

예외는 여기에

javax.faces.view.facelets.FaceletException: Function 'of:concat' not found 
    at com.sun.faces.facelets.tag.AbstractTagLibrary$UserComponentHandlerFactory.createHandler(AbstractTagLibrary.java:344) 
    at com.sun.faces.facelets.tag.AbstractTagLibrary.createTagHandler(AbstractTagLibrary.java:723) 
    at com.sun.faces.facelets.tag.CompositeTagLibrary.createTagHandler(CompositeTagLibrary.java:194) 
    at com.sun.faces.facelets.compiler.TagUnit.createFaceletHandler(TagUnit.java:121) 
    at com.sun.faces.facelets.compiler.TextUnit.createFaceletHandler(TextUnit.java:117) 
    at com.sun.faces.facelets.compiler.CompilationUnit.getNextFaceletHandler(CompilationUnit.java:115) 
    at com.sun.faces.facelets.compiler.TagUnit.getNextHandler(TagUnit.java:125) 
at javax.faces.view.facelets.TagHandler.<init>(TagHandler.java:116) 
    at com.sun.faces.facelets.tag.TagHandlerImpl.<init>(TagHandlerImpl.java:58) 
    at com.sun.faces.facelets.tag.composite.ImplementationHandler.<init>(ImplementationHandler.java:76) 
    at sun.reflect.GeneratedConstructorAccessor186.newInstance(Unknown Source) 
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) 
... 

을 던져 프로젝트의 pom.xml입니다.

<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> 

    <snip package info /> 

    <properties> 
     <endorsed.dir>${project.build.directory}/endorsed</endorsed.dir> 
     <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> 
     <netbeans.hint.deploy.server>gfv3ee6</netbeans.hint.deploy.server> 
    </properties> 

    <dependencies> 
     <dependency> 
      <groupId>com.smartbear</groupId> 
      <artifactId>swagger4j</artifactId> 
      <version>1.0-beta4</version> 
     </dependency> 
     <dependency> 
      <groupId>com.wordnik</groupId> 
      <artifactId>swagger-jaxrs_2.10</artifactId> 
      <version>1.3.1</version> 
      <scope>compile</scope> 
     </dependency> 
     <dependency> 
      <groupId>org.glassfish</groupId> 
      <artifactId>javax.json</artifactId> 
      <version>1.0-b06</version> 
     </dependency> 
     <dependency> 
      <groupId>org.omnifaces</groupId> 
      <artifactId>omnifaces</artifactId> 
      <version>1.8.1</version> 
     </dependency> 
     <dependency> 
      <groupId>junit</groupId> 
      <artifactId>junit</artifactId> 
      <version>4.10</version> 
      <scope>test</scope> 
     </dependency> 
     <dependency> 
      <groupId>org.mockito</groupId> 
      <artifactId>mockito-all</artifactId> 
      <version>1.9.5</version> 
      <scope>test</scope> 
     </dependency> 
     <dependency> 
      <groupId>org.apache.httpcomponents</groupId> 
      <artifactId>httpclient</artifactId> 
      <version>4.2.5</version> 
     </dependency> 
     <dependency> 
      <groupId>commons-io</groupId> 
      <artifactId>commons-io</artifactId> 
      <version>2.4</version> 
     </dependency> 
     <dependency> 
      <groupId>ch.qos.logback</groupId> 
      <artifactId>logback-classic</artifactId> 
      <version>1.0.13</version> 
     </dependency> 
     <dependency> 
      <groupId>com.fasterxml.jackson.core</groupId> 
      <artifactId>jackson-core</artifactId> 
      <version>2.1.1</version> 
     </dependency> 
     <dependency> 
      <groupId>org.codehaus.jackson</groupId> 
      <artifactId>jackson-mapper-asl</artifactId> 
      <version>1.9.12</version> 
     </dependency> 
     <dependency> 
      <groupId>org.glassfish.extras</groupId> 
      <artifactId>glassfish-embedded-all</artifactId> 
      <version>3.2-b06</version> 
      <scope>test</scope> 
     </dependency> 
     <dependency> 
      <groupId>org.glassfish.main.extras</groupId> 
      <artifactId>glassfish-embedded-all</artifactId> 
      <version>3.1.2.2</version> 
      <type>jar</type> 
      <scope>provided</scope> 
     </dependency> 
     <dependency> 
      <groupId>javax</groupId> 
      <artifactId>javaee-web-api</artifactId> 
      <version>6.0</version> 
      <scope>provided</scope> 
     </dependency> 
     <dependency> 
      <groupId>commons-validator</groupId> 
      <artifactId>commons-validator</artifactId> 
      <version>1.3.1</version> 
     </dependency> 
     <dependency> 
      <groupId>oro</groupId> 
      <artifactId>oro</artifactId> 
      <version>2.0.8</version> 
     </dependency> 
     <dependency> 
      <groupId>org.eclipse.persistence</groupId> 
      <artifactId>eclipselink</artifactId> 
      <version>2.5.0</version> 
     </dependency> 
     <dependency> 
      <groupId>org.postgresql</groupId> 
      <artifactId>postgresql</artifactId> 
      <version>9.2-1002-jdbc4</version> 
     </dependency> 
     <dependency> 
      <groupId>com.google.guava</groupId> 
      <artifactId>guava</artifactId> 
      <version>14.0.1</version> 
     </dependency> 
     <dependency> 
      <groupId>joda-time</groupId> 
      <artifactId>joda-time</artifactId> 
      <version>2.2</version> 
     </dependency> 
     <dependency> 
      <groupId>org.primefaces</groupId> 
      <artifactId>primefaces</artifactId> 
      <version>4.0</version> 
     </dependency> 
     <dependency> 
      <groupId>org.primefaces.themes</groupId> 
      <artifactId>bootstrap</artifactId> 
      <version>1.0.10</version> 
     </dependency> 
     <dependency> 
      <groupId>dnsjava</groupId> 
      <artifactId>dnsjava</artifactId> 
      <version>2.1.6</version> 
     </dependency> 
    </dependencies> 

    <build> 
     <plugins> 
      <plugin> 
       <groupId>org.apache.maven.plugins</groupId> 
       <artifactId>maven-compiler-plugin</artifactId> 
       <version>2.3.2</version> 
       <configuration> 
        <source>1.7</source> 
        <target>1.7</target> 
        <compilerArguments> 
         <endorseddirs>${endorsed.dir}</endorseddirs> 
        </compilerArguments> 
        <showDeprecation>true</showDeprecation> 
       </configuration> 
      </plugin> 
      <plugin> 
       <groupId>org.apache.maven.plugins</groupId> 
       <artifactId>maven-war-plugin</artifactId> 
       <version>2.1.1</version> 
       <configuration> 
        <failOnMissingWebXml>false</failOnMissingWebXml> 
       </configuration> 
      </plugin> 
      <plugin> 
       <groupId>org.apache.maven.plugins</groupId> 
       <artifactId>maven-dependency-plugin</artifactId> 
       <version>2.1</version> 
       <executions> 
        <execution> 
         <phase>validate</phase> 
         <goals> 
          <goal>copy</goal> 
         </goals> 
         <configuration> 
          <outputDirectory>${endorsed.dir}</outputDirectory> 
          <silent>true</silent> 
          <artifactItems> 
           <artifactItem> 
            <groupId>javax</groupId> 
            <artifactId>javaee-endorsed-api</artifactId> 
            <version>6.0</version> 
            <type>jar</type> 
           </artifactItem> 
          </artifactItems> 
         </configuration> 
        </execution> 
       </executions> 
      </plugin> 
     </plugins> 
    </build> 
</project> 

답변

0

그것은이이 컴파일 작업에 사용 유효 JSF의 조각에 의해 발생 된 것으로 나타났다, 그러나 인 Mojarra의 최신 버전에서 컴파일되지 않습니다.

기존 코드

<h:outputLink value="/alink" target="_blank"> 
    #{msg[of:concat(of:concat('prefix-', cc.attrs.rType), '-postfix')]} 
</h:outputLink> 

새로운 코드

<h:outputLink value="/alink" target="_blank"> 
    <h:outputText value="#{msg[ca:concat('prefix-', cc.attrs.rType, '-postfix')]}" /> 
</h:outputLink>