Sametime 中的插件与 Lotus Notes Classess - 整个故事

发布于 2024-08-06 03:32:36 字数 9870 浏览 10 评论 0原文

这将是一个很长的阅读,所以感谢您的耐心:)。

我一直在尝试开发一个在 Lotus Sametime 内执行的插件。这个插件的想法是提取给定日期的日历条目,然后同时显示它。是不是很简单,我也是这么想的。显然我错了,严重误解了 JVM 版本兼容性问题。我首先在默认的 Java 1.6 中进行了独立测试,效果很好,我获得了条目并准备好代码以转移到 Sametime 开发环境。

我转移到插件开发环境来插入我的代码。当我将 Notes.jar 添加到外部 jar 列表和 import Lotus.domino 行时,我的第一个问题出现了。 IDE 告诉我这一点

The type org.omg.CORBA.UserException cannot be resolved. It is indirectly referenced from required .class files

经过一番谷歌搜索后,我在项目中引用了 ibmorbapi.jar 并让它运行。不幸的是,对我来说,即使这样也没有成功。插件本身无法加载,这就是我得到的,

    java.lang.NoClassDefFoundError: lotus.notes.Session
 at java.lang.J9VMInternals.verifyImpl(Native Method)
 at java.lang.J9VMInternals.verify(J9VMInternals.java:59)
 at java.lang.J9VMInternals.initialize(J9VMInternals.java:120)
 at java.lang.Class.newInstanceImpl(Native Method)
 at java.lang.Class.newInstance(Class.java:1244)
 at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:157)
 at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:759)
 at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
 at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:51)
 at com.ibm.collaboration.realtime.imhub.ImHub.loadMiniAppExtensions(ImHub.java:416)
 at com.ibm.collaboration.realtime.imhub.ImHub.getMiniApps(ImHub.java:356)
 at com.ibm.collaboration.realtime.imhub.workbench.ImHubWorkbenchWindowAdvisorShelf.transformMiniApps(ImHubWorkbenchWindowAdvisorShelf.java:354)
 at com.ibm.collaboration.realtime.imhub.workbench.ImHubWorkbenchWindowAdvisorShelf.createWindowContents(ImHubWorkbenchWindowAdvisorShelf.java:179)
 at org.eclipse.ui.internal.WorkbenchWindow.createContents(WorkbenchWindow.java:938)
 at org.eclipse.jface.window.Window.create(Window.java:426)
 at org.eclipse.ui.internal.Workbench.busyOpenWorkbenchWindow(Workbench.java:805)
 at org.eclipse.ui.internal.Workbench.doOpenFirstTimeWindow(Workbench.java:1453)
 at org.eclipse.ui.internal.Workbench.openFirstTimeWindow(Workbench.java:1404)
 at org.eclipse.ui.internal.WorkbenchConfigurer.openFirstTimeWindow(WorkbenchConfigurer.java:190)
 at org.eclipse.ui.application.WorkbenchAdvisor.openWindows(WorkbenchAdvisor.java:708)
 at org.eclipse.ui.internal.Workbench.init(Workbench.java:1101)
 at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1863)
 at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:422)
 at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
 at com.ibm.collaboration.realtime.ui.WorkbenchAdapter.createAndRunWorkbench(WorkbenchAdapter.java:103)
 at com.ibm.collaboration.realtime.ui.WorkbenchAdapter.run(WorkbenchAdapter.java:85)
 at com.ibm.collaboration.realtime.application.RTCApplication.run(RTCApplication.java:765)
 at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:78)
 at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:92)
 at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:68)
 at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:400)
 at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:177)
 at java.lang.reflect.AccessibleObject.invokeL(AccessibleObject.java:211)
 at java.lang.reflect.Method.invoke(Method.java:272)
 at org.eclipse.core.launcher.Main.invokeFramework(Main.java:336)
 at org.eclipse.core.launcher.Main.basicRun(Main.java:280)
 at org.eclipse.core.launcher.Main.run(Main.java:977)
 at org.eclipse.core.launcher.Main.main(Main.java:952)

