Fling Installation on Trunk

classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

Fling Installation on Trunk

Andreas Schaefer
Hi

I tried to install Fling from the Samples but failed with the latest Sling.

First I had to install Sling Messaging and Sling Query but then
I gave up on Sling Thymeleaf which has dependencies on com.fasterxml.jackson.ocre
etc that are not deployed in Sling and it also looks like they are
not deployed by any other bundle.

A sample does not much good if I cannot build and install it, right?

I am pretty fluent with package dependencies and so if I cannot
figure it out in an acceptable time frame then who will.

Any pointers on how to get this working would be very much
appreciated.

Thanks - Andy Schaefer
Reply | Threaded
Open this post in threaded view
|

Re: Fling Installation on Trunk

Oliver Lietz
On Monday 27 March 2017 13:05:38 Andreas Schaefer Sr. wrote:

> Hi
>
> I tried to install Fling from the Samples but failed with the latest Sling.
>
> First I had to install Sling Messaging and Sling Query but then
> I gave up on Sling Thymeleaf which has dependencies on
> com.fasterxml.jackson.ocre etc that are not deployed in Sling and it also
> looks like they are not deployed by any other bundle.
>
> A sample does not much good if I cannot build and install it, right?

*sigh

> I am pretty fluent with package dependencies and so if I cannot
> figure it out in an acceptable time frame then who will.

Stop whining and start reading, please.

> Any pointers on how to get this working would be very much
> appreciated.

The version of Fling is 0.0.1-SNAPSHOT which clearly indicates that it is work
in progress. Fling itself depends on some snapshots namely Validation and
Messaging (and therefore has to be adjusted sometimes when those dependencies
do incompatible changes – see my latest commits). Fling's prerequisites are
listed in the README: https://github.com/apache/sling/tree/trunk/samples/fling

How to install Scripting Thymeleaf is described in its README (and btw.
Jackson is optional):
https://github.com/apache/sling/tree/trunk/contrib/scripting/org.apache.sling.scripting.thymeleaf

If you are unable to install those dependencies into Launchpad you can try
with Sling's Karaf Distribution:
https://github.com/apache/sling/tree/trunk/karaf

Start Karaf and open http://localhost:8181/system/console/features, install
sling-launchpad-oak-tar and sling-samples-fling by clicking the play/install
buttons on the right. Open http://localhost:8181/fling.html

O.

> Thanks - Andy Schaefer

Reply | Threaded
Open this post in threaded view
|

Re: Fling Installation on Trunk

Andreas Schaefer
Hi Oliver

It would be nice if the Readme would indicate that this is a work in
progress to avoid users wasting time on a piece that is not ready
for prime time. As the trunk is probably the first thing people
get as Sling code this would be helpful I think.

In my opinion an example should be plug and play. For anyone
not very familiar with Sling this is disheartening and can turn them
away from Sling. I hope that Fling eventually gets there but for
now I pass as I don’t have the time to look into that (have my own
little peeve Sling project).

Thanks - Andy Schaefer

> On Mar 28, 2017, at 1:22 AM, Oliver Lietz <[hidden email]> wrote:
>
> On Monday 27 March 2017 13:05:38 Andreas Schaefer Sr. wrote:
>> Hi
>>
>> I tried to install Fling from the Samples but failed with the latest Sling.
>>
>> First I had to install Sling Messaging and Sling Query but then
>> I gave up on Sling Thymeleaf which has dependencies on
>> com.fasterxml.jackson.ocre etc that are not deployed in Sling and it also
>> looks like they are not deployed by any other bundle.
>>
>> A sample does not much good if I cannot build and install it, right?
>
> *sigh
>
>> I am pretty fluent with package dependencies and so if I cannot
>> figure it out in an acceptable time frame then who will.
>
> Stop whining and start reading, please.
>
>> Any pointers on how to get this working would be very much
>> appreciated.
>
> The version of Fling is 0.0.1-SNAPSHOT which clearly indicates that it is work
> in progress. Fling itself depends on some snapshots namely Validation and
> Messaging (and therefore has to be adjusted sometimes when those dependencies
> do incompatible changes – see my latest commits). Fling's prerequisites are
> listed in the README: https://github.com/apache/sling/tree/trunk/samples/fling
>
> How to install Scripting Thymeleaf is described in its README (and btw.
> Jackson is optional):
> https://github.com/apache/sling/tree/trunk/contrib/scripting/org.apache.sling.scripting.thymeleaf
>
> If you are unable to install those dependencies into Launchpad you can try
> with Sling's Karaf Distribution:
> https://github.com/apache/sling/tree/trunk/karaf
>
> Start Karaf and open http://localhost:8181/system/console/features, install
> sling-launchpad-oak-tar and sling-samples-fling by clicking the play/install
> buttons on the right. Open http://localhost:8181/fling.html
>
> O.
>
>> Thanks - Andy Schaefer
>

