Re: is there any way to user sling whithout OSGi

2008-09-05 Thread Bertrand Delacretaz
Hi,

On Sat, Sep 6, 2008 at 2:24 AM, Torgeir Veimo <[EMAIL PROTECTED]> wrote:
> On 6 Sep 2008, at 08:55, tung vu duc wrote:

>>... how to use sling whithout OSGi (without Felix).
>
> This will be hard. I'd figure it would be easier to leave felix in, it's not
> too large...

Sure, and I don't think the Sling community is willing to support
non-OSGi setups at this time. We like it too much ;-)

Reusing specific parts of Sling outside of the OSGi world, however, is
certainly possible. But in general, you need OSGi to use Sling, and
that's where our focus is, as a community.

>> ...I think, the most developers, who would like to use sling, will integrate
>> it into their own web app but do't use sling alone, whithout a server-side
>> web framwork. For a normal web app is sling with Felix too heavy and
>> complex

Depends on what a "normal" webapp is. Lots of Sling use cases don't
require any OSGi knowledge, you can go a long way just with scripting
in the repository. What kind of server-side web framework would you
use with Sling? You don't need any, unless I misunderstand the term.

And quite frankly, creating pluggable Sling servlets or components is
not that hard using the supplied Maven plugins. And there are other
ways that are not hard if you don't want to use Maven.

> ...Secondly, sling can be set up to use an existing repository, there was some
> hints provided on the mailing list, but I don't remember the subject lines.
> Searching the mailing list should give some pointers

Replacing the jacrkabbit-server bundle by the jackrabbit-client one,
and configuring that with the repository access parameters, should be
enough for that.

-Bertrand


Re: is there any way to user sling whithout OSGi

2008-09-05 Thread Torgeir Veimo


On 6 Sep 2008, at 08:55, tung vu duc wrote:


Hi cool Day Software developers,


Am answering as a mere user, not related to Day..


how to use sling whithout OSGi (without Felix).


This will be hard. I'd figure it would be easier to leave felix in,  
it's not too large.


I think, the most developers, who would like to use sling, will  
integrate it into their own web app but do't use sling alone,  
whithout a server-side web framwork. For a normal web app is sling  
with Felix too heavy and complex.


It's certainly possible to integrate into an existing webapp. You can  
extract the guts of the war file and embed into yours. The issue I  
think it to get a resource provider set up that can serve resources  
from the webapp, in addition to the sling repository, this would allow  
JSP files to reside in their usual places in your legacy applications  
WAR file.


A file system resource provider has already been implemented and is in  
the samples directory of the sling source. I believe this can be  
modified to use the servlet context getResource() method instead of  
using the filesystem directly. Search the mailing list for SLING-583  
to see some discussion on this topic and how to set up.


Secondly, sling can be set up to use an existing repository, there was  
some hints provided on the mailing list, but I don't remember the  
subject lines. Searching the mailing list should give some pointers.


--
Torgeir Veimo
[EMAIL PROTECTED]






Re: How do I create a Ruby template?

2008-09-05 Thread Joshua Oransky

Thanks! That worked!

On Sep 2, 2008, at 11:52 PM, Bertrand Delacretaz wrote:


Hi,

On Wed, Sep 3, 2008 at 3:39 AM, Joshua Oransky <[EMAIL PROTECTED]>  
wrote:

...When I run mvn -P autoInstallBundle
-Dsling.url=http://localhost:8080/ctx/system/console clean install  
I get a

build error. Nothing shows up in the $sling.home/logs/error.log...


Looks like your sling.url is wrong, if you open it from a browser you
should see the OSGi console. I guess the correct one is
http://localhost:8080/system/console


... [INFO] Installing Bundle
org.apache.sling.scripting.ruby(/Users/joshuaoransky/Downloads/ 
slingsrc/sling/scripting/ruby/target/ 
org.apache.sling.scripting.ruby-2.0.0-incubator-SNAPSHOT.jar)

to http://localhost:8080/ctx/system/console
[ERROR] Installation failed, cause: Created...


I guess the install plugin gets a "created" HTTP response instead of
what it expects, which would be the case if using a wrong install URL:
in this case the SlingPostServlet will create a new node.

-Bertrand




is there any way to user sling whithout OSGi

2008-09-05 Thread tung vu duc
Hi cool Day Software developers,

With sling-lauchpad i have learn the first lessions about sling. i understand 
the concept of sling, how it ease the working with JCR.
But my question is now: how to use sling whithout OSGi (without Felix). Only 
request processing, script selection and scripting engine suffice for most
web apps. I think, the most developers, who would like to use sling, will 
integrate it into their own web app but do't use sling alone, whithout a 
server-side web framwork. For a normal web app is sling with Felix too heavy 
and complex.

