2016-09-27 1 views
0

gwt-2.8.0-SNAPSHOT을 실행 중이며 잠시 실행했습니다. 내가 일어난 일이나 그 원인을 기억하지 못한다. 그러나 편집은 단지 하나의 순열을 만들고있다. 각 브라우저에 대한 순열을 컴파일하지 않습니다. 나는 이전에 사용자 에이전트 플래그를 구성했으나 오랫동안 삭제되었습니다. 이 문제가 발생할 수있는 특정 플래그에 대한 내 pom.xml을 검사 한 후 user.agent 플래그에 대해 다른 상속 된 모듈을 검사했지만 아무것도 찾을 수없는 것 같습니다. 또한 컴파일 로깅을 모두 활성화했으며 문제를 찾지 못했습니다. 나는 gwt-2.8.0을 가정하고있다. - SNAPSHOT은이 옵션을 단지 하나의 순열을 구성하기 위해 구성하지 않는다.GWT 컴파일러 - 하나의 침투 만이 형성됩니다.

업데이트 1

난 단지에만 생산 모듈을 컴파일하고있다. Adam은 개발 모듈에서 사용하는 축소 형 모든 속성이 단일 컴파일을 빌드한다는 점을 현명하게 지적했습니다. 이것은 생산 모듈에 의해 선택되지 않았으며 좋은 측정을 위해 나는 그것을 확인하기 위해 주석 처리했다. 제작 모듈에 가능한 모든 user.agents를 추가하는 아이디어가있었습니다. 이 작업을 수행 할 때 user.agent를 재정의 할 수 없다는 오류가 발생합니다. 상속 된 모듈 중 하나가이 속성을 설정하고 있다는 느낌이 들었습니다. 어떤 모듈이 속성을 설정하고 있지만 운이 없는지 알아낼 수 있는지보기 위해 loglevel을 ALL로 설정하려고 시도했습니다. 어떤 모듈이이 문제를 일으키는 지 파악할 때까지 계속 파고들 것입니다. 2

<define-property name="user.agent" values="ie8,gecko1_8,safari,ie9,ie10"></define-property> 

업데이트 난 그냥 생산 모듈에있는 모든 user.agents에 대한 설정 - 속성을 사용하여 주변에 임시 작품을 발견했다. 나는 아직도이 자산이 어디로 갈지 모를 것이다. 나는 상속 된 모듈 중 일부를 살펴 보았지만 범인을 찾을 수 없었다.

<set-property name="user.agent" value="ie8,gecko1_8,safari,ie9,ie10"></set-property> 

공통 모듈

공통 모듈 개발 및 생산 모듈 사이에 공유됩니다. 모든 상속 및 공통 정의가 있습니다. (가) 있습니다

