|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Is there an operation name bug or am I missing something |
« View previous topic :: View next topic » |
Author |
Message
|
jcv |
Posted: Wed Nov 08, 2017 9:08 am Post subject: Is there an operation name bug or am I missing something |
|
|
 Chevalier
Joined: 07 May 2007 Posts: 411 Location: Zagreb
|
After importing yaml, and setting operation names to REST API Description, the toolkit doesn't save properly all operation names, and it takes some persuasion until it finally accepts all of them. In the mean time, there is an error reported that states: "There is more than one operation in the API api_name without a name." Is it a swagger problem or toolkit problem or something else? |
|
Back to top |
|
 |
martinb |
Posted: Wed Nov 08, 2017 10:01 am Post subject: |
|
|
Master
Joined: 09 Nov 2006 Posts: 210 Location: UK
|
Hi
I've not seen any issues like this.
To clarify are you adding additional operations to the original imported Swagger, or are you renaming operations?
Have you checked in the Eclipse Error log view/file for any problem event when you encounter the issue? |
|
Back to top |
|
 |
jcv |
Posted: Wed Nov 08, 2017 8:19 pm Post subject: |
|
|
 Chevalier
Joined: 07 May 2007 Posts: 411 Location: Zagreb
|
Hi,
I am naming original operations generated by the import, not adding new ones, because they are not automatically named, for whatever reason might that be, probably that is another problem with that specific yaml that I am importing. Unfortunately it didn't occur to me to look there yet, so let me check it and get back to you, and thanks. |
|
Back to top |
|
 |
jcv |
Posted: Thu Nov 09, 2017 1:16 am Post subject: |
|
|
 Chevalier