因为那是行不通的。我想为什么不将 NotesCalendarExtraction 部分创建到单独的 jar 执行文件中,并获取其中包含日历条目的 xml 文件,然后将其交给插件以显示条目。我知道这不是最好的解决方案,但我很绝望,想让它发挥作用。无论如何,当我对 jar 文件和生成的 xml 文件的路径进行硬编码时,这个想法效果很好。顺便说一句,我正在使用 java 中的 getRuntime.exec 模块执行 jar 文件。是时候让它普遍运行了,不幸的是,对我来说,exec 模块不接受其路径中的空格,因此程序文件是不可能的。我不确定这是否是正确的方法,但由于某种原因,jar 本身也没有执行。我尝试放入一个带有适当命令行参数的bat文件,它在命令行中执行时生成xml,但在从eclipse ide运行时则不生成xml,原因只有IDE知道。此时我别无选择,我得到了另一个插件,它在获取日历条目方面做了完全相同的事情。我反编译了插件并检查了源代码,发现代码使用类加载器来完成这项工作。当我看到这段代码时,我燃起了新的希望。经过一番谷歌搜索后,我整理了一些代码,这些代码为我完成了这项工作。酸测试的时间到了,我将代码放入插件环境中,这就是我得到的。

    !ENTRY org.eclipse.ui 4 0 2009-09-27 22:05:55.996
!MESSAGE (org/omg/CORBA/UserException) bad major version at offset=6
!STACK 0
java.lang.UnsupportedClassVersionError: (org/omg/CORBA/UserException) bad major version at offset=6
 at java.lang.ClassLoader.defineClassImpl(Native Method)
 at java.lang.ClassLoader.defineClass(ClassLoader.java:246)
 at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:109)
 at java.net.URLClassLoader.findClassImpl(URLClassLoader.java:1028)
 at java.net.URLClassLoader$4.run(URLClassLoader.java:549)
 at java.security.AccessController.doPrivileged(AccessController.java:213)
 at java.net.URLClassLoader.findClass(URLClassLoader.java:547)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:625)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:582)
 at java.lang.ClassLoader.defineClassImpl(Native Method)
 at java.lang.ClassLoader.defineClass(ClassLoader.java:246)
 at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:109)
 at java.net.URLClassLoader.findClassImpl(URLClassLoader.java:1028)
 at java.net.URLClassLoader$4.run(URLClassLoader.java:549)
 at java.security.AccessController.doPrivileged(AccessController.java:213)
 at java.net.URLClassLoader.findClass(URLClassLoader.java:547)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:625)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:582)
 at java.lang.J9VMInternals.verifyImpl(Native Method)
 at java.lang.J9VMInternals.verify(J9VMInternals.java:59)
 at java.lang.J9VMInternals.initialize(J9VMInternals.java:120)
 at java.lang.reflect.AccessibleObject.initializeClass(Native Method)
 at java.lang.reflect.Method.invoke(Method.java:248)
 at com.ibm.collaboration.realtime.lotusnotes.LotusNotes.getNotesSession(LotusNotes.java:179)
 at com.ibm.notes.sametime.calendar.hack.SpeakUpMiniApp.createControl(SpeakUpMiniApp.java:58)
 at com.ibm.collaboration.realtime.miniapp.MiniAppViewPart.createPartControl(MiniAppViewPart.java:41)
 at com.ibm.rcp.ui.internal.shelf.ShelfViewReference.createPartHelper(ShelfViewReference.java:330)
 at com.ibm.rcp.ui.internal.shelf.ShelfViewReference.createPart(ShelfViewReference.java:201)
 at org.eclipse.ui.internal.WorkbenchPartReference.getPart(WorkbenchPartReference.java:566)
 at com.ibm.rcp.ui.shelf.ShelfPage.activatePart(ShelfPage.java:1168)
 at com.ibm.rcp.ui.shelf.ShelfPage.access$10(ShelfPage.java:1159)
 at com.ibm.rcp.ui.shelf.ShelfPage$7.handleEvent(ShelfPage.java:1312)
 at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
 at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:938)
 at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:962)
 at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:947)
 at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:706)
 at com.ibm.rcp.swt.swidgets.SViewForm.toggleMaximize(SViewForm.java:1501)
 at com.ibm.rcp.swt.swidgets.SViewStack.expand(SViewStack.java:596)
 at com.ibm.rcp.swt.swidgets.SViewStack.toggleMaximize(SViewStack.java:526)
 at com.ibm.rcp.swt.swidgets.SViewStack$5.handleEvent(SViewStack.java:312)
 at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
 at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:938)
 at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:962)
 at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:947)
 at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:706)
 at com.ibm.rcp.swt.swidgets.SViewForm.onMouseUpMaximize(SViewForm.java:1437)
 at com.ibm.rcp.swt.swidgets.SViewForm.onMouseUp(SViewForm.java:1127)
 at com.ibm.rcp.swt.swidgets.SViewForm$4.handleEvent(SViewForm.java:421)
 at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
 at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:938)
 at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3673)
 at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3284)
 at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1930)
 at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1894)
 at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:422)
 at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
 at com.ibm.collaboration.realtime.ui.WorkbenchAdapter.createAndRunWorkbench(WorkbenchAdapter.java:103)
 at com.ibm.collaboration.realtime.ui.WorkbenchAdapter.run(WorkbenchAdapter.java:85)
 at com.ibm.collaboration.realtime.application.RTCApplication.run(RTCApplication.java:765)
 at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:78)
 at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:92)
 at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:68)
 at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:400)
 at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:177)
 at java.lang.reflect.AccessibleObject.invokeL(AccessibleObject.java:211)
 at java.lang.reflect.Method.invoke(Method.java:272)
 at org.eclipse.core.launcher.Main.invokeFramework(Main.java:336)
 at org.eclipse.core.launcher.Main.basicRun(Main.java:280)
 at org.eclipse.core.launcher.Main.run(Main.java:977)
 at org.eclipse.core.launcher.Main.main(Main.java:952)