Reply | Threaded
Open this post in threaded view
|

Re: Fling Installation on Trunk

Oliver Lietz
On Tuesday 28 March 2017 10:07:00 Andreas Schaefer Sr. wrote:
> Hi Oliver

Hi Andy,

> It would be nice if the Readme would indicate that this is a work in
> progress to avoid users wasting time on a piece that is not ready
> for prime time. As the trunk is probably the first thing people
> get as Sling code this would be helpful I think.

the very first sentence says that this sample is using snapshots. People
having no experience with Sling should not use trunk but releases.

> In my opinion an example should be plug and play. For anyone
> not very familiar with Sling this is disheartening and can turn them
> away from Sling. I hope that Fling eventually gets there but for
> now I pass as I don’t have the time to look into that (have my own
> little peeve Sling project).

The Fling sample is using modules (from trunk) which cannot be part of
Launchpad – that means no plug and play with Launchpad (using Sling Karaf
makes it plug and play though).

Nevertheless it works for others and some find it quite useful. I'm sorry that
it doesn't work for you.

Regards,
O.

> Thanks - Andy Schaefer
>
> > On Mar 28, 2017, at 1:22 AM, Oliver Lietz <[hidden email]> wrote:
> >
> > On Monday 27 March 2017 13:05:38 Andreas Schaefer Sr. wrote:
> >> Hi
> >>
> >> I tried to install Fling from the Samples but failed with the latest
> >> Sling.
> >>
> >> First I had to install Sling Messaging and Sling Query but then
> >> I gave up on Sling Thymeleaf which has dependencies on
> >> com.fasterxml.jackson.ocre etc that are not deployed in Sling and it also
> >> looks like they are not deployed by any other bundle.
> >>
> >> A sample does not much good if I cannot build and install it, right?
> >
> > *sigh
> >
> >> I am pretty fluent with package dependencies and so if I cannot
> >> figure it out in an acceptable time frame then who will.
> >
> > Stop whining and start reading, please.
> >
> >> Any pointers on how to get this working would be very much
> >> appreciated.
> >
> > The version of Fling is 0.0.1-SNAPSHOT which clearly indicates that it is
> > work in progress. Fling itself depends on some snapshots namely
> > Validation and Messaging (and therefore has to be adjusted sometimes when
> > those dependencies do incompatible changes – see my latest commits).
> > Fling's prerequisites are listed in the README:
> > https://github.com/apache/sling/tree/trunk/samples/fling
> >
> > How to install Scripting Thymeleaf is described in its README (and btw.
> > Jackson is optional):
> > https://github.com/apache/sling/tree/trunk/contrib/scripting/org.apache.sl
> > ing.scripting.thymeleaf
> >
> > If you are unable to install those dependencies into Launchpad you can try
> > with Sling's Karaf Distribution:
> > https://github.com/apache/sling/tree/trunk/karaf
> >
> > Start Karaf and open http://localhost:8181/system/console/features,
> > install
> > sling-launchpad-oak-tar and sling-samples-fling by clicking the
> > play/install buttons on the right. Open http://localhost:8181/fling.html
> >
> > O.
> >
> >> Thanks - Andy Schaefer