Joined: 07 May 2007 Posts: 411 Location: Zagreb
|
I think the problem was with the name of the swagger document, which contained illegal character (blank). After I removed it, I managed to execute the import twice, without having problems afterwards with naming the operations. Yesterday, first errors that were logged, looked like this:
Code: |
eclipse.buildId=4.2.2.M20140918-1444
java.fullversion=JRE 1.7.0 IBM J9 2.7 Windows 7 amd64-64 Compressed References 20170406_343211 (JIT enabled, AOT enabled)
J9VM - R27_Java727_SR4_20170406_2107_B343211
JIT - tr.r13.java_20170406_343211
GC - R27_Java727_SR4_20170406_2107_B343211_CMPRSS
J9CL - 20170406_343211
BootLoader constants: OS=win32, ARCH=x86_64, WS=win32, NL=hr_HR
Framework arguments: -showlocation -product com.ibm.etools.msgbroker.tooling.ide tools_auto -showlocation -product com.ibm.etools.msgbroker.tooling.ide
Command-line arguments: -os win32 -ws win32 -arch x86_64 -showlocation -product com.ibm.etools.msgbroker.tooling.ide tools_auto -showlocation -product com.ibm.etools.msgbroker.tooling.ide
Error
Wed Nov 08 16:55:07 CET 2017
Problems occurred when invoking code from plug-in: "org.eclipse.e4.ui.workbench".
java.lang.IllegalArgumentException: Illegal character in path at index 34: http://localhost:7800/rec_poc/Docs V0.3.yaml
at java.net.URI.create(URI.java:871)
at com.ibm.broker.config.proxy.RestApiProxy.getLocalDefinitionsURL(RestApiProxy.java:459)
at com.ibm.etools.mft.broker.runtime.model.RestApiPropertySource.getPropertyValue(RestApiPropertySource.java:89)
at org.eclipse.ui.views.properties.PropertySheetEntry.refreshValues(PropertySheetEntry.java:611)
at org.eclipse.ui.views.properties.PropertySheetEntry.createChildEntries(PropertySheetEntry.java:248)
at org.eclipse.ui.views.properties.PropertySheetEntry.getChildEntries(PropertySheetEntry.java:341)
at org.eclipse.ui.views.properties.PropertySheetViewer.updateCategories(PropertySheetViewer.java:1086)
at org.eclipse.ui.views.properties.PropertySheetViewer.updateChildrenOf(PropertySheetViewer.java:1257)
at org.eclipse.ui.views.properties.PropertySheetViewer.setInput(PropertySheetViewer.java:975)
at org.eclipse.ui.views.properties.PropertySheetPage.selectionChanged(PropertySheetPage.java:510)
at org.eclipse.ui.views.properties.PropertySheet.selectionChanged(PropertySheet.java:365)
at org.eclipse.ui.internal.e4.compatibility.SelectionService.notifyPostSelectionListeners(SelectionService.java:173)
at org.eclipse.ui.internal.e4.compatibility.SelectionService.access$4(SelectionService.java:170)
at org.eclipse.ui.internal.e4.compatibility.SelectionService$2.selectionChanged(SelectionService.java:86)
at org.eclipse.e4.ui.internal.workbench.SelectionAggregator$4.run(SelectionAggregator.java:160)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.e4.ui.internal.workbench.SelectionAggregator.notifyPostListeners(SelectionAggregator.java:158)
at org.eclipse.e4.ui.internal.workbench.SelectionAggregator.access$8(SelectionAggregator.java:155)
at org.eclipse.e4.ui.internal.workbench.SelectionAggregator$8$1.run(SelectionAggregator.java:257)
at org.eclipse.e4.core.contexts.RunAndTrack.runExternalCode(RunAndTrack.java:53)
at org.eclipse.e4.ui.internal.workbench.SelectionAggregator$8.changed(SelectionAggregator.java:255)
at org.eclipse.e4.core.internal.contexts.TrackableComputationExt.update(TrackableComputationExt.java:110)
at org.eclipse.e4.core.internal.contexts.EclipseContext.processScheduled(EclipseContext.java:328)
at org.eclipse.e4.core.internal.contexts.EclipseContext.set(EclipseContext.java:342)
at org.eclipse.e4.ui.internal.workbench.SelectionServiceImpl.setPostSelection(SelectionServiceImpl.java:34)
at org.eclipse.ui.internal.e4.compatibility.CompatibilityPart$3.selectionChanged(CompatibilityPart.java:125)
at org.eclipse.jface.viewers.StructuredViewer$3.run(StructuredViewer.java:888)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:49)
at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:175)
at org.eclipse.jface.viewers.StructuredViewer.firePostSelectionChanged(StructuredViewer.java:886)
at org.eclipse.jface.viewers.StructuredViewer.handlePostSelect(StructuredViewer.java:1226)
at org.eclipse.jface.viewers.StructuredViewer$5.widgetSelected(StructuredViewer.java:1251)
at org.eclipse.jface.util.OpenStrategy.firePostSelectionEvent(OpenStrategy.java:262)
at org.eclipse.jface.util.OpenStrategy.access$5(OpenStrategy.java:256)
at org.eclipse.jface.util.OpenStrategy$3.run(OpenStrategy.java:433)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
at org.eclipse.swt.widgets.Synchronizer.contact admin(Synchronizer.java:135)
at org.eclipse.swt.widgets.Display.contact admin(Display.java:4145)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3762)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1054)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:943)
at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:88)
at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:589)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:543)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:124)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:353)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:180)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:95)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:56)
at java.lang.reflect.Method.invoke(Method.java:620)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:629)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:584)
at org.eclipse.equinox.launcher.Main.run(Main.java:1438)
at org.eclipse.equinox.launcher.Main.main(Main.java:1414)
Caused by: java.net.URISyntaxException: Illegal character in path at index 34: http://localhost:7800/rec_poc/Docs V0.3.yaml
at java.net.URI$Parser.fail(URI.java:2841)
at java.net.URI$Parser.checkChars(URI.java:3014)
at java.net.URI$Parser.parseHierarchical(URI.java:3098)
at java.net.URI$Parser.parse(URI.java:3046)
at java.net.URI.<init>(URI.java:607)
at java.net.URI.create(URI.java:869)
... 61 more
|
|
|
Back to top |
|
 |
jcv |
Posted: Thu Nov 09, 2017 3:43 am Post subject: |
|
|
 Chevalier
