| Summary: | Provide Virgo support | ||
|---|---|---|---|
| Product: | [RT] RAP | Reporter: | Holger Staudacher <holger.staudacher> |
| Component: | Demo | Assignee: | Project Inbox <rap-inbox> |
| Status: | CLOSED FIXED | QA Contact: | |
| Severity: | enhancement | ||
| Priority: | P3 | CC: | aol-nnov, eclipse, fwaibel, glyn.normington, jingweno, rino, zteve.powell |
| Version: | 1.4 | ||
| Target Milestone: | 1.4 M3 | ||
| Hardware: | All | ||
| OS: | All | ||
| Whiteboard: | plan-theme=other-projects plan-status=committed plan-version=1.4 | ||
| Bug Depends on: | 318863 | ||
| Bug Blocks: | |||
| Attachments: | |||
|
Description
Holger Staudacher
Created attachment 181921 [details]
Virgo Plan containing equionx/eclipse bundles needed for RAP applications
Created attachment 181922 [details]
Virgo Plan containing RAP bundles needed for RAP applications
Created attachment 181924 [details]
Virgo Plan containing the RAP demo application
Drop this plan into the Virgo pickup folder to install the RAP demo application. Tested with Virgo Kernel 2.1.0.RC1-incubation - and RAP runtime 1.3.1.
TODO - automatically start the HttpService: @see http://dev.eclipse.org/mhonarc/lists/virgo-dev/msg00336.html Hey Florian, thanks for your solution. I tink we should create a wiki page at wiki.eclipse.org/RAP before we can close the bug. Would you agree to do this? Thanks in advance. Regards Holger Thanks for creating the wiki page. You will find the page here: http://wiki.eclipse.org/RAP/Running_RAP_on_virgo I will close the bug as fixed. Hi! just tried to deploy RAP 1.4 demo using plans attached, but failed. i was using virgo kernel 2.1.1 and 3.0.M6 - both failed. Hi Andrey, I guess you tried to deploy the RAP 1.4 runtime. This runtime depends on Equinox 3.7. Virgo is build on top of Equinox 3.6 and as such does not provide all required dependencies to resolve the RAP 1.4 runtime successfully. Please use the Equinox bundles from RAP 1.3 runtime and the RAP bundles from RAP 1.4 runtime. I tried this on the current Virgo 2.1.1.RELEASE. Part of the installed RAP 1.3.2 runtime: osgi> ss equinox Framework is launched. id State Bundle 10 ACTIVE org.eclipse.equinox.common_3.6.0.v20100503 62 ACTIVE org.eclipse.equinox.preferences_3.3.0.v20100503 63 ACTIVE org.eclipse.equinox.app_1.3.1.R36x_v20100803 73 ACTIVE org.eclipse.equinox.registry_3.5.0.v20100503 74 ACTIVE org.eclipse.equinox.http.registry_1.1.1.R36x_v20101103 75 ACTIVE org.eclipse.equinox.http.servlet_1.1.0.v20100503 76 ACTIVE org.eclipse.equinox.http.jetty_2.0.0.v20100503 The RAP 1.4 bundles: osgi> ss rap Framework is launched. id State Bundle 60 RESOLVED org.eclipse.rap.jface.databinding_1.4.0.20110614-2335 77 ACTIVE org.eclipse.rap.rwt_1.4.0.20110614-2335 Fragments=78 78 RESOLVED org.eclipse.rap.rwt.q07_1.4.0.20110614-2335 Master=77 79 ACTIVE org.eclipse.rap.jface_1.4.0.20110614-2335 80 ACTIVE org.eclipse.rap.ui.workbench_1.4.0.20110614-2335 81 ACTIVE org.eclipse.rap.ui_1.4.0.20110614-2335 82 <<LAZY>> org.eclipse.rap.ui.views_1.4.0.20110614-2335 83 ACTIVE org.eclipse.rap.demo_1.4.0.20110614-2335 (In reply to comment #8) Good day, Florian! thank you for a quick reply! yes, it was exactly that way. i used 1.4 runtime. but as far as i can see, virgo 3.0.M6 uses Equinox 3.7 too! Am i wrong? The question, actually, was why doesn't RAP 1.4 run on Virgo 3.0.M6, as i managed to run RAP 1.3 on Virgo 2.1.1 flawlessly. Hi Andrey,
with two small changes to the plan to match the newer versions/changes in Virgo Kernel:
1. comment out org.eclipse.osgi.services - now present in Virgo Kernel.
<!--
<artifact type="bundle" name="org.eclipse.equinox.common" version="[3.5.0, 3.7.0)" />
<artifact type="bundle" name="org.eclipse.osgi.services" version="[3.2.100, 4.0.0)" />
-->
2. change version range of org.eclipse.core.runtime:
<artifact type="bundle" name="org.eclipse.core.runtime" version="[3.6.0, 3.8.0)" />
you most likely encountered the following NPE:
Caused by: java.lang.NullPointerException: null
at org.eclipse.core.internal.runtime.ResourceTranslator.getResourceBundle(ResourceTranslator.java:69)
at org.eclipse.core.internal.runtime.ResourceTranslator.getResourceBundle(ResourceTranslator.java:61)
After investigating the source I came to the conclusion the NPE could be replaced with an InvalidStateException("Bundle not active") :-)
A singleton
private static Activator singleton;
is initialized in the Activator of 'org.eclipse.equinox.common' bundle.
The problem we encounter here is the state RESOLVED of the org.eclipse.equinox.common bundle after starting Virgo Kernel 3.0.0:
osgi> ss common
...
id State Bundle
65 RESOLVED org.eclipse.equinox.common_3.6.0.v20110523
Starting Virgo Kernel 2.1.1 the state is ACTIVE:
osgi> ss common
Framework is launched.
id State Bundle
10 ACTIVE org.eclipse.equinox.common_3.6.0.v20100503
After starting this bundle manually
osgi> start 65
I was able to deploy and run the RAP 1.4 demo on virgo-kernel-3.0.0:
osgi> ss equinox
"Framework is launched."
id State Bundle
47 ACTIVE org.eclipse.equinox.cm_1.0.300.v20101204
55 ACTIVE org.eclipse.equinox.console.supportability_1.0.0.N20110626-2000
62 ACTIVE org.eclipse.equinox.ds_1.3.0.v20110124-0830
63 ACTIVE org.eclipse.equinox.util_1.0.200.v20100503
65 ACTIVE org.eclipse.equinox.common_3.6.0.v20110523
73 ACTIVE org.eclipse.equinox.preferences_3.4.0.v20110502
74 ACTIVE org.eclipse.equinox.app_1.3.100.v20110321
82 ACTIVE org.eclipse.equinox.registry_3.5.100.v20110502
83 ACTIVE org.eclipse.equinox.http.registry_1.1.100.v20110502
84 ACTIVE org.eclipse.equinox.http.servlet_1.1.200.v20110502
osgi> ss rap
"Framework is launched."
id State Bundle
99 RESOLVED org.eclipse.rap.jface.databinding_1.4.0.20110614-2335
115 ACTIVE org.eclipse.rap.rwt_1.4.0.20110614-2335
Fragments=116
116 RESOLVED org.eclipse.rap.rwt.q07_1.4.0.20110614-2335
Master=115
117 ACTIVE org.eclipse.rap.jface_1.4.0.20110614-2335
118 ACTIVE org.eclipse.rap.ui.workbench_1.4.0.20110614-2335
119 ACTIVE org.eclipse.rap.ui_1.4.0.20110614-2335
120 ACTIVE org.eclipse.rap.ui.views_1.4.0.20110614-2335
121 ACTIVE org.eclipse.rap.demo_1.4.0.20110614-2335
Maybe one of the Virgo experts know how to ACTIVatE the 'org.eclipse.equinox.common' bundle during startup...
Amazing! i was so close to the solution! i've already commented out services and changed the version of runtime bundle in the plan. then i stuck and went googling, found this bug and commented on it. ;) thank you for the hints and thorough explanation, Florian! Hi, I managed to get rap 1.3.2 running on virgo 2.1.1. But when i tried to deploy rap 1.3 (or rap 1.4) on virgo 3.0.x it fails with the already mentioned NPE. I tried "ss common" in order to search and manually start the org.eclipse.equinox.common bundle, but it doesn't show up in the list. Re-enabling the org.eclipse.equinox.common bundle in the demo plan doesn't help, because then i got the error "The bundle could not be resolved because another singleton bundle was selected. In bundle <org.eclipse.equinox.common_3.6.0.v20100503>" How do i proceed? Regards Rino Extra info: (running on virgo-kernel-3.0.1.RELEASE ) macbook-rino:rap_on_virgo rino$ telnet localhost 2401 Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. osgi> ss common "Framework is launched." id State Bundle 3 ACTIVE com.springsource.slf4j.org.apache.commons.logging_1.6.1 12 ACTIVE org.eclipse.virgo.util.common_3.0.1.RELEASE 17 ACTIVE com.springsource.org.apache.commons.codec_1.3.0 18 ACTIVE com.springsource.org.apache.commons.httpclient_3.1.0 osgi> osgi> ss equinox "Framework is launched." id State Bundle 1 ACTIVE org.eclipse.equinox.region_1.0.0.v20110503 8 ACTIVE org.eclipse.equinox.cm_1.0.300.v20101204 11 ACTIVE org.eclipse.equinox.event_1.2.100.v20110110 32 ACTIVE org.eclipse.equinox.ds_1.3.0.v20110124-0830 33 ACTIVE org.eclipse.equinox.util_1.0.200.v20100503 45 ACTIVE org.eclipse.equinox.console.supportability_1.0.0.201108021516 osgi> Hi Rino,
thanks for providing the extra information.
> macbook-rino:rap_on_virgo rino$ telnet localhost 2401
As I can see you connect to the *kernel region* console by mistake (port 2401). Please activate the *user region* console in
repository/ext/osgi.console.telnet.properties
(port 2501 per default.)
Then you should be able to see the bundle you are looking for.
Hope this helps,
Florian
(In reply to comment #14) > Hi Rino, > > thanks for providing the extra information. > > > macbook-rino:rap_on_virgo rino$ telnet localhost 2401 > > As I can see you connect to the *kernel region* console by mistake (port 2401). > Please activate the *user region* console in > repository/ext/osgi.console.telnet.properties > (port 2501 per default.) > > Then you should be able to see the bundle you are looking for. > > Hope this helps, > Florian DOOH!, You're right. I was looking at the wrong properties file (the one in config)! Thanks for pointing it out. Will try again asap. Regards Rino |