Reply | Threaded
Open this post in threaded view
|

Re: Fling Installation on Trunk

Bertrand Delacretaz
On Tue, Mar 28, 2017 at 8:48 PM, Oliver Lietz <[hidden email]> wrote:
> -...The Fling sample is using modules (from trunk) which cannot be part of
> Launchpad...

> Nevertheless it works for others and some find it quite useful...

I have added a warning about snapshots to the Fling sample in
http://svn.apache.org/r1789329 - hopefully this helps and if not feel
free to tweak.

-Bertrand
Reply | Threaded
Open this post in threaded view
|

Re: Fling Installation on Trunk

Oliver Lietz
On Wednesday 29 March 2017 12:42:52 Bertrand Delacretaz wrote:
> On Tue, Mar 28, 2017 at 8:48 PM, Oliver Lietz <[hidden email]> wrote:
> > -...The Fling sample is using modules (from trunk) which cannot be part of
> > Launchpad...
> >
> > Nevertheless it works for others and some find it quite useful...
>
> I have added a warning about snapshots to the Fling sample in
> http://svn.apache.org/r1789329 - hopefully this helps and if not feel
> free to tweak.

Thanks, Bertrand. I made the warning bold to be even more obvious.

O.

> -Bertrand

Reply | Threaded
Open this post in threaded view
|

Re: Fling Installation on Trunk

Andreas Schaefer
In reply to this post by Oliver Lietz
For something else I delved into Sling Provisioning and I
came up with a way to import Thymeleaf. Not sure if  that
is the best way but it seems to work.

When I add a file called thymeleaf.txt to launchpad/builder/src/main/provisioning
with that content:

[feature name=thymeleaf]

# Add the dependencies on the Model exporter
[artifacts]
    org.attoparser/attoparser/2.0.2.RELEASE
    org.unbescape/unbescape/1.1.4.RELEASE
    org.apache.servicemix.bundles/org.apache.servicemix.bundles.ognl/3.2_1
    org.javassist/javassist/3.20.0-GA
    org.apache.sling/org.apache.sling.scripting.thymeleaf/1.1.1-SNAPSHOT

Build and start sling (just the builder) I have thymeleaf installed and prepped
and ready.

So I am wondering if there is a better way or if I can create my own provisioning
models but keep them in a separate folder.

Thanks - Andy Schaefer

> On Mar 28, 2017, at 1:22 AM, Oliver Lietz <[hidden email]> wrote:
>
> On Monday 27 March 2017 13:05:38 Andreas Schaefer Sr. wrote:
>> Hi
>>
>> I tried to install Fling from the Samples but failed with the latest Sling.
>>
>> First I had to install Sling Messaging and Sling Query but then
>> I gave up on Sling Thymeleaf which has dependencies on
>> com.fasterxml.jackson.ocre etc that are not deployed in Sling and it also
>> looks like they are not deployed by any other bundle.
>>
>> A sample does not much good if I cannot build and install it, right?
>
> *sigh
>
>> I am pretty fluent with package dependencies and so if I cannot
>> figure it out in an acceptable time frame then who will.
>
> Stop whining and start reading, please.
>
>> Any pointers on how to get this working would be very much
>> appreciated.
>
> The version of Fling is 0.0.1-SNAPSHOT which clearly indicates that it is work
> in progress. Fling itself depends on some snapshots namely Validation and
> Messaging (and therefore has to be adjusted sometimes when those dependencies
> do incompatible changes – see my latest commits). Fling's prerequisites are
> listed in the README: https://github.com/apache/sling/tree/trunk/samples/fling
>
> How to install Scripting Thymeleaf is described in its README (and btw.
> Jackson is optional):
> https://github.com/apache/sling/tree/trunk/contrib/scripting/org.apache.sling.scripting.thymeleaf
>
> If you are unable to install those dependencies into Launchpad you can try
> with Sling's Karaf Distribution:
> https://github.com/apache/sling/tree/trunk/karaf
>
> Start Karaf and open http://localhost:8181/system/console/features, install
> sling-launchpad-oak-tar and sling-samples-fling by clicking the play/install
> buttons on the right. Open http://localhost:8181/fling.html
>
> O.
>
>> Thanks - Andy Schaefer
>