<?xml version="1.0" encoding="UTF-8"?> 
<!DOCTYPE module PUBLIC "-//Google Inc.//DTD Google Web Toolkit 2.5.1//EN" "http://google-web-toolkit.googlecode.com/svn/tags/2.5.1/distro-source/core/src/gwt-module.dtd"> 
<module> 

    <inherits name="com.google.gwt.user.User" /> 
    <inherits name="com.google.gwt.place.Place" /> 
    <inherits name="com.google.gwt.activity.Activity" /> 
    <inherits name="com.google.gwt.logging.Logging" /> 
    <inherits name='com.google.gwt.inject.Inject' /> 


    <inherits name="gwt.material.design.GwtMaterialWithJQuery" /> 
    <inherits name="gwt.material.design.GwtMaterialTableDebug" /> 
    <inherits name="gwt.material.design.GwtMaterialDesignBasic" /> 
    <inherits name="gwt.material.design.addins.GwtMaterialAddins" /> 
    <inherits name="gwt.material.design.themes.GwtMaterialThemeBlue" /> 

    <inherits name="com.googlecode.gwt.charts.Charts" /> 

    <!-- Maps --> 
    <inherits name='com.google.gwt.maps.Maps' /> 

    <!-- Maybe remove --> 

    <inherits name='com.google.common.base.Base' /> 
    <inherits name="com.google.common.collect.Collect" /> 
    <inherits name="com.google.common.util.concurrent.Concurrent" /> 
    <inherits name="com.google.common.cache.Cache" /> 

    <inherits name='com.googlecode.gflot.GFlotJQueryNoConflict' /> 
    <inherits name="org.fusesource.restygwt.RestyGWT" /> 

    <!-- Adding temporal support --> 
    <replace-with class="com.upsnap.dsp.web.client.temporal.ChronoUnit"> 
     <when-type-is class="java.time.temporal.ChronoUnit" /> 
    </replace-with> 

    <public path='view/resource'> 
     <include name='css/*.css' /> 
     <include name='js/*.js' /> 
    </public> 

    <set-property name="restygwt.autodetect.plainText" value="true" /> 

    <!-- This is so gflot doesn't fail This should almost assuredly be disabled 
     for production --> 
    <set-configuration-property name='xsiframe.failIfScriptTag' 
     value='false' /> 


    <!-- May be dangerous, do some more investigation 8-2016 --> 
    <!-- <set-configuration-property name="compiler.enum.obfuscate.names" value="true" 
     /> --> 

    <!-- Enabling GSS will tell the GWT compiler to use GSS for all CssResource 
     interfaces. This flag can either be “false” (default) or “true”. --> 
    <set-configuration-property name="CssResource.enableGss" 
     value="true" /> 

    <!-- If GSS is enabled and the GWT compiler finds a .css file, it will first 
     convert this file to gss and then feed it into GSS on the fly. Gradual GSS 
     migration --> 
    <set-configuration-property name="CssResource.conversionMode" 
     value="strict" /> 

    <source path='client' /> 
</module> 

생산 모듈

생산 모듈입니다.

<?xml version="1.0" encoding="UTF-8"?> 
<!DOCTYPE module PUBLIC "-//Google Inc.//DTD Google Web Toolkit 2.5.1//EN" "http://google-web-toolkit.googlecode.com/svn/tags/2.5.1/distro-source/core/src/gwt-module.dtd"> 
<module rename-to='dsp'> 

    <inherits name="com.upsnap.dsp.web.DspCommon" /> 

    <set-property name="gwt.logging.enabled" value="TRUE" /> 
    <set-property name="gwt.logging.logLevel" value="INFO" /> 

    <set-property name="compiler.stackMode" value="strip" /> 

    <!-- Form Factor support --> 
    <replace-with class="com.upsnap.dsp.web.client.DesktopInjectorProvider"> 
     <when-type-is class="com.upsnap.dsp.web.client.InjectorProvider" /> 
    </replace-with> 

</module> 

발전 모듈

이 GWT 플러그인 디버깅 등

<?xml version="1.0" encoding="UTF-8"?> 
<!DOCTYPE module PUBLIC "-//Google Inc.//DTD Google Web Toolkit 2.5.1//EN" "http://google-web-toolkit.googlecode.com/svn/tags/2.5.1/distro-source/core/src/gwt-module.dtd"> 
<module rename-to='dsp'> 

    <inherits name="com.upsnap.dsp.web.DspCommon" /> 

    <set-property name="gwt.logging.enabled" value="TRUE" /> 
    <set-property name="gwt.logging.logLevel" value="FINE" /> 

    <set-property name="compiler.stackMode" value="emulated" /> 
    <set-configuration-property name="compiler.emulatedStack.recordFileNames" 
     value="true" /> 
    <set-configuration-property name="compiler.emulatedStack.recordLineNumbers" 
     value="true" /> 

    <collapse-all-properties /> 

    <!-- Form Factor support --> 
    <replace-with class="com.upsnap.dsp.web.client.DesktopInjectorProvider"> 
     <when-type-is class="com.upsnap.dsp.web.client.InjectorProvider" /> 
    </replace-with> 

</module> 

POM

의 pom.xml 발췌 사용 발전 모듈이다.

