tbouron commented on issue #1049: Retry flaky unit tests
URL: https://github.com/apache/brooklyn-server/pull/1049#issuecomment-471919561
 
 
   Hey @geomacy. So we spent some time on this and it turns out that it is a 
problem specifically on MacOS. It was introduced when the version of 
`felix.framework.version` was bumped to `5.6.10`.
   
   Long story short, this version changed how Felix framework handles extension 
bundles. It appends bundles to the classpath as they're installed.
   
   So when e.g. a test in `org.apache.brooklyn.launcher.WebAppRunnerTest` runs 
all of the extension bundles are cached and added to the classpath. When the 
test completes the cache directory is deleted.
   
   But when a second test runs, EmbeddedFelixFramework discovers the bundles 
from the last test which triggers:
   ```
   2018-11-30 16:43:44,041 WARN  o.a.b.r.f.EmbeddedFelixFramework [main]: 
Unable to install manifest from 
jar:file:/Users/sam/.brooklyn/osgi/cache/wcx9QUag/bundle175/version0.0/bundle.jar!/META-INF/MANIFEST.MF:
 java.lang.IllegalStateException: Problem installing extension bundle 
jar:file:/Users/sam/.brooklyn/osgi/cache/wcx9QUag/bundle175/version0.0/bundle.jar!/META-INF/MANIFEST.MF:
 java.io.FileNotFoundException: 
/Users/sam/.brooklyn/osgi/cache/wcx9QUag/bundle175/version0.0/bundle.jar (No 
such file or directory)
   java.lang.IllegalStateException: Problem installing extension bundle 
jar:file:/Users/sam/.brooklyn/osgi/cache/wcx9QUag/bundle175/version0.0/bundle.jar!/META-INF/MANIFEST.MF:
 java.io.FileNotFoundException: 
/Users/sam/.brooklyn/osgi/cache/wcx9QUag/bundle175/version0.0/bundle.jar (No 
such file or directory)
        at 
org.apache.brooklyn.rt.felix.EmbeddedFelixFramework.installExtensionBundle(EmbeddedFelixFramework.java:212)
 [brooklyn-rt-felix-1.0.0-SNAPSHOT.jar:1.0.0-SNAPSHOT]
        at 
org.apache.brooklyn.rt.felix.EmbeddedFelixFramework.installBootBundles(EmbeddedFelixFramework.java:143)
 [brooklyn-rt-felix-1.0.0-SNAPSHOT.jar:1.0.0-SNAPSHOT]
        at 
org.apache.brooklyn.rt.felix.EmbeddedFelixFramework.newFrameworkStarted(EmbeddedFelixFramework.java:106)
 [brooklyn-rt-felix-1.0.0-SNAPSHOT.jar:1.0.0-SNAPSHOT]
        at 
org.apache.brooklyn.rt.felix.EmbeddedFramework.getFramework(EmbeddedFramework.java:30)
 [brooklyn-rt-felix-1.0.0-SNAPSHOT.jar:1.0.0-SNAPSHOT]
        at 
org.apache.brooklyn.util.core.osgi.Osgis.getFramework(Osgis.java:301) 
[brooklyn-core-1.0.0-SNAPSHOT.jar:1.0.0-SNAPSHOT]
        at 
org.apache.brooklyn.core.mgmt.ha.OsgiManager.start(OsgiManager.java:273) 
[brooklyn-core-1.0.0-SNAPSHOT.jar:1.0.0-SNAPSHOT]
        at 
org.apache.brooklyn.core.mgmt.internal.LocalManagementContext.<init>(LocalManagementContext.java:184)
 [brooklyn-core-1.0.0-SNAPSHOT.jar:1.0.0-SNAPSHOT]
        at 
org.apache.brooklyn.launcher.common.BasicLauncher.initManagementContext(BasicLauncher.java:539)
 [brooklyn-launcher-common-1.0.0-SNAPSHOT.jar:1.0.0-SNAPSHOT]
        at 
org.apache.brooklyn.launcher.BrooklynLauncher.initManagementContext(BrooklynLauncher.java:241)
 [classes/:na]
        at 
org.apache.brooklyn.launcher.common.BasicLauncher.startPartOne(BasicLauncher.java:394)
 [brooklyn-launcher-common-1.0.0-SNAPSHOT.jar:1.0.0-SNAPSHOT]
        at 
org.apache.brooklyn.launcher.common.BasicLauncher.start(BasicLauncher.java:379) 
[brooklyn-launcher-common-1.0.0-SNAPSHOT.jar:1.0.0-SNAPSHOT]
        at 
org.apache.brooklyn.launcher.WebAppRunnerTest.testStartWithLauncher(WebAppRunnerTest.java:143)
 [test-classes/:na]
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to