- This topic has 35 replies, 9 voices, and was last updated 20 years, 7 months ago by
Riyad Kalla.
-
AuthorPosts
-
Riyad KallaMemberScott,
AFAIK this is the class loader (logger) problem with Struts. I’m seeing the same behavior with a fresh 3.0+3.8Beta 1 on Windows XP. I think we’ve talked/fixed/killed that bug to death by now I imagine though 🙂
kitmMemberI was getting the same error. (using 3.0+3.8b1) I followed Michael’s advice (I think):
@support-michael wrote:The short term workaround is:
1) create a parallel web project
2) add struts capabilities to it
3) copy over former struts project resourcesHowever, I didn’t want to overwrite my project’s configs so for 3) I copied only .mystrutsdata, the <nature>com.genuitec.eclipse.cross.easystruts.eclipse.easystrutsnature</nature> from .project, and *.tld and validator-rules.xml from WEB-INF from the new struts project into my own.
Now the error’s gone as is the option to add struts capabilities in the project’s MyEclipse context menu, but when I open struts-config.xml it doesn’t open in the struts editor, it opens in the generic xml editor and there’s no [source] or [flow view] tabs. What can I do to fully enable the struts features now?
Thanks!
Riyad KallaMemberit opens in the generic xml editor and there’s no [source] or [flow view] tabs. What can I do to fully enable the struts features now?
If you right click on the struts-config.xml file, is there a “Open With” option of “MyEclipse Struts Editor”?
kitmMemberThat did it! (I had to first close the existing xml-editor window displaying the file.) Will this editor now be the default for this file? (What controls the default editer setting on a per-file basis? Is it sticky to the last-used editor on that file? Will I need to explicitly select the struts editor for each struts file in other projects? Will it be different for converted projects vs new ones? )
Thanks again!
Riyad KallaMemberNo problem I’m glad it helped. usually the option is sticky, but you can set it via the Window > Preferences> Workbench> File Associations preference panel. Just associate the “struts-config.xml” with the “MyEclipse Struts Editor” and you’ll be all set.
kitmMemberOne more question: On the ME features page for the Struts Editor/Modeler (http://www.myeclipseide.com/ContentExpress-display-ceid-55.html) in the section entitled “Struts Flow View / Modeler” it shows two variants of the perspective. The lower one has the Flow View in the middle, the Outline on the right, and above the Outline there’s a small navigator pane entitled “Struts Flow Overview” that looks like it allows you to navigate the Flow diagram by sliding a view panel across a highly zoomed-out view of the diagram. I can’t for the life of me figure out how to open that navigator pane. I’ve tried right-clicking on every possible graphic/widget/component in the app. I’ve tried searching the help files. I’ve tried all the menus. I’ve tried opening/closing the Outline navigator. How do I get that “Overview” navigator to open? Is it actually in the 3.8b1 release?
Thanks.
support-michaelKeymasterThe view you are referring to is the Struts Modeler Overview. To open it goto Windows menu>Show View>Other>MyEclipse>Struts Flow Overview. This will open a pannable overview in the default location of your current perspective. You can relocate this view’s location by dragging the titlebar to a new location in your workbench.
big_bad_tonyMember@kitm wrote:
I was getting the same error. (using 3.0+3.8b1) I followed Michael’s advice (I think):
@support-michael wrote:The short term workaround is:
1) create a parallel web project
2) add struts capabilities to it
3) copy over former struts project resourcesHowever, I didn’t want to overwrite my project’s configs so for 3) I copied only .mystrutsdata, the <nature>com.genuitec.eclipse.cross.easystruts.eclipse.easystrutsnature</nature> from .project, and *.tld and validator-rules.xml from WEB-INF from the new struts project into my own.
Now the error’s gone as is the option to add struts capabilities in the project’s MyEclipse context menu, but when I open struts-config.xml it doesn’t open in the struts editor, it opens in the generic xml editor and there’s no [source] or [flow view] tabs. What can I do to fully enable the struts features now?
Thanks!
I just tried this workaround. While Struts capabilities have been added, I get “Unable to create part:” “An error occurred while activating this view” and “An error occurred when creating this editor”.
Heres a bit of the stack trace:
java.lang.NullPointerException
at com.genuitec.eclipse.struts.editor.model.ModelManager.getActionConfigs(Unknown Source)
at com.genuitec.eclipse.struts.editor.modeler.model.StrutsConfigDiagram.synchronizeDiagram(Unknown Source)
at com.genuitec.eclipse.struts.editor.modeler.model.StrutsConfigDiagram.<init>(Unknown Source)java.lang.NullPointerException
at org.eclipse.gef.ui.actions.ActionBarContributor.setActiveEditor(ActionBarContributor.java:133)
at com.genuitec.eclipse.struts.editor.multipage.MultiPageActionContributor.setActivePage(Unknown Source)java.lang.NullPointerException
at com.genuitec.eclipse.struts.editor.outline.StrutsConfigOutlinePage.redrawTree(Unknown Source)
at org.xmen.internal.ui.text.DampenedXMLStructureUpdaterPage$1.run(Unknown Source)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)Bring on Beta 2!
Tony
big_bad_tonyMemberHere’s something interesting. I opened the struts-config in the default text editor and removed my forms-beans and action mappings. Closed the text editor and reopened in the my eclipse editor and the error is gone. Go figure.
Riyad KallaMemberTony,
That is strange.Also, the error you gave above I was also seeing and sent it in last week.
benoitwMemberI’m afraid this bug is still there in beta 2.
Can post my metadata .log if necessary
benoit
Riyad KallaMemberbenoit,
Can you post the information we ask for in the posting guidelines at the top of this forum?
benoitwMemberThe error message is
“Invalid struts 1.1 config file found … ”My struts config is correct : it is located under /WEB-INF/config
My project has this structure :
/MyProject
—-/src
—-/webapp
——-/WEB-INF
———-/configoperating system and version -> windows 2000 sp3
Eclipse version and build id -> Version: 3.0.0 Build id: 200406251208
Was Eclipse freshly installed for MyEclipse -> yes
Are any other external plugins installed -> yes : lomboz, tomcat plugin
How many plugins in the <eclipse>/plugins directory are like org.eclipse.pde.* -> 8
MyEclipse version -> 3.8 beta 2
JDK version -> 1.4.2
What steps did you take that resulted in the issue -> i try to add struts capabilities to an existing project
Are there any errors in the Eclipse log? (<workspace>/.metadata/.log) -> yes see below!ENTRY org.eclipse.core.runtime 4 2 juil. 13, 2004 16:40:44.432
!MESSAGE Problems occurred when invoking code from plug-in: “org.eclipse.core.runtime”.
!STACK 0
java.lang.NullPointerException
at com.genuitec.eclipse.struts.editor.model.ModelManager.getGlobalForwardConfigs(Unknown Source)
at com.genuitec.eclipse.struts.editor.modeler.model.StrutsConfigDiagram.synchronizeDiagram(Unknown Source)
at com.genuitec.eclipse.struts.editor.modeler.model.StrutsConfigDiagram.<init>(Unknown Source)
at com.genuitec.eclipse.struts.editor.modeler.core.StrutsEditor.setInput(Unknown Source)
at org.eclipse.gef.ui.parts.GraphicalEditor.init(GraphicalEditor.java:271)
at org.eclipse.ui.part.MultiPageEditorPart.addPage(MultiPageEditorPart.java:117)
at com.genuitec.eclipse.struts.editor.multipage.StrutsConfigEditor.createFlowModeler(Unknown Source)
at com.genuitec.eclipse.struts.editor.multipage.StrutsConfigEditor.getAdapter(Unknown Source)
at org.eclipse.ui.views.contentoutline.ContentOutline.doCreatePage(ContentOutline.java:120)
at org.eclipse.ui.part.PageBookView.createPage(PageBookView.java:310)
at org.eclipse.ui.part.PageBookView.partActivated(PageBookView.java:591)
at org.eclipse.ui.internal.PartListenerList$1.run(PartListenerList.java:49)
at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:615)
at org.eclipse.core.runtime.Platform.run(Platform.java:747)
at org.eclipse.ui.internal.PartListenerList.firePartActivated(PartListenerList.java:47)
at org.eclipse.ui.internal.WorkbenchPage.firePartActivated(WorkbenchPage.java:1371)
at org.eclipse.ui.internal.WorkbenchPage.setActivePart(WorkbenchPage.java:2695)
at org.eclipse.ui.internal.WorkbenchPage.activate(WorkbenchPage.java:457)
at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditorBatched(WorkbenchPage.java:2215)
at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditor(WorkbenchPage.java:2134)
at org.eclipse.ui.internal.WorkbenchPage.access$6(WorkbenchPage.java:2126)
at org.eclipse.ui.internal.WorkbenchPage$9.run(WorkbenchPage.java:2113)
at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:69)
at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:2108)
at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:2091)
at org.eclipse.ui.actions.OpenWithMenu.openEditor(OpenWithMenu.java:258)
at org.eclipse.ui.actions.OpenWithMenu.access$0(OpenWithMenu.java:251)
at org.eclipse.ui.actions.OpenWithMenu$2.handleEvent(OpenWithMenu.java:166)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:82)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:796)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:2772)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2431)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1377)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1348)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:254)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:141)
at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:96)
at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:335)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:273)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:129)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.core.launcher.Main.basicRun(Main.java:183)
at org.eclipse.core.launcher.Main.run(Main.java:644)
at org.eclipse.core.launcher.Main.main(Main.java:628)!ENTRY org.eclipse.core.runtime 4 2 juil. 13, 2004 16:40:45.448
!MESSAGE Problems occurred when invoking code from plug-in: “org.eclipse.core.runtime”.
!STACK 0
java.lang.NullPointerException
at com.genuitec.eclipse.struts.editor.modeler.core.StrutsEditor.getAdapter(Unknown Source)
at com.genuitec.eclipse.struts.editor.multipage.StrutsConfigEditor.getAdapter(Unknown Source)
at org.eclipse.gef.ui.actions.ZoomComboContributionItem$1.partActivated(ZoomComboContributionItem.java:74)
at org.eclipse.ui.internal.PartListenerList$1.run(PartListenerList.java:49)
at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:615)
at org.eclipse.core.runtime.Platform.run(Platform.java:747)
at org.eclipse.ui.internal.PartListenerList.firePartActivated(PartListenerList.java:47)
at org.eclipse.ui.internal.WorkbenchPage.firePartActivated(WorkbenchPage.java:1371)
at org.eclipse.ui.internal.WorkbenchPage.setActivePart(WorkbenchPage.java:2695)
at org.eclipse.ui.internal.WorkbenchPage.activate(WorkbenchPage.java:457)
at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditorBatched(WorkbenchPage.java:2215)
at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditor(WorkbenchPage.java:2134)
at org.eclipse.ui.internal.WorkbenchPage.access$6(WorkbenchPage.java:2126)
at org.eclipse.ui.internal.WorkbenchPage$9.run(WorkbenchPage.java:2113)
at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:69)
at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:2108)
at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:2091)
at org.eclipse.ui.actions.OpenWithMenu.openEditor(OpenWithMenu.java:258)
at org.eclipse.ui.actions.OpenWithMenu.access$0(OpenWithMenu.java:251)
at org.eclipse.ui.actions.OpenWithMenu$2.handleEvent(OpenWithMenu.java:166)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:82)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:796)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:2772)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2431)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1377)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1348)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:254)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:141)
at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:96)
at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:335)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:273)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:129)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.core.launcher.Main.basicRun(Main.java:183)
at org.eclipse.core.launcher.Main.run(Main.java:644)
at org.eclipse.core.launcher.Main.main(Main.java:628)
Riyad KallaMemberI am not able to reproduce this problem… can you open your struts-config.xml file in our XML editor, and right click and select Validate…. is it valid?
I tried even cutting down my struts-config.xml file to noghitn before adding Struts Caps… and it still worked (I saw in your 1st exception something about global forwatrds, so I tried removing that from my struts-config before doing it to see if I could cause the exception)…
Can you come up with a reproducable set of steps that we can do over here that will cause this problem?
nikbatsMemberHi all,
We are having the same problem as *benoitw*. We recently installed eclipse 3.0 and 3.8 beta 2 version of myEclipse and the error is caused by *global forwards*. This happens also in older struts projects (with the existing global forward tags) and in new projects when adding a new global forward rag.
Any help would be appreciated.
NB -
AuthorPosts