To sum up all what i want to know:

- is there a version of sling-lauchpad without Felix?

and a tep better

- is there a version of sling-lauchpad whithout Felix and can be configured 
whit a existing repository. (dont use the buildin repository)


Thanks you all very much!



  


[jira] Closed: (SLING-640) Add provider for status information about timed events

2008-09-05 Thread Carsten Ziegeler (JIRA)

 [ 
https://issues.apache.org/jira/browse/SLING-640?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Carsten Ziegeler closed SLING-640.
--

Resolution: Fixed

Added a simple provider which can be queried for scheduled events and which can 
be used to cancel events.

> Add provider for status information about timed events
> --
>
> Key: SLING-640
> URL: https://issues.apache.org/jira/browse/SLING-640
> Project: Sling
>  Issue Type: Improvement
>  Components: Event
>Affects Versions: Extensions Event 2.0.2
>Reporter: Carsten Ziegeler
>Assignee: Carsten Ziegeler
> Fix For: Extensions Event 2.0.4
>
>
> Currently it is only possible to start and stop timed events (by sending 
> events)
> A new interface TimedEventStatusProvider should be added which allows to 
> query if something is scheduled.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



Re: How to beginn with Microsling

2008-09-05 Thread tung vu duc
super!, it's exactly what i need.

It's so cool how sling resolves the selection of the script to render requested 
content.

Do you plan to support .GSP und Groovy as scripting engine? I will be looking 
forward to. :-D

Thanks you very much!



- Original Message 
From: Torgeir Veimo <[EMAIL PROTECTED]>
To: sling-dev@incubator.apache.org
Sent: Friday, September 5, 2008 1:07:27 PM
Subject: Re: How to beginn with Microsling


On 5 Sep 2008, at 20:48, tung vu duc wrote:

> But i don't still understand how to beginn now. I have successful  
> builded sling (the whole from trunk) with maven. what modules of  
> whole sling should one need
> to have the functionaties of Microsling and how to integrate these  
> with a Jackrabbit Repo.


You can take the resulting sling war file and put it into any web  
container, eg tomcat. It contains the jackrabbit jars, and will  
automatically set up a repository, which will be available instantly,  
also via webdav. Then you can immediately put content and scripts into  
sling using eg curl.

Macintosh-3:sling torgeir$ find . -name "*.war"
./launchpad/testing/target/org.apache.sling.launchpad.testing-4- 
incubator-SNAPSHOT.war
./launchpad/webapp/target/org.apache.sling.launchpad.webapp-4- 
incubator-SNAPSHOT.war

Use the bottom one, and rename it eg. sling.war before adding it to  
tomcat. Your sling instance would then be available at 
http://localhost:8080/sling/

Check eg with http://localhost:8080/sling/system/console/bundles or  
try http://localhost:8080/sling/index.html

I guess you've already read 
http://incubator.apache.org/sling/site/discover-sling-in-15-minutes.html 
  ?

-- 
Torgeir Veimo
[EMAIL PROTECTED]


  


Re: How to beginn with Microsling

2008-09-05 Thread Torgeir Veimo


On 5 Sep 2008, at 20:48, tung vu duc wrote:

But i don't still understand how to beginn now. I have successful  
builded sling (the whole from trunk) with maven. what modules of  
whole sling should one need
to have the functionaties of Microsling and how to integrate these  
with a Jackrabbit Repo.



You can take the resulting sling war file and put it into any web  
container, eg tomcat. It contains the jackrabbit jars, and will  
automatically set up a repository, which will be available instantly,  
also via webdav. Then you can immediately put content and scripts into  
sling using eg curl.


Macintosh-3:sling torgeir$ find . -name "*.war"
./launchpad/testing/target/org.apache.sling.launchpad.testing-4- 
incubator-SNAPSHOT.war
./launchpad/webapp/target/org.apache.sling.launchpad.webapp-4- 
incubator-SNAPSHOT.war


Use the bottom one, and rename it eg. sling.war before adding it to  
tomcat. Your sling instance would then be available at http://localhost:8080/sling/


Check eg with http://localhost:8080/sling/system/console/bundles or  
try http://localhost:8080/sling/index.html


I guess you've already read http://incubator.apache.org/sling/site/discover-sling-in-15-minutes.html 
 ?


--
Torgeir Veimo
[EMAIL PROTECTED]






How to beginn with Microsling

2008-09-05 Thread tung vu duc
I have read some articles on dev.day.com about mircosling. It is really great 
web framewok, exactly for a content-centric web app.
But i don't still understand how to beginn now. I have successful builded sling 
(the whole from trunk) with maven. what modules of whole sling should one need
to have the functionaties of Microsling and how to integrate these with a 
Jackrabbit Repo.

These articles on dev.day.com show the cool concept of sling and microsling. 
But newbies need somewhat clear, complete and practical exampls to beginn.
I personally want to integrate microsling + jackrabbit into my Grails web app 
to ease the access, manage, versioning and event notifications of the contents.
So i really want to know how to beginn with microsling.

Thanks in advance!
Tung Vu



  


[jira] Created: (SLING-648) Make cache sizes configurable

2008-09-05 Thread Felix Meschberger (JIRA)
Make cache sizes configurable
-

 Key: SLING-648
 URL: https://issues.apache.org/jira/browse/SLING-648
 Project: Sling
  Issue Type: Improvement
  Components: Extensions
Affects Versions: Extensions Bundleresource 2.1.0
Reporter: Felix Meschberger
Assignee: Felix Meschberger
 Fix For: Extensions Bundleresource 2.1.0


SLING-641 adds caches to the BundleResourceProvider. These are currently fixed 
at a hard coded size (50 for the entry cache and 20 for the child list cache) . 
It would make sense to add configuration support for the cache sizes.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Closed: (SLING-641) Implement cache for bundle resources

2008-09-05 Thread Felix Meschberger (JIRA)

 [ 
https://issues.apache.org/jira/browse/SLING-641?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Felix Meschberger closed SLING-641.
---

Resolution: Fixed

JavaDoc is now added so I close this issue

> Implement cache for bundle resources
> 
>
> Key: SLING-641
> URL: https://issues.apache.org/jira/browse/SLING-641
> Project: Sling
>  Issue Type: Bug
>  Components: Extensions
>Affects Versions: Extensions Bundleresource 2.0.2
>Reporter: Felix Meschberger
>Assignee: Felix Meschberger
> Fix For: Extensions Bundleresource 2.1.0
>
>
> When accessing bundle resources, the BundleResourceProvider currently 
> accesses the bundle for each check, which in turn accesses and lock sthe 
> bundle jar file.
> A simple cache should be built into the BundleResourceProvider to cache 
> resources found for faster access on future access. This cache should be 
> limited and on a per-bundle level, such that the cache may simply be dropped 
> if the bundle is stopped.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Closed: (SLING-644) Add a Felix Web Console plugin the bundle resource provider

2008-09-05 Thread Felix Meschberger (JIRA)

 [ 
https://issues.apache.org/jira/browse/SLING-644?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Felix Meschberger closed SLING-644.
---

Resolution: Fixed

This can be closed for now with the first implementation

> Add a Felix Web Console plugin the bundle resource provider
> ---
>
> Key: SLING-644
> URL: https://issues.apache.org/jira/browse/SLING-644
> Project: Sling
>  Issue Type: Improvement
>  Components: Extensions
>Reporter: Felix Meschberger
>Assignee: Felix Meschberger
> Fix For: Extensions Bundleresource 2.1.0
>
>
> For easy overview of the state of the bundle resource provider services 
> registered in the system, a simple plugin for the Felix Web Console should be 
> developed.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.



[jira] Closed: (SLING-643) The LogSupport.fireLogEvent should deliver LogEvents to listeners asynchronously

2008-09-05 Thread Felix Meschberger (JIRA)

 [ 
https://issues.apache.org/jira/browse/SLING-643?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Felix Meschberger closed SLING-643.
---

Resolution: Fixed

Implemented asynchronous LogEvent delivery in Rev. 692355.

> The LogSupport.fireLogEvent should deliver LogEvents to listeners 
> asynchronously
> 
>
> Key: SLING-643
> URL: https://issues.apache.org/jira/browse/SLING-643
> Project: Sling
>  Issue Type: Bug
>  Components: Commons Log
>Affects Versions: Commons Log 2.0.2
>Reporter: Felix Meschberger
>Assignee: Felix Meschberger
> Fix For: Commons Log 2.0.4
>
>
> Currently the LogSupport.fireLogEvent notifies registered LogListeners 
> synchronously during the call the to the LogService.log method. According to 
> Section 101.4, Log Reader Service, of the OSGi Service Compendium 
> specification, the delivery of events to LogListeners is recommended to be 
> done asynchronously:
>"The delivery of LogEntry objects to the LogListener
>   object should be done asynchronously"
> This should enhance the performance of the LogService.log calls dramatically.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.