Joined: 07 May 2007 Posts: 411 Location: Zagreb
|
...although, subsequent errors look more relevant:
Code: |
eclipse.buildId=4.2.2.M20140918-1444
java.fullversion=JRE 1.7.0 IBM J9 2.7 Windows 7 amd64-64 Compressed References 20170406_343211 (JIT enabled, AOT enabled)
J9VM - R27_Java727_SR4_20170406_2107_B343211
JIT - tr.r13.java_20170406_343211
GC - R27_Java727_SR4_20170406_2107_B343211_CMPRSS
J9CL - 20170406_343211
BootLoader constants: OS=win32, ARCH=x86_64, WS=win32, NL=hr_HR
Framework arguments: -showlocation -product com.ibm.etools.msgbroker.tooling.ide tools_auto -showlocation -product com.ibm.etools.msgbroker.tooling.ide
Command-line arguments: -os win32 -ws win32 -arch x86_64 -showlocation -product com.ibm.etools.msgbroker.tooling.ide tools_auto -showlocation -product com.ibm.etools.msgbroker.tooling.ide
Error
Wed Nov 08 16:58:27 CET 2017
The Swagger document contains an existing definition for the operation 'get1'.
com.ibm.broker.rest.swagger_20.ExceptionImpl: The Swagger document contains an existing definition for the operation 'get1'.
at com.ibm.broker.rest.swagger_20.OperationImpl.setName(OperationImpl.java:346)
at com.ibm.etools.mft.restapi.ui.commands.ModifyOperationNameCommand.setName(ModifyOperationNameCommand.java:60)
at com.ibm.etools.mft.restapi.ui.commands.ModifyOperationNameCommand.execute(ModifyOperationNameCommand.java:34)
at org.eclipse.gef.commands.CommandStack.execute(CommandStack.java:199)
at com.ibm.etools.mft.restapi.ui.editors.RestApiEditor.execute(RestApiEditor.java:377)
at com.ibm.etools.mft.restapi.ui.editors.CompositionOperation$OperationNameHandler.handleModification(CompositionOperation.java:48)
at com.ibm.etools.mft.restapi.ui.editors.EditorWidgets$4.focusLost(EditorWidgets.java:272)
at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:143)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1053)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1077)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1058)
at org.eclipse.swt.widgets.Control.sendFocusEvent(Control.java:2822)
at org.eclipse.swt.widgets.Widget.wmKillFocus(Widget.java:1935)
at org.eclipse.swt.widgets.Control.WM_KILLFOCUS(Control.java:4900)
at org.eclipse.swt.widgets.Control.windowProc(Control.java:4562)
at org.eclipse.swt.widgets.Text.windowProc(Text.java:2587)
at org.eclipse.swt.widgets.Display.windowProc(Display.java:4990)
at org.eclipse.swt.internal.win32.OS.SetFocus(Native Method)
at org.eclipse.swt.widgets.Control.forceFocus(Control.java:1098)
at org.eclipse.swt.widgets.Control.setFocus(Control.java:3303)
at org.eclipse.swt.widgets.Composite.setFocus(Composite.java:1040)
at org.eclipse.swt.widgets.Composite.WM_LBUTTONDOWN(Composite.java:1351)
at org.eclipse.swt.widgets.Canvas.WM_LBUTTONDOWN(Canvas.java:444)
at org.eclipse.swt.widgets.Control.windowProc(Control.java:4564)
at org.eclipse.swt.widgets.Canvas.windowProc(Canvas.java:341)
at org.eclipse.swt.widgets.Display.windowProc(Display.java:4977)
at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method)
at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java:2547)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3757)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1054)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:943)
at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:88)
at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:589)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:543)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:124)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:353)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:180)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:95)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:56)
at java.lang.reflect.Method.invoke(Method.java:620)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:629)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:584)
at org.eclipse.equinox.launcher.Main.run(Main.java:1438)
at org.eclipse.equinox.launcher.Main.main(Main.java:1414)
|
I thought for a moment that due to some defect, there is a name conflict if there are multiple operations with the same name in different projects, but that is not the case. I can import the same swagger document in multiple projects and name operations identically, it doesn't matter. The reported conflict occured within the same project, when it reported that there are operations without a name, and I tried to enter the same name again to a field that appeared empty, and was marked by a red exclamation mark. Now when the yaml file name is OK, I can't reproduce the problem. |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|