[jbosstools-issues] [JBoss JIRA] (JBIDE-20384) Need public API for internal m2e function currently used via reflection

Rastislav Wagner (JIRA) issues at jboss.org
Fri Nov 6 08:00:03 EST 2015


     [ https://issues.jboss.org/browse/JBIDE-20384?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Rastislav Wagner closed JBIDE-20384.
------------------------------------


verified. Missing method is in m2e 1.6.2

> Need public API for internal m2e function currently used via reflection
> -----------------------------------------------------------------------
>
>                 Key: JBIDE-20384
>                 URL: https://issues.jboss.org/browse/JBIDE-20384
>             Project: Tools (JBoss Tools)
>          Issue Type: Bug
>          Components: maven
>    Affects Versions: 4.3.0.Beta1
>            Reporter: Brian Fitzpatrick
>            Assignee: Fred Bricon
>             Fix For: 4.3.0.CR1
>
>
> In the SwitchYard code for m2e support we have some code that references an internal method. 
> This is the line causing me grief - https://github.com/jboss-switchyard/tools/blob/master/eclipse/plugins/org.switchyard.tools.m2e/src/org/switchyard/tools/m2e/SwitchYardBuildParticipant.java#L181
> Does anybody know if this internal method has changed in the latest version of m2e for Mars? I know Rob C used the internal method for a reason, but am wondering if there's a cleaner way to do this.
> It's generating this exception in my tests:
> {code}
> $ mvn -U clean install > build2.log
> Picked up _JAVA_OPTIONS: -XX:-UseGCOverheadLimit -Xmx512m -Xmx1024m -XX:MaxMetas
> paceSize=256m
> SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
> SLF4J: Defaulting to no-operation (NOP) logger implementation
> SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
> java.lang.NoSuchMethodException: org.eclipse.m2e.core.internal.builder.plexusbuildapi.EclipseEmptyBuildContext.getFiles()
>         at java.lang.Class.getMethod(Class.java:1786)
>         at org.switchyard.tools.m2e.SwitchYardBuildParticipant.getRefreshedFiles(SwitchYardBuildParticipant.java:181)
>         at org.switchyard.tools.m2e.SwitchYardBuildParticipant.checkRefreshedFiles(SwitchYardBuildParticipant.java:151)
>         at org.switchyard.tools.m2e.SwitchYardBuildParticipant.build(SwitchYardBuildParticipant.java:97)
>         at org.eclipse.m2e.core.internal.builder.MavenBuilderImpl.build(MavenBuilderImpl.java:137)
>         at org.eclipse.m2e.core.project.configurator.AbstractLifecycleMapping.configure(AbstractLifecycleMapping.java:111)
>         at org.eclipse.m2e.core.internal.project.ProjectConfigurationManager$3.call(ProjectConfigurationManager.java:501)
>         at org.eclipse.m2e.core.internal.project.ProjectConfigurationManager$3.call(ProjectConfigurationManager.java:1)
>         at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:176)
>         at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:151)
>         at org.eclipse.m2e.core.internal.project.ProjectConfigurationManager.updateProjectConfiguration(ProjectConfigurationManager.java:494)
>         at org.eclipse.m2e.core.internal.project.ProjectConfigurationManager.configureNewMavenProjects(ProjectConfigurationManager.java:281)
>         at org.eclipse.m2e.core.internal.project.ProjectConfigurationManager$1.call(ProjectConfigurationManager.java:168)
>         at org.eclipse.m2e.core.internal.project.ProjectConfigurationManager$1.call(ProjectConfigurationManager.java:1)
>         at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:176)
>         at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:151)
>         at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:99)
>         at org.eclipse.m2e.core.internal.embedder.MavenImpl.execute(MavenImpl.java:1355)
>         at org.eclipse.m2e.core.internal.project.ProjectConfigurationManager.importProjects(ProjectConfigurationManager.java:136)
>         at org.eclipse.m2e.tests.common.AbstractMavenProjectTestCase$4.run(AbstractMavenProjectTestCase.java:371)
>         at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2241)
>         at org.eclipse.m2e.tests.common.AbstractMavenProjectTestCase.importProjects(AbstractMavenProjectTestCase.java:369)
>         at org.eclipse.m2e.tests.common.AbstractMavenProjectTestCase.importProjects(AbstractMavenProjectTestCase.java:344)
>         at org.eclipse.m2e.tests.common.AbstractMavenProjectTestCase.importProject(AbstractMavenProjectTestCase.java:331)
>         at org.switchyard.tools.m2e.tests.SwitchYardConfigurationTest.runProjectTest(SwitchYardConfigurationTest.java:59)
>         at org.switchyard.tools.m2e.tests.SwitchYardConfigurationTest.testBeanServiceQuickstart(SwitchYardConfigurationTest.java:42)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>         at java.lang.reflect.Method.invoke(Method.java:497)
>         at junit.framework.TestCase.runTest(TestCase.java:176)
>         at org.eclipse.m2e.tests.common.AbstractMavenProjectTestCase.runTest(AbstractMavenProjectTestCase.java:576)
>         at junit.framework.TestCase.runBare(TestCase.java:141)
>         at junit.framework.TestResult$1.protect(TestResult.java:122)
>         at junit.framework.TestResult.runProtected(TestResult.java:142)
>         at junit.framework.TestResult.run(TestResult.java:125)
>         at junit.framework.TestCase.run(TestCase.java:129)
>         at junit.framework.TestSuite.runTest(TestSuite.java:252)
>         at junit.framework.TestSuite.run(TestSuite.java:247)
>         at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:86)
>         at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:264)
>         at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:153)
>         at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:124)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>         at java.lang.reflect.Method.invoke(Method.java:497)
>         at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray2(ReflectionUtils.java:208)
>         at org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:156)
>         at org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:82)
>         at org.eclipse.tycho.surefire.osgibooter.OsgiSurefireBooter.run(OsgiSurefireBooter.java:91)
>         at org.eclipse.tycho.surefire.osgibooter.AbstractUITestApplication$1.run(AbstractUITestApplication.java:35)
>         at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
>         at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:135)
>         at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:4155)
>         at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3772)
>         at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$4.run(PartRenderingEngine.java:1127)
>         at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:337)
>         at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1018)
>         at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:156)
>         at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:654)
>         at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:337)
>         at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:598)
>         at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:150)
>         at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:139)
>         at org.eclipse.tycho.surefire.osgibooter.UITestApplication.runApplication(UITestApplication.java:31)
>         at org.eclipse.tycho.surefire.osgibooter.AbstractUITestApplication.run(AbstractUITestApplication.java:120)
>         at org.eclipse.tycho.surefire.osgibooter.UITestApplication.start(UITestApplication.java:37)
>         at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
>         at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
>         at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
>         at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:380)
>         at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:235)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>         at java.lang.reflect.Method.invoke(Method.java:497)
>         at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:669)
>         at org.eclipse.equinox.launcher.Main.basicRun(Main.java:608)
>         at org.eclipse.equinox.launcher.Main.run(Main.java:1515)
>         at org.eclipse.equinox.launcher.Main.main(Main.java:1488)
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.11#64026)


More information about the jbosstools-issues mailing list