Reply | Threaded
Open this post in threaded view
|

Re: Fling Installation on Trunk

Oliver Lietz
On Friday 31 March 2017 14:39:46 Andreas Schaefer Sr. wrote:

> For something else I delved into Sling Provisioning and I
> came up with a way to import Thymeleaf. Not sure if  that
> is the best way but it seems to work.
>
> When I add a file called thymeleaf.txt to
> launchpad/builder/src/main/provisioning with that content:
>
> [feature name=thymeleaf]
>
> # Add the dependencies on the Model exporter
> [artifacts]
>     org.attoparser/attoparser/2.0.2.RELEASE
>     org.unbescape/unbescape/1.1.4.RELEASE
>     org.apache.servicemix.bundles/org.apache.servicemix.bundles.ognl/3.2_1
>     org.javassist/javassist/3.20.0-GA
>     org.apache.sling/org.apache.sling.scripting.thymeleaf/1.1.1-SNAPSHOT
>
> Build and start sling (just the builder) I have thymeleaf installed and
> prepped and ready.
>
> So I am wondering if there is a better way or if I can create my own
> provisioning models but keep them in a separate folder.

That way is totally perfect, but you can use Scripting Thymeleaf 1.1.0 of
course.

Feel free to open an issue if you want Scripting Thymeleaf be part of
Launchpad builder. We should provide run modes for Sightly and Thymeleaf then
until SLING-4330 is done as both use .html extension per default which leads
to errors when running both.

Regards,
O.

> Thanks - Andy Schaefer


Reply | Threaded
Open this post in threaded view
|

Re: Fling Installation on Trunk

Roy Teeuwen
In reply to this post by Andreas Schaefer
Hey Andreas,

You can make your own custom launchpads with a maven project.

In your pom.xml you use the following plugin:

            <plugin>
                <groupId>org.apache.sling</groupId>
                <artifactId>slingstart-maven-plugin</artifactId>
                <extensions>true</extensions>
            </plugin>

Until sling 9 is released you use the following snapshot dependency, or you could also use sling version 8:

        <dependency>
            <groupId>org.apache.sling</groupId>
            <artifactId>org.apache.sling.launchpad</artifactId>
            <version>9-SNAPSHOT</version>
            <type>slingstart</type>
        </dependency>

Add a boot.txt in the directory src/main/provisioning containing the following info:

[feature name=:boot]

[artifacts]
    org.apache.sling/org.apache.sling.launchpad/9-SNAPSHOT/slingstart

Add any txt file in the same directory to add your custom stuff you need. For example add a thymeleaf.txt containing:

[feature name=thymeleaf]

# Add the dependencies on the Model exporter
[artifacts]
   org.attoparser/attoparser/2.0.2.RELEASE
   org.unbescape/unbescape/1.1.4.RELEASE
   org.apache.servicemix.bundles/org.apache.servicemix.bundles.ognl/3.2_1
   org.javassist/javassist/3.20.0-GA
   org.apache.sling/org.apache.sling.scripting.thymeleaf/1.1.1-SNAPSHOT

Now build your project, and in your target folder you will have your custom created launchpad jar

Greets,
Roy