再次遇到版本错误真是令人沮丧。 Sametime 插件开发环境在 J9 JVM 上运行,由于某种原因,我猜这对于notes.jar ibmorbapi.jar 来说是不够的。至少这就是我对错误的假设。

我将不胜感激你们对此的任何帮助。 “org/omg/CORBA/UserException”似乎是问题的症结所在,我根本无法克服它。我可以让外部 jar 执行以某种复杂的方式工作,但我不想这样做,因为我觉得这是从笔记中获取日历条目的最佳方式。我确信它必须相当简单,任何对此的帮助将不胜感激。

It's gonna be a long read so Thanks for being patient :).

I have been trying to develop a plugin to be executed inside Lotus Sametime. The idea of this plugin is to extract the calendar entries for a given date and then display it in sametime. Simple isn't it, i thought so too. Apparently I was wrong and grossly misunderstood the JVM version compatibility issues. I first did an independent test in the default Java 1.6 and it worked fine, I got the entries and got the code ready to move to the Sametime Development environment.

I moved to the plugin development environment to insert my code.My first issue came, when I added the Notes.jar to the External jar list and the import lotus.domino line. The IDE told me this

The type org.omg.CORBA.UserException cannot be resolved. It is indirectly referenced from required .class files

After some googling , i referenced the ibmorbapi.jar in the project and got it running. Unfortunately for me even that didn't work out. The plugin itself failed to load and this is what i got

    java.lang.NoClassDefFoundError: lotus.notes.Session
 at java.lang.J9VMInternals.verifyImpl(Native Method)
 at java.lang.J9VMInternals.verify(J9VMInternals.java:59)
 at java.lang.J9VMInternals.initialize(J9VMInternals.java:120)
 at java.lang.Class.newInstanceImpl(Native Method)
 at java.lang.Class.newInstance(Class.java:1244)
 at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:157)
 at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:759)
 at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
 at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:51)
 at com.ibm.collaboration.realtime.imhub.ImHub.loadMiniAppExtensions(ImHub.java:416)
 at com.ibm.collaboration.realtime.imhub.ImHub.getMiniApps(ImHub.java:356)
 at com.ibm.collaboration.realtime.imhub.workbench.ImHubWorkbenchWindowAdvisorShelf.transformMiniApps(ImHubWorkbenchWindowAdvisorShelf.java:354)
 at com.ibm.collaboration.realtime.imhub.workbench.ImHubWorkbenchWindowAdvisorShelf.createWindowContents(ImHubWorkbenchWindowAdvisorShelf.java:179)
 at org.eclipse.ui.internal.WorkbenchWindow.createContents(WorkbenchWindow.java:938)
 at org.eclipse.jface.window.Window.create(Window.java:426)
 at org.eclipse.ui.internal.Workbench.busyOpenWorkbenchWindow(Workbench.java:805)
 at org.eclipse.ui.internal.Workbench.doOpenFirstTimeWindow(Workbench.java:1453)
 at org.eclipse.ui.internal.Workbench.openFirstTimeWindow(Workbench.java:1404)
 at org.eclipse.ui.internal.WorkbenchConfigurer.openFirstTimeWindow(WorkbenchConfigurer.java:190)
 at org.eclipse.ui.application.WorkbenchAdvisor.openWindows(WorkbenchAdvisor.java:708)
 at org.eclipse.ui.internal.Workbench.init(Workbench.java:1101)
 at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1863)
 at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:422)
 at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
 at com.ibm.collaboration.realtime.ui.WorkbenchAdapter.createAndRunWorkbench(WorkbenchAdapter.java:103)
 at com.ibm.collaboration.realtime.ui.WorkbenchAdapter.run(WorkbenchAdapter.java:85)
 at com.ibm.collaboration.realtime.application.RTCApplication.run(RTCApplication.java:765)
 at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:78)
 at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:92)
 at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:68)
 at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:400)
 at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:177)
 at java.lang.reflect.AccessibleObject.invokeL(AccessibleObject.java:211)
 at java.lang.reflect.Method.invoke(Method.java:272)
 at org.eclipse.core.launcher.Main.invokeFramework(Main.java:336)
 at org.eclipse.core.launcher.Main.basicRun(Main.java:280)
 at org.eclipse.core.launcher.Main.run(Main.java:977)
 at org.eclipse.core.launcher.Main.main(Main.java:952)

