Hello,

just for other people that are trying to get Vaadin 8 to work within an OSGi environment:

The ClassNotFoundException for AppWidgetset can be ignored. If Vaadin does not find this class it falls back to the default widgetset.

The lost connection seems to stem from false urlPatterns for UIs. After the initial load of an UI that is registered under localhost:8080/test Vaadin sends XHR requests for each interaction (e.g. resizing, clicks, etc.) to the server. The path for these requests are always in form of <myUrlPattern>/UIDL/?... In our case this would be localhost:8080/test/UIDL. If there is no servlet registered for this path, the Vaadin client receives a malformed response and displays a popup that says: Connection lost... . I fixed this issue in my example application by letting VaadinApplicationHandler change all urlPatterns of UIs to <myUrlPattern>/*

The VaadinResource class of the original enRoute example is not needed anymore, as Vaadin 8 takes care of registering its resources (Widgetsets/Themes/other stuff) itself as long as its bundles are started in the right order! The first bundle to start must be vaadin-shared.

Kind regards,
Thomas

------ Originalnachricht ------
Von: "Thomas Driessen" <thomas.dries...@ds-lab.org>
An: "Matthews, Kevin" <kevin.matth...@firstdata.com>; "Paul F Fraser" <pa...@a2zliving.com>; "OSGi Developer Mail List" <osgi-dev@mail.osgi.org>
Gesendet: 17.01.2018 18:07:27
Betreff: Re[2]: [osgi-dev] Fwd: Fwd: Vaadin 8.2 in OSGi: ClassNotFound

Hello Paul,

thank you for the hint to the enroute Vaadin exmaple.

My steps so far:

I tried to merge Peter's code with the current work of Vaadin regarding their OSGi compatibility [1] and got Vaadin 8.2.1 to at least show the UI once. However, after the initial request it looses the connection to the server and isn't working anymore :(

From Peter's code I removed the VaadinResources class, because this is done now by Vaadin, at least if you start the bundles in the right order [2]. They are using static method calls between bundles and if the vaadin-shared bundle hasn't been started before the others there will be an exception in the @Activate method of some of their other services -.-

Right now I'm dealing with a ClassNotFoundException as Vaadin can not find an AppWidgetset? Additionally the reconection issues seems to originate from some XHR configuration issues.

I've set up a sample workspace [3], so that anyone who is interested can investigate those issues too.

Kind regards,
Thomas


[1] https://github.com/mmerruko/framework/commit/ce52b21290ca5790b1b193876a2d000d7d1d970e
[2] https://github.com/vaadin/framework/issues/10526
[3] https://github.com/Sandared/vaadin8osgi.git


------ Originalnachricht ------
Von: "Matthews, Kevin via osgi-dev" <osgi-dev@mail.osgi.org>
An: "Paul F Fraser" <pa...@a2zliving.com>; "OSGi Developer Mail List" <osgi-dev@mail.osgi.org>
Gesendet: 17.01.2018 00:29:53
Betreff: Re: [osgi-dev] Fwd: Fwd: Vaadin 8.2 in OSGi: ClassNotFound

I apologize to send this request on this thread but I had sent this topic on a separate email thread and got no response. A simple question. Does anyone know or had done production deployment model using bnd osgi services. What’s the best practice to deploy these bundles to a standalone server as runnable jar or to docker containers using apache ace.



From:osgi-dev-boun...@mail.osgi.org [mailto:osgi-dev-boun...@mail.osgi.org] On Behalf Of Paul F Fraser via osgi-dev
Sent: Tuesday, January 16, 2018 6:00 PM
To: OSGi Developer Mail List
Subject: [osgi-dev] Fwd: Fwd: Vaadin 8.2 in OSGi: ClassNotFound



Forwarded with permission--

-------- Forwarded Message --------

Subject:

Fwd: [osgi-dev] Vaadin 8.2 in OSGi: ClassNotFound

Date:

Tue, 16 Jan 2018 22:24:18 +0100

From:

Pierre De Rop <pierre.de...@gmail.com> <mailto:pierre.de...@gmail.com>

To:

Paul F Fraser <pa...@a2zliving.com> <mailto:pa...@a2zliving.com>



Hello Paul;



I'm Pierre, one of the apache felix dependency manager committer;



so, I just wanted to comment the following part in your mail:



"Also, I have given up using Bndtools with Oxygen as there seems to be an intermittent problem that causes Eclipse to not load the workspace and once it happens I have had to reinstall Eclipse. So I have gone back to Neon and so far the problem has not re-occurred."



Indeed, I think I came across the same issue you described; and when my eclipse Oxygen (and bndtools 3.5.0) can't restart, then the problem is resolved using the "-clean" eclipse option (see [1]])



hope this helps;



kind regards

/Pierre



[1] https://stackoverflow.com/questions/2030064/how-to-run-eclipse-in-clean-mode-and-what-happens-if-we-do-so <https://urldefense.proofpoint.com/v2/url?u=https-3A__stackoverflow.com_questions_2030064_how-2Dto-2Drun-2Declipse-2Din-2Dclean-2Dmode-2Dand-2Dwhat-2Dhappens-2Dif-2Dwe-2Ddo-2Dso&d=DwMDaQ&c=ewHkv9vLloTwhsKn5d4bTdoqsmBfyfooQX5O7EQLv5TtBZ1CwcvjU063xndfqI8U&r=wKHHp1xupEN1UoR2CPDlg9US2Vs3om5ld5YqSsWMQX8&m=a2pcT_a1N3ce6Hakf7mZrvZB_WD-LRjm6tzRJMTZj00&s=rEKD80woMOc36eXclJlPWSsajWODV1ukr_CIysJsVgA&e=>



The information in this message may be proprietary and/or confidential, and protected from disclosure. If the reader of this message is not the intended recipient, or an employee or agent responsible for delivering this message to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please notify First Data immediately by replying to this message and deleting it from your computer.
_______________________________________________
OSGi Developer Mail List
osgi-dev@mail.osgi.org
https://mail.osgi.org/mailman/listinfo/osgi-dev

Reply via email to