> On 31 Mar 2017, at 23:39, Andreas Schaefer Sr. <[hidden email]> wrote:
>
> For something else I delved into Sling Provisioning and I
> came up with a way to import Thymeleaf. Not sure if  that
> is the best way but it seems to work.
>
> When I add a file called thymeleaf.txt to launchpad/builder/src/main/provisioning
> with that content:
>
> [feature name=thymeleaf]
>
> # Add the dependencies on the Model exporter
> [artifacts]
>    org.attoparser/attoparser/2.0.2.RELEASE
>    org.unbescape/unbescape/1.1.4.RELEASE
>    org.apache.servicemix.bundles/org.apache.servicemix.bundles.ognl/3.2_1
>    org.javassist/javassist/3.20.0-GA
>    org.apache.sling/org.apache.sling.scripting.thymeleaf/1.1.1-SNAPSHOT
>
> Build and start sling (just the builder) I have thymeleaf installed and prepped
> and ready.
>
> So I am wondering if there is a better way or if I can create my own provisioning
> models but keep them in a separate folder.
>
> Thanks - Andy Schaefer
>
>> On Mar 28, 2017, at 1:22 AM, Oliver Lietz <[hidden email]> wrote:
>>
>> On Monday 27 March 2017 13:05:38 Andreas Schaefer Sr. wrote:
>>> Hi
>>>
>>> I tried to install Fling from the Samples but failed with the latest Sling.
>>>
>>> First I had to install Sling Messaging and Sling Query but then
>>> I gave up on Sling Thymeleaf which has dependencies on
>>> com.fasterxml.jackson.ocre etc that are not deployed in Sling and it also
>>> looks like they are not deployed by any other bundle.
>>>
>>> A sample does not much good if I cannot build and install it, right?
>>
>> *sigh
>>
>>> I am pretty fluent with package dependencies and so if I cannot
>>> figure it out in an acceptable time frame then who will.
>>
>> Stop whining and start reading, please.
>>
>>> Any pointers on how to get this working would be very much
>>> appreciated.
>>
>> The version of Fling is 0.0.1-SNAPSHOT which clearly indicates that it is work
>> in progress. Fling itself depends on some snapshots namely Validation and
>> Messaging (and therefore has to be adjusted sometimes when those dependencies
>> do incompatible changes – see my latest commits). Fling's prerequisites are
>> listed in the README: https://github.com/apache/sling/tree/trunk/samples/fling
>>
>> How to install Scripting Thymeleaf is described in its README (and btw.
>> Jackson is optional):
>> https://github.com/apache/sling/tree/trunk/contrib/scripting/org.apache.sling.scripting.thymeleaf
>>
>> If you are unable to install those dependencies into Launchpad you can try
>> with Sling's Karaf Distribution:
>> https://github.com/apache/sling/tree/trunk/karaf
>>
>> Start Karaf and open http://localhost:8181/system/console/features, install
>> sling-launchpad-oak-tar and sling-samples-fling by clicking the play/install
>> buttons on the right. Open http://localhost:8181/fling.html
>>
>> O.
>>
>>> Thanks - Andy Schaefer
>>
>