Since that was not gonna work. I thought why not create the NotesCalendarExtraction part into a separate jar execution file and get a xml file with the calendar entries in it and then give it to the plugin to show the entries. I know it was not the best solution but i was desperate and wanted to get this working. In anycase, the idea kinda worked well when I had hardcoded the jar file and and the path to the generated xml file. Btw I was executing the jar file using the getRuntime.exec module in java. Time came to get it running generically and unfortunately for me the exec module was not accepting spaces in its path so program files was out of question. I was not sure if this was right method but then the jar as such was not executing either for some reason. I tried putting in a bat file with the appropriate command line parameters and it generated the xml when executed in the command line but not when running from the eclipse ide for reasons known only to the IDE. I was out of options at this point and I got my hands on another plugin which did exactly the same thing with regard to getting the calendar entries. I decompiled plugin and checked out the source code and saw the code was using a class loader to do the job. A new hope got into me when i saw this code. After some googling i put together some code which did the job for me. Time came for the acid test, i put the code into the plugin env and this is what I got.

    !ENTRY org.eclipse.ui 4 0 2009-09-27 22:05:55.996
!MESSAGE (org/omg/CORBA/UserException) bad major version at offset=6
!STACK 0
java.lang.UnsupportedClassVersionError: (org/omg/CORBA/UserException) bad major version at offset=6
 at java.lang.ClassLoader.defineClassImpl(Native Method)
 at java.lang.ClassLoader.defineClass(ClassLoader.java:246)
 at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:109)
 at java.net.URLClassLoader.findClassImpl(URLClassLoader.java:1028)
 at java.net.URLClassLoader$4.run(URLClassLoader.java:549)
 at java.security.AccessController.doPrivileged(AccessController.java:213)
 at java.net.URLClassLoader.findClass(URLClassLoader.java:547)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:625)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:582)
 at java.lang.ClassLoader.defineClassImpl(Native Method)
 at java.lang.ClassLoader.defineClass(ClassLoader.java:246)
 at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:109)
 at java.net.URLClassLoader.findClassImpl(URLClassLoader.java:1028)
 at java.net.URLClassLoader$4.run(URLClassLoader.java:549)
 at java.security.AccessController.doPrivileged(AccessController.java:213)
 at java.net.URLClassLoader.findClass(URLClassLoader.java:547)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:625)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:582)
 at java.lang.J9VMInternals.verifyImpl(Native Method)
 at java.lang.J9VMInternals.verify(J9VMInternals.java:59)
 at java.lang.J9VMInternals.initialize(J9VMInternals.java:120)
 at java.lang.reflect.AccessibleObject.initializeClass(Native Method)
 at java.lang.reflect.Method.invoke(Method.java:248)
 at com.ibm.collaboration.realtime.lotusnotes.LotusNotes.getNotesSession(LotusNotes.java:179)
 at com.ibm.notes.sametime.calendar.hack.SpeakUpMiniApp.createControl(SpeakUpMiniApp.java:58)
 at com.ibm.collaboration.realtime.miniapp.MiniAppViewPart.createPartControl(MiniAppViewPart.java:41)
 at com.ibm.rcp.ui.internal.shelf.ShelfViewReference.createPartHelper(ShelfViewReference.java:330)
 at com.ibm.rcp.ui.internal.shelf.ShelfViewReference.createPart(ShelfViewReference.java:201)
 at org.eclipse.ui.internal.WorkbenchPartReference.getPart(WorkbenchPartReference.java:566)
 at com.ibm.rcp.ui.shelf.ShelfPage.activatePart(ShelfPage.java:1168)
 at com.ibm.rcp.ui.shelf.ShelfPage.access$10(ShelfPage.java:1159)
 at com.ibm.rcp.ui.shelf.ShelfPage$7.handleEvent(ShelfPage.java:1312)
 at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
 at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:938)
 at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:962)
 at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:947)
 at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:706)
 at com.ibm.rcp.swt.swidgets.SViewForm.toggleMaximize(SViewForm.java:1501)
 at com.ibm.rcp.swt.swidgets.SViewStack.expand(SViewStack.java:596)
 at com.ibm.rcp.swt.swidgets.SViewStack.toggleMaximize(SViewStack.java:526)
 at com.ibm.rcp.swt.swidgets.SViewStack$5.handleEvent(SViewStack.java:312)
 at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
 at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:938)
 at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:962)
 at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:947)
 at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:706)
 at com.ibm.rcp.swt.swidgets.SViewForm.onMouseUpMaximize(SViewForm.java:1437)
 at com.ibm.rcp.swt.swidgets.SViewForm.onMouseUp(SViewForm.java:1127)
 at com.ibm.rcp.swt.swidgets.SViewForm$4.handleEvent(SViewForm.java:421)
 at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
 at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:938)
 at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3673)
 at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3284)
 at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1930)
 at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1894)
 at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:422)
 at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
 at com.ibm.collaboration.realtime.ui.WorkbenchAdapter.createAndRunWorkbench(WorkbenchAdapter.java:103)
 at com.ibm.collaboration.realtime.ui.WorkbenchAdapter.run(WorkbenchAdapter.java:85)
 at com.ibm.collaboration.realtime.application.RTCApplication.run(RTCApplication.java:765)
 at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:78)
 at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:92)
 at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:68)
 at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:400)
 at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:177)
 at java.lang.reflect.AccessibleObject.invokeL(AccessibleObject.java:211)
 at java.lang.reflect.Method.invoke(Method.java:272)
 at org.eclipse.core.launcher.Main.invokeFramework(Main.java:336)
 at org.eclipse.core.launcher.Main.basicRun(Main.java:280)
 at org.eclipse.core.launcher.Main.run(Main.java:977)
 at org.eclipse.core.launcher.Main.main(Main.java:952)

