You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@karaf.apache.org by Julian Feinauer <j....@pragmaticminds.de> on 2019/09/16 16:27:23 UTC
Vaadin Flow and Apache Karaf
Hi all,
we use the Vaadin Framework [1] in multiple projects as Frontend technology.
As I just recently started with Karaf I wanted to build a small example app based on Vaadin and OSGI.
Although Vaadin claims to have OSGi support [2], it really doesn’t feel well documented, properly tested and up to date. And it is lacking a good Karaf integration like a feature or so.
An Example project is shown here [3] but its very implicit (uses embedded Felix and tons of maven shenanigans as it looks).
Does anyone here have experience with Vaadin or an idea on how one would approach a Vaadin-OSGi Application?
Thanks!
Julian
[1] https://vaadin.com/
[2] https://vaadin.com/docs/v14/flow/osgi/tutorial-osgi-basic.html
[3] https://github.com/vaadin/base-starter-flow-osgi
Re: Vaadin Flow and Apache Karaf
Posted by Maurice Betzel <m....@gaston-schul.com>.
Hi, we at a Gaston-Schul have a Vaadin 14 and bnd / low level OSGi
application running in production for about half a year now. Basically it
builds on the Vaadin OSGi example, service discovery is low level OSGi
though. It consists just of one big bundle, modularity is in research. I
accomplished deeper OSGi integration with Vaadin 8 using only Java side
development, on Vaadin flow with polymer this seems not possible due to
having to embed all web components in every bundle added to the front end.
--
Sent from: http://karaf.922171.n3.nabble.com/Karaf-User-f930749.html
Re: Vaadin Flow and Apache Karaf
Posted by Julian Feinauer <j....@pragmaticminds.de>.
Hi JB,
thank you very much for the fast reply.
Indeed, I agree that a vaadin feature as PR to vaadin would be the best way.
So I'll check your feature and see what I can do from it.
Really appreciated!
Julian
Am 16.09.19, 09:33 schrieb "Jean-Baptiste Onofré" <jb...@nanthrax.net>:
Hi Julian,
I don't have personal experience but I helped some guys on Vaadin.
IMHO, Vaadin should provide a clean features XML.
This is one that I created for Vaadin 7:
<?xml version="1.0" encoding="UTF-8"?>
<features xmlns="http://karaf.apache.org/xmlns/features/v1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://karaf.apache.org/xmlns/features/v1.0.0
http://karaf.apache.org/xmlns/features/v1.0.0"
name="vaadin7-feature">
<feature install="true" name="vaadin7-feature" version="1.0.0-SNAPSHOT">
<feature>vaadin7-common</feature>
<bundle>mvn:com.vaadin/vaadin-themes/7.3.0</bundle>
<bundle>mvn:com.vaadin/vaadin-shared/7.3.0</bundle>
<bundle>mvn:com.vaadin/vaadin-server/7.3.0</bundle>
<bundle>mvn:com.vaadin/vaadin-client/7.3.0</bundle>
<bundle>mvn:com.vaadin/vaadin-client-compiled/7.3.0</bundle>
<bundle>mvn:com.vaadin/vaadin-push/7.3.0</bundle>
<bundle>mvn:com.vaadin/vaadin-sass-compiler/0.9.2</bundle>
</feature>
<feature name="vaadin7-common" version="1.0.0-SNAPSHOT">
<bundle>mvn:com.vaadin.external.google/android-json/0.0.20131108.vaadin1</bundle>
<bundle>mvn:org.jbundle.util.osgi.wrapped/org.jbundle.util.osgi.wrapped.c3p0/0.9.1.2</bundle>
<bundle>mvn:org.quartz-scheduler/quartz/2.2.1</bundle>
<bundle>mvn:joda-time/joda-time/2.4</bundle>
<bundle>wrap:mvn:org.springframework/spring-core/3.2.6.RELEASE$Bundle-SymbolicName=Spring-Framework&Bundle-Version=3.2.6.RELEASE</bundle>
<bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.xpp3/1.1.4c_7</bundle>
<bundle>mvn:com.google.guava/guava/16.0.1</bundle>
<bundle>mvn:io.netty/netty/3.9.0.Final</bundle>
<bundle>mvn:org.apache.commons/commons-lang3/3.3.2</bundle>
<bundle>mvn:com.vaadin.external.flute/flute/1.3.0.gg2</bundle>
<bundle>mvn:com.vaadin.external.streamhtmlparser/streamhtmlparser-jsilver/0.0.10.vaadin1</bundle>
<bundle>mvn:com.vaadin.external.google/guava/16.0.1.vaadin1</bundle>
<bundle>mvn:org.eclipse.jetty.orbit/javax.servlet/3.0.0.v201112011016</bundle>
<bundle>wrap:mvn:org.w3c.css/sac/1.3$Bundle-SymbolicName=org-w3c-css-sac&Bundle-Version=1.3</bundle>
<bundle>mvn:org.jsoup/jsoup/1.6.3</bundle>
<bundle>mvn:com.vaadin.external.slf4j/vaadin-slf4j-jdk14/1.6.1</bundle>
<bundle>mvn:com.vaadin.external.atmosphere/atmosphere-runtime/2.1.2.vaadin3</bundle>
<bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.gwt-dev/2.4.0_1</bundle>
<bundle>mvn:org.apache.commons/commons-jexl/2.1.1</bundle>
<bundle>mvn:com.vaadin.external.json/json/0.0.20080701</bundle>
<bundle>wrap:mvn:javax.validation/validation-api/1.0.0.GA$Bundle-SymbolicName=validation-api&Bundle-Version=1.0.0.GA</bundle>
<bundle>wrap:mvn:net.sourceforge.cssparser/cssparser/0.9.11$Bundle-SymbolicName=cssparser&Bundle-Version=0.9.11</bundle>
</feature>
</features>
It's not up to date, but could be a good starting point to update ;)
I would propose a updated features XML as Vaadin PR.
Regards
JB
On 16/09/2019 18:27, Julian Feinauer wrote:
> Hi all,
>
>
>
> we use the Vaadin Framework [1] in multiple projects as Frontend technology.
>
> As I just recently started with Karaf I wanted to build a small example
> app based on Vaadin and OSGI.
>
> Although Vaadin claims to have OSGi support [2], it really doesn’t feel
> well documented, properly tested and up to date. And it is lacking a
> good Karaf integration like a feature or so.
>
> An Example project is shown here [3] but its very implicit (uses
> embedded Felix and tons of maven shenanigans as it looks).
>
>
>
> Does anyone here have experience with Vaadin or an idea on how one would
> approach a Vaadin-OSGi Application?
>
>
>
> Thanks!
>
> Julian
>
>
>
> [1] https://vaadin.com/
>
> [2] https://vaadin.com/docs/v14/flow/osgi/tutorial-osgi-basic.html
>
> [3] https://github.com/vaadin/base-starter-flow-osgi
>
--
Jean-Baptiste Onofré
jbonofre@apache.org
http://blog.nanthrax.net
Talend - http://www.talend.com
Re: Vaadin Flow and Apache Karaf
Posted by Jean-Baptiste Onofré <jb...@nanthrax.net>.
Hi Julian,
I don't have personal experience but I helped some guys on Vaadin.
IMHO, Vaadin should provide a clean features XML.
This is one that I created for Vaadin 7:
<?xml version="1.0" encoding="UTF-8"?>
<features xmlns="http://karaf.apache.org/xmlns/features/v1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://karaf.apache.org/xmlns/features/v1.0.0
http://karaf.apache.org/xmlns/features/v1.0.0"
name="vaadin7-feature">
<feature install="true" name="vaadin7-feature" version="1.0.0-SNAPSHOT">
<feature>vaadin7-common</feature>
<bundle>mvn:com.vaadin/vaadin-themes/7.3.0</bundle>
<bundle>mvn:com.vaadin/vaadin-shared/7.3.0</bundle>
<bundle>mvn:com.vaadin/vaadin-server/7.3.0</bundle>
<bundle>mvn:com.vaadin/vaadin-client/7.3.0</bundle>
<bundle>mvn:com.vaadin/vaadin-client-compiled/7.3.0</bundle>
<bundle>mvn:com.vaadin/vaadin-push/7.3.0</bundle>
<bundle>mvn:com.vaadin/vaadin-sass-compiler/0.9.2</bundle>
</feature>
<feature name="vaadin7-common" version="1.0.0-SNAPSHOT">
<bundle>mvn:com.vaadin.external.google/android-json/0.0.20131108.vaadin1</bundle>
<bundle>mvn:org.jbundle.util.osgi.wrapped/org.jbundle.util.osgi.wrapped.c3p0/0.9.1.2</bundle>
<bundle>mvn:org.quartz-scheduler/quartz/2.2.1</bundle>
<bundle>mvn:joda-time/joda-time/2.4</bundle>
<bundle>wrap:mvn:org.springframework/spring-core/3.2.6.RELEASE$Bundle-SymbolicName=Spring-Framework&Bundle-Version=3.2.6.RELEASE</bundle>
<bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.xpp3/1.1.4c_7</bundle>
<bundle>mvn:com.google.guava/guava/16.0.1</bundle>
<bundle>mvn:io.netty/netty/3.9.0.Final</bundle>
<bundle>mvn:org.apache.commons/commons-lang3/3.3.2</bundle>
<bundle>mvn:com.vaadin.external.flute/flute/1.3.0.gg2</bundle>
<bundle>mvn:com.vaadin.external.streamhtmlparser/streamhtmlparser-jsilver/0.0.10.vaadin1</bundle>
<bundle>mvn:com.vaadin.external.google/guava/16.0.1.vaadin1</bundle>
<bundle>mvn:org.eclipse.jetty.orbit/javax.servlet/3.0.0.v201112011016</bundle>
<bundle>wrap:mvn:org.w3c.css/sac/1.3$Bundle-SymbolicName=org-w3c-css-sac&Bundle-Version=1.3</bundle>
<bundle>mvn:org.jsoup/jsoup/1.6.3</bundle>
<bundle>mvn:com.vaadin.external.slf4j/vaadin-slf4j-jdk14/1.6.1</bundle>
<bundle>mvn:com.vaadin.external.atmosphere/atmosphere-runtime/2.1.2.vaadin3</bundle>
<bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.gwt-dev/2.4.0_1</bundle>
<bundle>mvn:org.apache.commons/commons-jexl/2.1.1</bundle>
<bundle>mvn:com.vaadin.external.json/json/0.0.20080701</bundle>
<bundle>wrap:mvn:javax.validation/validation-api/1.0.0.GA$Bundle-SymbolicName=validation-api&Bundle-Version=1.0.0.GA</bundle>
<bundle>wrap:mvn:net.sourceforge.cssparser/cssparser/0.9.11$Bundle-SymbolicName=cssparser&Bundle-Version=0.9.11</bundle>
</feature>
</features>
It's not up to date, but could be a good starting point to update ;)
I would propose a updated features XML as Vaadin PR.
Regards
JB
On 16/09/2019 18:27, Julian Feinauer wrote:
> Hi all,
>
>
>
> we use the Vaadin Framework [1] in multiple projects as Frontend technology.
>
> As I just recently started with Karaf I wanted to build a small example
> app based on Vaadin and OSGI.
>
> Although Vaadin claims to have OSGi support [2], it really doesn’t feel
> well documented, properly tested and up to date. And it is lacking a
> good Karaf integration like a feature or so.
>
> An Example project is shown here [3] but its very implicit (uses
> embedded Felix and tons of maven shenanigans as it looks).
>
>
>
> Does anyone here have experience with Vaadin or an idea on how one would
> approach a Vaadin-OSGi Application?
>
>
>
> Thanks!
>
> Julian
>
>
>
> [1] https://vaadin.com/
>
> [2] https://vaadin.com/docs/v14/flow/osgi/tutorial-osgi-basic.html
>
> [3] https://github.com/vaadin/base-starter-flow-osgi
>
--
Jean-Baptiste Onofré
jbonofre@apache.org
http://blog.nanthrax.net
Talend - http://www.talend.com
Re: Vaadin Flow and Apache Karaf
Posted by Steinar Bang <sb...@dod.no>.
>>>>> Julian Feinauer <j....@pragmaticminds.de>:
> Hi all,
> we use the Vaadin Framework [1] in multiple projects as Frontend technology.
> As I just recently started with Karaf I wanted to build a small example app based on Vaadin and OSGI.
> Although Vaadin claims to have OSGi support [2], it really doesn’t feel well documented, properly tested and up to date. And it is lacking a good Karaf integration like a feature or so.
> An Example project is shown here [3] but its very implicit (uses embedded Felix and tons of maven shenanigans as it looks).
> Does anyone here have experience with Vaadin or an idea on how one would approach a Vaadin-OSGi Application?
My ukelonn web application[1] has gone through several iterations:
1. A JSF application using PrimeFaces[2] (started in July 2016 and
abandoned in December 2016)
2. A Vaadin application[3] (on master from December 2016 abandoned in August 2018)
3. A react.js application, with a REST API written using jersey[4],
initially (ie from August 2018 to July 2019) styled with Material
Design Lite (MDL)[5], but currently styled with bootstrap 4[6]
In Vaadin I was using an extension called TouchKit[7] to get a mobile
app'ish look on the application. However TouchKit was kind of, sort of,
abandoned when moving to Vaadin 8. I tried getting the open sourced
version of TouchKit[8] working, providing some Pull Requests to the
project.
But I never got the Vaadin8 version working[9], and sometime in the spring
of 2018 gave up on TouchKit and started moving towards making ukelonn a
react.js application, backed a REST API.
And that approach proved to be so much conceptually simpler and so much
easier to maintain, that I will never be going back again, I think.
(I may switch react.js with something else, like Vue.js or Svelte.js,
but for now react/redux with sagas seems like the simplest to program
and debug)
If anyone are interest I can try to outline the architecture of the
react.js solution (can't do the same for the older versions,
unfortunately, because I can't quite remember how they were put
together...:-) ).
References:
[1] <https://github.com/steinarb/ukelonn>
[2] <https://github.com/steinarb/ukelonn/tree/using-primefaces>
[3] <https://github.com/steinarb/ukelonn/tree/using-vaadin>
[4] <https://github.com/steinarb/ukelonn/tree/using-react>
[5] <https://github.com/steinarb/ukelonn/tree/work/using-react-with-material-design-lite>
[6] <https://github.com/steinarb/ukelonn/tree/work/using-react-with-bootstrap4>
[7] <https://vaadin.com/docs/v7/touchkit/mobile-components.html>
[8] <https://vaadin.com/blog/touchkit-is-dead-long-live-touchkit>
[9] <https://github.com/steinarb/ukelonn/tree/work/using-vaadin-with-vaadin8>
Re: Vaadin Flow and Apache Karaf
Posted by Markus Rathgeb <ma...@gmail.com>.
I got the vaadin start project (TextField, Button, Notification)
working in an bnd application.
I used vaadin 14.1.5 and flow 2.1.4.
So, I "know" all bundles that are necessary for that use case
and
how a pom needs to look like to build a vaadin bundle that is working.
Now I can start clean up stuff and try to understand what is vaadin at all ;)
Am So., 26. Jan. 2020 um 14:56 Uhr schrieb stefang <st...@me.com>:
>
> Hi,
>
> it would be nice if a "war" from Vaadin Flow build could be run as WebApp
> under Karaf with "war" feature.
> Thats actually not possible and because of this we must setup a separate
> Jetty Instance to get it running.
>
> Regards
> Stefan
>
>
>
>
> jbonofre wrote
> > Hi Markus,
> >
> > Julian reported issue with Vaadin. I never tried (we are using mostly
> > Karaf services with Angular).
> >
> > Let me create a Jira to add a vaadin example:
> > https://issues.apache.org/jira/browse/KARAF-6608
> >
> > Regards
> > JB
> >
> > On 25/01/2020 22:20, Markus Rathgeb wrote:
> >> Hi,
> >>
> >> has there been already any progress for example working features for
> >> Vaadin 14 or a simple demo bundle that shows the feature working in
> >> Karaf?
> >>
> >> Best regards,
> >> Markus
>
>
>
>
>
> --
> Sent from: http://karaf.922171.n3.nabble.com/Karaf-User-f930749.html
Re: Vaadin Flow and Apache Karaf
Posted by stefang <st...@me.com>.
Hi,
it would be nice if a "war" from Vaadin Flow build could be run as WebApp
under Karaf with "war" feature.
Thats actually not possible and because of this we must setup a separate
Jetty Instance to get it running.
Regards
Stefan
jbonofre wrote
> Hi Markus,
>
> Julian reported issue with Vaadin. I never tried (we are using mostly
> Karaf services with Angular).
>
> Let me create a Jira to add a vaadin example:
> https://issues.apache.org/jira/browse/KARAF-6608
>
> Regards
> JB
>
> On 25/01/2020 22:20, Markus Rathgeb wrote:
>> Hi,
>>
>> has there been already any progress for example working features for
>> Vaadin 14 or a simple demo bundle that shows the feature working in
>> Karaf?
>>
>> Best regards,
>> Markus
--
Sent from: http://karaf.922171.n3.nabble.com/Karaf-User-f930749.html