signature.asc (817 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Fling Installation on Trunk

Oliver Lietz
On Saturday 01 April 2017 13:25:49 Roy Teeuwen wrote:

> Hey Andreas,
>
> You can make your own custom launchpads with a maven project.
>
> In your pom.xml you use the following plugin:
>
>             <plugin>
>                 <groupId>org.apache.sling</groupId>
>                 <artifactId>slingstart-maven-plugin</artifactId>
>                 <extensions>true</extensions>
>             </plugin>
>
> Until sling 9 is released you use the following snapshot dependency, or you
> could also use sling version 8:

Sling 8 is too old for Scripting Thymeleaf 1.1.0.

Regards,
O.

>
>         <dependency>
>             <groupId>org.apache.sling</groupId>
>             <artifactId>org.apache.sling.launchpad</artifactId>
>             <version>9-SNAPSHOT</version>
>             <type>slingstart</type>
>         </dependency>
>
> Add a boot.txt in the directory src/main/provisioning containing the
> following info:
>
> [feature name=:boot]
>
> [artifacts]
>     org.apache.sling/org.apache.sling.launchpad/9-SNAPSHOT/slingstart
>
> Add any txt file in the same directory to add your custom stuff you need.
> For example add a thymeleaf.txt containing:
>
> [feature name=thymeleaf]
>
> # Add the dependencies on the Model exporter
> [artifacts]
>    org.attoparser/attoparser/2.0.2.RELEASE
>    org.unbescape/unbescape/1.1.4.RELEASE
>    org.apache.servicemix.bundles/org.apache.servicemix.bundles.ognl/3.2_1
>    org.javassist/javassist/3.20.0-GA
>    org.apache.sling/org.apache.sling.scripting.thymeleaf/1.1.1-SNAPSHOT
>
> Now build your project, and in your target folder you will have your custom
> created launchpad jar
>
> Greets,
> Roy
>
> > On 31 Mar 2017, at 23:39, Andreas Schaefer Sr. <[hidden email]> wrote:
> >
> > For something else I delved into Sling Provisioning and I
> > came up with a way to import Thymeleaf. Not sure if  that
> > is the best way but it seems to work.
> >
> > When I add a file called thymeleaf.txt to
> > launchpad/builder/src/main/provisioning with that content:
> >
> > [feature name=thymeleaf]
> >
> > # Add the dependencies on the Model exporter
> > [artifacts]
> >
> >    org.attoparser/attoparser/2.0.2.RELEASE
> >    org.unbescape/unbescape/1.1.4.RELEASE
> >    org.apache.servicemix.bundles/org.apache.servicemix.bundles.ognl/3.2_1
> >    org.javassist/javassist/3.20.0-GA
> >    org.apache.sling/org.apache.sling.scripting.thymeleaf/1.1.1-SNAPSHOT
> >
> > Build and start sling (just the builder) I have thymeleaf installed and
> > prepped and ready.
> >
> > So I am wondering if there is a better way or if I can create my own
> > provisioning models but keep them in a separate folder.
> >
> > Thanks - Andy Schaefer
> >
> >> On Mar 28, 2017, at 1:22 AM, Oliver Lietz <[hidden email]> wrote:
> >>
> >> On Monday 27 March 2017 13:05:38 Andreas Schaefer Sr. wrote:
> >>> Hi
> >>>
> >>> I tried to install Fling from the Samples but failed with the latest
> >>> Sling.
> >>>
> >>> First I had to install Sling Messaging and Sling Query but then
> >>> I gave up on Sling Thymeleaf which has dependencies on
> >>> com.fasterxml.jackson.ocre etc that are not deployed in Sling and it
> >>> also
> >>> looks like they are not deployed by any other bundle.
> >>>
> >>> A sample does not much good if I cannot build and install it, right?
> >>
> >> *sigh
> >>
> >>> I am pretty fluent with package dependencies and so if I cannot
> >>> figure it out in an acceptable time frame then who will.
> >>
> >> Stop whining and start reading, please.
> >>
> >>> Any pointers on how to get this working would be very much
> >>> appreciated.
> >>
> >> The version of Fling is 0.0.1-SNAPSHOT which clearly indicates that it is
> >> work in progress. Fling itself depends on some snapshots namely
> >> Validation and Messaging (and therefore has to be adjusted sometimes
> >> when those dependencies do incompatible changes – see my latest
> >> commits). Fling's prerequisites are listed in the README:
> >> https://github.com/apache/sling/tree/trunk/samples/fling
> >>
> >> How to install Scripting Thymeleaf is described in its README (and btw.
> >> Jackson is optional):
> >> https://github.com/apache/sling/tree/trunk/contrib/scripting/org.apache.s
> >> ling.scripting.thymeleaf
> >>
> >> If you are unable to install those dependencies into Launchpad you can
> >> try
> >> with Sling's Karaf Distribution:
> >> https://github.com/apache/sling/tree/trunk/karaf
> >>
> >> Start Karaf and open http://localhost:8181/system/console/features,
> >> install
> >> sling-launchpad-oak-tar and sling-samples-fling by clicking the
> >> play/install buttons on the right. Open http://localhost:8181/fling.html
> >>
> >> O.
> >>
> >>> Thanks - Andy Schaefer