It's really frustrating again to the version error. The sametime plugin dev environment runs on J9 JVM and the for some reason that is not enough for notes.jar ibmorbapi.jar i guess. Atleast that is what my assumption is about the error.

I would appreciate any help on this from you guys. "org/omg/CORBA/UserException" seems to be crux of the issue and I am simply not able to get over it. I can get the external jar execution working in some complex way but I don't want to do it as i feel its the best way to get calendar entries from notes. I am sure it has to be reasonably simple and any help on this would be appreciated.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

秋凉 2024-08-13 03:32:36

有两个与 Notes 应用程序对话相关的 jar。

Notes.jar - 这是 LSXBE 类的 JNI 包装器。为了使其正常工作,您需要在计算机上安装 Lotus Notes 以及系统 PATH 上的主目录。

NCSO.jar - 用于与 Domino 服务器建立 DIIOP 连接。这不需要安装 Lotus Notes。它确实需要您可以连接到启用了 DIIOP 的 Domino 服务器。

不清楚你是否安装了Notes?

这些 jar 还特定于某些 JVM 版本。

  • Java 6 - Notes 8.5.1
  • Java 5 - Notes 8.x
  • Java 1.4.2 - Notes 7.x
  • Java 1.3 - Notes 6.x

“偏移处的主要版本错误”意味着您正在为 JVM 运行错误的 jar(例如1.4.2 上的 851 罐子)。

