Open cdietrich opened 6 years ago
enhanced looging:
bad:
Begin testNewlyAddedReexportedSource
reallyWaitForAutoBuild
[foo; []]
[foo; []]
reallyWaitForAutoBuild
[foo; []]
reallyWaitForAutoBuild
[bar; [], foo; []]
reallyWaitForAutoBuild
[bar; [], foo; []]
reallyWaitForAutoBuild
[bar; [], baz; [], foo; []]
reallyWaitForAutoBuild
[bar; [], baz; [], foo; []]
forget foo FULL
forget bar FULL
forget baz FULL
reallyWaitForAutoBuild
forget bar FULL
[bar; [], baz; [], foo; []]
build bar FULL
Result for bar -> foo
build baz FULL
Result for baz ->
build foo FULL
Result for foo ->
reallyWaitForAutoBuild
forget baz FULL
[bar; [], baz; [], foo; []]
build baz FULL
Result for baz -> bar
forget baz FULL
forget baz FULL
waitForBuild 1
reallyWaitForAutoBuild
[bar; [], baz; [], foo; []]
build baz FULL
doUpdate: baz
queueURI: platform:/resource/baz/src/Baz.buildertestlanguage
Result for baz -> bar
assert 1
org.eclipse.core.internal.resources.Workspace@2f84848e
reallyWaitForAutoBuild
forget foo FULL
[bar; [], baz; [], foo; []]
build bar AUTO
Result for bar -> foo
build baz AUTO
Result for baz -> bar
build foo FULL
doUpdate: foo
queueURI: archive:platform:/resource/foo/foo.jar!/foo/Foo.buildertestlanguage
queueURI: platform:/resource/baz/src/Baz.buildertestlanguage
Result for foo ->
waitForBuild 2
reallyWaitForAutoBuild
assert 2
reallyWaitForAutoBuild
doUpdate: baz
doUpdate: foo
[]
good:
Begin testNewlyAddedReexportedSource
reallyWaitForAutoBuild
[foo; []]
[foo; []]
reallyWaitForAutoBuild
[foo; []]
reallyWaitForAutoBuild
[bar; [], foo; []]
reallyWaitForAutoBuild
[bar; [], foo; []]
reallyWaitForAutoBuild
[bar; [], baz; [], foo; []]
reallyWaitForAutoBuild
[bar; [], baz; [], foo; []]
forget foo FULL
forget bar FULL
forget baz FULL
reallyWaitForAutoBuild
forget bar FULL
[baz; [], foo; [], bar; []]
build baz FULL
Result for baz ->
build foo FULL
Result for foo ->
build bar FULL
Result for bar -> foo
reallyWaitForAutoBuild
forget baz FULL
[foo; [], bar; [], baz; []]
build baz FULL
Result for baz -> bar
forget baz FULL
forget baz FULL
waitForBuild 1
reallyWaitForAutoBuild
[foo; [], bar; [], baz; []]
build baz FULL
doUpdate: baz
queueURI: platform:/resource/baz/src/Baz.buildertestlanguage
Result for baz -> bar
assert 1
org.eclipse.core.internal.resources.Workspace@5126c0cd
reallyWaitForAutoBuild
forget foo FULL
[foo; [], bar; [], baz; []]
build foo FULL
doUpdate: foo
queueURI: archive:platform:/resource/foo/foo.jar!/foo/Foo.buildertestlanguage
queueURI: platform:/resource/baz/src/Baz.buildertestlanguage
Result for foo ->
build bar AUTO
Result for bar -> foo
build baz AUTO
doUpdate: baz
Result for baz -> bar
waitForBuild 2
reallyWaitForAutoBuild
assert 2
End testNewlyAddedReexportedSource
reallyWaitForAutoBuild
doUpdate: baz
doUpdate: foo
Helps:
addToClasspath(foo, newLibraryEntry);
addToClasspath(bar, JavaCore.newProjectEntry(foo.getPath(), true));
addToClasspath(baz, JavaCore.newProjectEntry(bar.getPath(), false));
Workspace ws = ((org.eclipse.core.internal.resources.Workspace)ResourcesPlugin.getWorkspace());
Method method = Workspace.class.getDeclaredMethod("flushBuildOrder");
method.setAccessible(true);
method.invoke(ws);
cause:
SetClasspathOperation no longer calls ProjectReferenceChange
=>
addToClasspath(bar, JavaCore.newProjectEntry(foo.getPath(), true));
setReference(bar.getProject(),foo.getProject());
addToClasspath(baz, JavaCore.newProjectEntry(bar.getPath(), false));
setReference(baz.getProject(),bar.getProject());
helps too
=> we should rework addToClasspath / removeFromClasspath
https://bugs.eclipse.org/bugs/show_bug.cgi?id=507795#c15 https://github.com/eclipse/eclipse.jdt.core/commit/f7ed9839ef5f6bfc6dd1db3bdc1a458b7b45c64b#diff-cedc3f8c2d2afc863a49dd8665e5487a
maybe we get it running with IDynamicReferenceProvider, first try did not work
have no idea whats happening
Build can be run against Photon with -PusePhotonTarget
still have no clue/idea how to tackle this problem
maybe we get it running with IDynamicReferenceProvider, first try did not work
Do you still have the code around?
no, it was a 1:1 copy of the one from jdt's org.eclipse.jdt.internal.core.DynamicProjectReferences
the registration is done via the builder
code from jdt
<extension
point="org.eclipse.core.resources.builders"
id="javabuilder"
name="%javaBuilderName">
<builder>
<run class="org.eclipse.jdt.internal.core.builder.JavaBuilder">
</run>
<dynamicReference class="org.eclipse.jdt.internal.core.DynamicProjectReferences"/>
</builder>
</extension>
clear milestone
http://services.typefox.io/open-source/jenkins/job/xtext-eclipse/job/cd_photon/4/testReport/ has failing tests e.g.
org.eclipse.xtext.builder.impl.SimpleProjectsIntegrationTest.testNewlyAddedReexportedSource org.eclipse.xtext.builder.impl.SimpleProjectsIntegrationTest.testReexportedJarRemoved
the same fail on my local machine (agains oxygen) on others it does not
it seems to be a race how builds and forget builds are executed
good case:
bad case