<configuration> 
    <disableCastChecking>true</disableCastChecking> 
    <disableClassMetadata>true</disableClassMetadata> 
    <style>PRETTY</style> 
    <logLevel>INFO</logLevel> 
    <runTarget>dsp.html</runTarget> 
    <hostedWebapp>${war.directory}</hostedWebapp> 
    <webappDirectory>${war.directory}</webappDirectory> 
    <copyWebapp>true</copyWebapp> 
    <localWorkers>4</localWorkers> 
    <modules><module>com.upsnap.dsp.web.DevelopmentDesktop</module> 
    </modules> 
    <extraJvmArgs>-Xms1024M -Xmx2048M -Dgwt.compiler.enableClosureCompiler=true</extraJvmArgs> 
</configuration> 

출력

이것은 단지 1 순열이 건설되고 있다는 것을 컴파일 공지 사항에서 출력됩니다.

[INFO] --- gwt-maven-plugin:2.8.0-SNAPSHOT:compile (default) @ dsp-web --- 
[INFO] Loading inherited module 'com.upsnap.dsp.web.DevelopmentDesktop' 
[INFO] Loading inherited module 'com.upsnap.dsp.web.DspCommon' 
[INFO]  Loading inherited module 'gwt.material.design.GwtMaterialWithJQuery' 
[INFO]   Loading inherited module 'gwt.material.design.GwtMaterialDesignBase' 
[INFO]    [WARN] Line 45: Setting configuration property named 'CssResource.legacy' in module 'gwt.material.design.GwtMaterialDesignBase' that has not been previously defined 
[INFO] Compiling module com.upsnap.dsp.web.DevelopmentDesktop 
[INFO] Ignored 9 units with compilation errors in first pass. 
[INFO] Compile with -strict or with -logLevel set to TRACE or DEBUG to see all errors. 
[INFO] Computing all possible rebind results for 'com.upsnap.dsp.web.client.rest.ExtraCodecs.ErrorResponseCodec' 
[INFO]  Rebinding com.upsnap.dsp.web.client.rest.ExtraCodecs.ErrorResponseCodec 
[INFO]   Invoking generator org.fusesource.restygwt.rebind.JsonEncoderDecoderGenerator 
[INFO]    Generating: com.upsnap.dsp.web.client.rest.ExtraCodecs_ErrorResponseCodec_Generated_ExtendedJsonEncoderDecoder_ 
[INFO]    checking: org.fusesource.restygwt.client.JsonEncoderDecoder, type: class com.google.gwt.dev.javac.typemodel.JParameterizedType 
[INFO] Compiling 1 permutation 
[INFO]  Compiling permutation 0... 
[INFO] Compile of permutations succeeded 
[INFO] Compilation succeeded -- 33.295s 
[INFO] Linking into /Users/chinshaw/devel/workspace/upsnap/dsp/modules/web/target/dsp-web-0.0.1-SNAPSHOT/dsp 
[INFO] Invoking Linker Cross-Site-Iframe 
[INFO]  Ignoring the following script tags in the gwt.xml file 
[INFO] jquery-1.8.3.min.js 
[INFO] jquery-noconflict.js 
[INFO] 
[INFO] Link succeeded 
[INFO] Linking succeeded -- 0.174s 
[INFO] 
+1

업데이트 후, 컴파일 된 모듈에서'compilation-mappings.txt' 파일을 확인하십시오. 사용자 에이전트 값에 매핑 된 컴파일 된 * .js 파일 이름이 포함되어야합니다. – Adam

답변

2

<collapse-all-properties />을 사용했기 때문입니다. 즉, 각 사용자 에이전트에 대한 순열을 생성하는 대신 모든 사용자 에이전트에 대해 하나의 순열만을 생성합니다.

+0

설명에이를 추가해야했습니다. 나는 collapse-all-properties를 포함하지 않는 생산 모듈만을 컴파일 중이다. 나는 또한 그것이 차이를 만들지를 알기 위해 이것을 논평하려했지만 시도하지 않았다. 나는 생산 모듈에 \t 를 추가하려고 시도했다. 모든 모듈이 있지만이 오류는 내가 user.agent를 다시 정의 할 수 없다는 오류를주었습니다. 이것은 상속 된 모듈 중 하나가이 구성을 정의하고 있다고 믿게합니다. –

+0

표시되는 로그는 개발 모듈에 관한 것입니다. –

관련 문제