This Bugzilla instance is deprecated, and most Eclipse projects now use GitHub or Eclipse GitLab. Please see the deprecation plan for details.
Bug 530467 - compile failed in org/eclipse/wst/xsl/xalan/debugger with Tycho 1.1.0-SNAPSHOT (3.10.0.M5)
Summary: compile failed in org/eclipse/wst/xsl/xalan/debugger with Tycho 1.1.0-SNAPSHO...
Status: RESOLVED FIXED
Alias: None
Product: WTP Source Editing
Classification: WebTools
Component: wst.xsl (show other bugs)
Version: unspecified   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: 3.10 (Photon)   Edit
Assignee: Project Inbox CLA
QA Contact: Jesper Moller CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-01-29 14:45 EST by Nick Boldt CLA
Modified: 2018-02-15 13:57 EST (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Nick Boldt CLA 2018-01-29 14:45:54 EST
The aggregate build is failing because Tycho 1.1.0-SNAPSHOT says:

[DEBUG] Closing connection to remote
[ERROR] Failed to execute goal org.eclipse.tycho:tycho-compiler-plugin:1.1.0-SNAPSHOT:compile (default-compile) on project org.eclipse.wst.xsl.xalan: Compilation failure: Compilation failure: 
[ERROR] /jobs/genie.webtools/WTP-R3_10_Integration/workspace/webtools.sourceediting/xsl/bundles/org.eclipse.wst.xsl.xalan/src-debugger/org/eclipse/wst/xsl/xalan/debugger/XalanDebugger.java:[46] 
[ERROR] 	lastTransformerInChain.getSerializationHandler().flushPending();
[ERROR] 	                       ^^^^^^^^^^^^^^^^^^^^^^^
[ERROR] The method getSerializationHandler() is undefined for the type TransformerImpl
[ERROR] /jobs/genie.webtools/WTP-R3_10_Integration/workspace/webtools.sourceediting/xsl/bundles/org.eclipse.wst.xsl.xalan/src-debugger/org/eclipse/wst/xsl/xalan/debugger/XalanStyleFrame.java:[131] 
[ERROR] 	currentLine = e.m_styleNode.getEndLineNumber();
[ERROR] 	                            ^^^^^^^^^^^^^^^^
[ERROR] The method getEndLineNumber() is undefined for the type ElemTemplateElement
[ERROR] 2 problems (2 errors)

Back to you in the studio, sourceediting folks.

https://hudson.eclipse.org/webtools/view/webtools_R3_10/job/WTP-R3_10_Integration/237/console

Also failing in the CI build:

https://hudson.eclipse.org/webtools/view/webtools_R3_10/job/webtools-sourceediting_R3_10/48/
Comment 1 Nitin Dahyabhai CLA 2018-01-29 16:05:53 EST
Neither org.eclipse.wst.xsl.xalan nor the Xalan bundle it uses from Orbit have changed in years, so it's either an intentional or
unintentional change in Tycho 1.1.
Comment 2 Nick Boldt CLA 2018-01-29 17:13:57 EST
Definitely a change caused by Tycho 1.1:

https://hudson.eclipse.org/webtools/view/webtools_R3_10/job/webtools-sourceediting_R3_10/53/ <-- green, using Tycho 1.0.0 and mvn 3.5.2

https://hudson.eclipse.org/webtools/view/webtools_R3_10/job/webtools-sourceediting_R3_10/48/ <-- red, using Tycho 1.1.0-SNAPSHOT and mvn 3.3
https://hudson.eclipse.org/webtools/view/webtools_R3_10/job/webtools-sourceediting_R3_10/52/ <-- red, using Tycho 1.1.0-SNAPSHOT and mvn 3.5.2
Comment 3 Nitin Dahyabhai CLA 2018-01-29 17:34:11 EST
(In reply to Nick Boldt from comment #2)
> Definitely a change caused by Tycho 1.1:
> 
> https://hudson.eclipse.org/webtools/view/webtools_R3_10/job/webtools-
> sourceediting_R3_10/53/ <-- green, using Tycho 1.0.0 and mvn 3.5.2
> 
> https://hudson.eclipse.org/webtools/view/webtools_R3_10/job/webtools-
> sourceediting_R3_10/48/ <-- red, using Tycho 1.1.0-SNAPSHOT and mvn 3.3
> https://hudson.eclipse.org/webtools/view/webtools_R3_10/job/webtools-
> sourceediting_R3_10/52/ <-- red, using Tycho 1.1.0-SNAPSHOT and mvn 3.5.2

Is there something we can do to eliminate the different versions of Maven as the cause?
Comment 4 Nitin Dahyabhai CLA 2018-01-29 17:38:13 EST
(In reply to Nitin Dahyabhai from comment #3)
> Is there something we can do to eliminate the different versions of Maven as
> the cause?

Nevermind, I see that you've dug into that already.
Comment 5 Jan Sievers CLA 2018-01-30 03:13:47 EST
could be you have two versions of org.apache.xalan.transformer.TransformerImpl in the buildpath and it's a matter of chance which one wins. Check compiler classpath using mvn -X
Comment 6 Nick Boldt CLA 2018-01-30 09:42:36 EST
Running with Tycho 1.1, mvn 3.5.2, and -X flag:

https://hudson.eclipse.org/webtools/view/webtools_R3_10/job/webtools-sourceediting_R3_10/54/
Comment 7 Jan Sievers CLA 2018-01-30 09:45:59 EST
(In reply to Jan Sievers from comment #5)
> could be you have two versions of
> org.apache.xalan.transformer.TransformerImpl in the buildpath and it's a
> matter of chance which one wins. Check compiler classpath using mvn -X

could also be several versions of xalan in the p2 target platform of the build and again a matter of chance which one p2 picks
Comment 8 Jan Sievers CLA 2018-01-30 11:09:40 EST
(In reply to Jan Sievers from comment #7)
> (In reply to Jan Sievers from comment #5)
> > could be you have two versions of
> > org.apache.xalan.transformer.TransformerImpl in the buildpath and it's a
> > matter of chance which one wins. Check compiler classpath using mvn -X
> 
> could also be several versions of xalan in the p2 target platform of the
> build and again a matter of chance which one p2 picks

this is probably related to bug 514471 comment 17 where we had to drop compiler access rules for the JDK bootclasspath

you are compiling against JDK 1.4 which I think contains an old version org.apache.xalan.transformer.TransformerImpl . 

From the logs:

[DEBUG] JDT compiler args: [
-s, /jobs/genie.webtools/webtools-sourceediting_R3_10/workspace/xsl/bundles/org.eclipse.wst.xsl.xalan/target/generated-sources/annotations,

 -d, /jobs/genie.webtools/webtools-sourceediting_R3_10/workspace/xsl/bundles/org.eclipse.wst.xsl.xalan/target/classes,
 
  -classpath,
   /jobs/genie.webtools/webtools-sourceediting_R3_10/workspace/xsl/bundles/org.eclipse.wst.xsl.xalan/target/classes:

  /home/hudson/genie.webtools/.hudson/jobs/webtools-sourceediting_R3_10/workspace/.maven/repo/p2/osgi/bundle/org.apache.xalan/2.7.1.v201005080400/org.apache.xalan-2.7.1.v201005080400.jar


[+META-INF/services/*:+org/apache/regexp/*:+org/apache/xalan/*:+org/apache/xalan/client/*:+org/apache/xalan/extensions/*:+org/apache/xalan/lib/*:+org/apache/xalan/lib/sql/*:+org/apache/xalan/processor/*:+org/apache/xalan/res/*:+org/apache/xalan/serialize/*:+org/apache/xalan/templates/*:+org/apache/xalan/trace/*:+org/apache/xalan/transformer/*:+org/apache/xalan/xslt/*:+org/apache/xalan/xsltc/*:+org/apache/xalan/xsltc/cmdline/*:+org/apache/xalan/xsltc/cmdline/getopt/*:+org/apache/xalan/xsltc/compiler/*:+org/apache/xalan/xsltc/compiler/util/*:+org/apache/xalan/xsltc/dom/*:+org/apache/xalan/xsltc/runtime/*:+org/apache/xalan/xsltc/runtime/output/*:+org/apache/xalan/xsltc/trax/*:+org/apache/xalan/xsltc/util/*:+org/apache/xml/dtm/*:+org/apache/xml/dtm/ref/*:+org/apache/xml/dtm/ref/dom2dtm/*:+org/apache/xml/dtm/ref/sax2dtm/*:+org/apache/xml/res/*:+org/apache/xml/utils/*:+org/apache/xml/utils/res/*:+org/apache/xpath/*:+org/apache/xpath/axes/*:+org/apache/xpath/compiler/*:+org/apache/xpath/domapi/*:+org/apache/xpath/functions/*:+org/apache/xpath/jaxp/*:+org/apache/xpath/objects/*:+org/apache/xpath/operations/*:+org/apache/xpath/patterns/*:+org/apache/xpath/res/*:?**/*]

  :/home/hudson/genie.webtools/.hudson/jobs/webtools-sourceediting_R3_10/workspace/.maven/repo/p2/osgi/bundle/org.eclipse.osgi/3.13.0.v20180110-2102/org.eclipse.osgi-3.13.0.v20180110-2102.jar

  [?**/*]:

  /home/hudson/genie.webtools/.hudson/jobs/webtools-sourceediting_R3_10/workspace/.maven/repo/p2/osgi/bundle/org.apache.xml.serializer/2.7.1.v201005080400/org.apache.xml.serializer-2.7.1.v201005080400.jar

  [+org/apache/xml/serializer/*:+org/apache/xml/serializer/dom3/*:?**/*]:

  /jobs/genie.webtools/webtools-sourceediting_R3_10/workspace/xsl/bundles/org.eclipse.wst.xsl.jaxp.debug/target/classes

  [+org/eclipse/wst/xsl/jaxp/debug/debugger/*:+org/eclipse/wst/xsl/jaxp/debug/invoker/*:~org/eclipse/wst/xsl/jaxp/debug/invoker/internal/*:?**/*]:


  /home/hudson/genie.webtools/.hudson/jobs/webtools-sourceediting_R3_10/workspace/.maven/repo/p2/osgi/bundle/org.apache.commons.logging/1.1.1.v201101211721/org.apache.commons.logging-1.1.1.v201101211721.jar

  [+org/apache/commons/logging/*:+org/apache/commons/logging/impl/*:?**/*],

   /jobs/genie.webtools/webtools-sourceediting_R3_10/workspace/xsl/bundles/org.eclipse.wst.xsl.xalan/src-debugger/org/eclipse/wst/xsl/xalan/debugger/XalanPrintTraceListener.java,
   /jobs/genie.webtools/webtools-sourceediting_R3_10/workspace/xsl/bundles/org.eclipse.wst.xsl.xalan/src-debugger/org/eclipse/wst/xsl/xalan/debugger/XalanDebugger.java,
   /jobs/genie.webtools/webtools-sourceediting_R3_10/workspace/xsl/bundles/org.eclipse.wst.xsl.xalan/src-debugger/org/eclipse/wst/xsl/xalan/debugger/XalanStyleFrame.java, 
   /jobs/genie.webtools/webtools-sourceediting_R3_10/workspace/xsl/bundles/org.eclipse.wst.xsl.xalan/src-debugger/org/eclipse/wst/xsl/xalan/debugger/XalanVariable.java,
   /jobs/genie.webtools/webtools-sourceediting_R3_10/workspace/xsl/bundles/org.eclipse.wst.xsl.xalan/src-debugger/org/eclipse/wst/xsl/xalan/debugger/XalanTraceListener.java,
    /jobs/genie.webtools/webtools-sourceediting_R3_10/workspace/xsl/bundles/org.eclipse.wst.xsl.xalan/src-debugger/org/eclipse/wst/xsl/xalan/debugger/XalanRootStyleFrame.java,

        -g, -nowarn, -target, 1.2, -source, 1.3, 

        -warn:+discouraged,forbidden,

         -bootclasspath,

          /opt/public/common/j2sdk1.4.2_19/jre/lib/rt.jar:
          /opt/public/common/j2sdk1.4.2_19/jre/lib/jce.jar:
          /opt/public/common/j2sdk1.4.2_19/jre/lib/sunrsasign.jar:
          /opt/public/common/j2sdk1.4.2_19/jre/lib/jsse.jar:
          /opt/public/common/j2sdk1.4.2_19/jre/lib/plugin.jar:
          /opt/public/common/j2sdk1.4.2_19/jre/lib/charsets.jar:
          /opt/public/common/j2sdk1.4.2_19/jre/lib/ext/dnsns.jar:
          /opt/public/common/j2sdk1.4.2_19/jre/lib/ext/ldapsec.jar:
          /opt/public/common/j2sdk1.4.2_19/jre/lib/ext/sunjce_provider.jar:
          /opt/public/common/j2sdk1.4.2_19/jre/lib/ext/localedata.jar]


I suppose this used to work only because the package org.apache.xalan.transformer from the bootclasspath was not made accessible via classpath access rules based on JDK 1.4 official packages [1].

not sure how to avoid the JDK 1.4 xalan taking precedence for now as long as you use useJDK=BREE to compile against JDK declared by the bundle's BREE.

Either update the bundle's BREE (I know, not nice and just a workaround) or drop useJDK=BREE for now and compile against currently running JDK


[1] https://github.com/eclipse/rt.equinox.framework/blob/99ea6b27ab528bdc5a5158fab0b9c8f4208a359a/bundles/org.eclipse.osgi/J2SE-1.4.profile#L11-L151
Comment 9 Eclipse Genie CLA 2018-01-30 15:08:17 EST
New Gerrit change created: https://git.eclipse.org/r/116372
Comment 10 Rob Stryker CLA 2018-02-02 18:42:43 EST
So Nick's patch to update the BREE failed (no idea why) and the build log is old and deleted. 

I added his BREE update to this gerrit:  https://hudson.eclipse.org/webtools/job/webtools-sourceediting-gerrit_master/313/

It mostly builds but has 2 test failures. To me this is a success and indicates that this patch should be merged, and maybe the two tests should be investigated by someone more sourceediting than I am. 

WDYT?
Comment 11 Nick Boldt CLA 2018-02-15 13:57:33 EST
Fixed in 3.10.M6.