为了首先排除任何配置问题,我建议仅创建一个简单的 java 应用程序来连接到 Notes/Domino。一旦成功,您就知道您的路径/jar 都已正确设置。

There are two jars that are related to talking to a Notes application.

Notes.jar - This is a JNI wrapper for LSXBE classes. In order for it to work correctly you will need Lotus Notes installed on the machine and the main directory on the system PATH.

NCSO.jar - This is for making DIIOP connections to a Domino server. This does not require Lotus Notes to be installed. It does require a Domino server you can connect to which has DIIOP enabled on it.

It is unclear if you have Notes installed?

The jars are also specific to certain JVM versions.

  • Java 6 - Notes 8.5.1
  • Java 5 - Notes 8.x
  • Java 1.4.2 - Notes 7.x
  • Java 1.3 - Notes 6.x

"bad major version at offset" means your are running the wrong jar for the JVM (eg. 851 jar on 1.4.2).

To rule out any configuration issues first I recommend creating just a simple java application which makes a connection to Notes/Domino. Once that works then you know your paths/jars are all set up correctly.

泪之魂 2024-08-13 03:32:36

看起来 CORBA 类是为较新的 JDK 编译的。您需要找到旧版本的 JAR,或者获取源代码并在您的 JDK(J9?)下编译它们。根据我在 Google 上的简短搜索,J9 要么兼容 1.4,要么甚至兼容 1.3。

另外,请确保您自己编译的所有代码都具有相同的目标 Java 版本,即本例中的 1.4(1.3?)。

Looks like CORBA classes are compiled for a newer JDK. You need to find an older version of the JAR, or, alternatively, get the sources and compile them under your JDK (J9?). From what I see from a brief Google search, J9 is either 1.4 or even 1.3 compatible.

Also, make sure that all the code you compile yourself has the same target Java version, i.e. 1.4 (1.3?) in this case.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文