You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by Torgeir Veimo <to...@pobox.com> on 2009/01/01 14:05:13 UTC

default node type for webdav collections

When mounting the sling webdav servlet in os x finder, creating  
directories result in them having primaryNodetype set to nt:folder.  
The docs indicates that the default type is configured to be  
sling:Folder, but I cannot find this setting when looking in the felix  
console. Do I need to add this configuration myself?

-- 
Torgeir Veimo
torgeir@pobox.com





Re: default node type for webdav collections

Posted by Felix Meschberger <fm...@gmail.com>.
Hi,

Torgeir Veimo schrieb:
> 
> On 3 Jan 2009, at 04:58, Felix Meschberger wrote:
> 
>> Torgeir Veimo schrieb:
>>>
>>> Do you know when? I have sling trunk from a few days ago running. Where
>>
>> Rev. 725679 dates from the 11. Dec. 2008.
> 
> If I take the current sling svn trunk code, do a mvn install in the
> root, then a mvn install in launchpad/webapp, then use the resulting war
> file in the target directory, then I should get the latest sling trunk
> code?

Yes. Note, though, that if you run this latest applications using an
existing ${sling.home} folder, the newest bundles will only be installed
if you remove the existing ${sling.home}/felix folder first.

(Or more specifically: if you remove the
${sling.home}/felix/bundle0/bootstrapinstaller.ser file and all Sling
bundles before starting the new Sling (web) app)

> 
>>> is the correct way to configure this manually? I had a look at the
>>> configuration settings for the webdav servlet, but I couldn't find any
>>> setting for the default node type.
>>
>> The configuration to look for is "Simple WebDAV Servlet
>> (org.apache.sling.jcr.webdav.impl.servlets.SimpleWebDavServlet)". This
>> should provide a whole lot of options. One of which is the "Collection
>> Primary Type" option, which defaults to sling:Folder.
> 
> 
> The simple webdav servlet configuration only has options for the
> authentication realm and the root path. Am a bit at a loss here..
> 

This means the newest WebDAV bundle is not being used.

Please note (I only realized yesterday), that the news WebDAV bundle has
a required dependency on the org.apache.jackrabbit.jsr283 package. This
package is available from the Jackrabbit API 1.5.0 bundle [1] which must
be deployed. (When building and running Sling from trunk, you should get
this bundle installed already)

After refreshing the packages (or redeploying the WebDAV bundle), the
new configuration should be available. You might also want to inspect
the log file (${sling.home}/log/error.log by default) for any errors.

Hope this helps.

Regards
Felix

Re: default node type for webdav collections

Posted by Felix Meschberger <fm...@gmail.com>.
Hi,

Torgeir Veimo schrieb:
> 
> On 3 Jan 2009, at 20:35, Bertrand Delacretaz wrote:
> 
>> Hi,
>>
>> On Sat, Jan 3, 2009 at 7:09 AM, Torgeir Veimo <to...@pobox.com> wrote:
>>> ...If I take the current sling svn trunk code, do a mvn install in
>>> the root,
>>> then a mvn install in launchpad/webapp, then use the resulting war
>>> file in
>>> the target directory, then I should get the latest sling trunk code?...
>>
>> Yes, but the launchpad app and webapp modules do not necessarily use
>> snapshot versions of all bundles, some dependencies are still on the
>> released versions of bundles.
>>>
> 
> Ok, so launchpad != latest trunk.

Hmm, I would consider this a "bug", then.

Thanks, Bertrand for fixing this.


> What is the easiest way to run the
> latest modules?

Launchpad should really get you the latest modules - unless launchpad is
not updated for the latest modules. In this case it was mea culpa, sorry.

> 
>> Note that you could also have updated the org.apache.sling.jcr.webdav
>> bundle manually after starting the launchpad webapp, for example by
>> building the webapp bundle using
>>
>>  mvn -P autoInstallBundle clean install -D
>> sling.url=http://localhost:8888/system/console
> 
> 
> Thank you! running this command in jcr/webdav fixed my problem!
> 

Great ! Good to hear.

Regards
Felix

Re: default node type for webdav collections

Posted by Torgeir Veimo <to...@pobox.com>.
On 3 Jan 2009, at 20:35, Bertrand Delacretaz wrote:

> Hi,
>
> On Sat, Jan 3, 2009 at 7:09 AM, Torgeir Veimo <to...@pobox.com>  
> wrote:
>> ...If I take the current sling svn trunk code, do a mvn install in  
>> the root,
>> then a mvn install in launchpad/webapp, then use the resulting war  
>> file in
>> the target directory, then I should get the latest sling trunk  
>> code?...
>
> Yes, but the launchpad app and webapp modules do not necessarily use
> snapshot versions of all bundles, some dependencies are still on the
> released versions of bundles.
>>

Ok, so launchpad != latest trunk. What is the easiest way to run the  
latest modules?

> Note that you could also have updated the org.apache.sling.jcr.webdav
> bundle manually after starting the launchpad webapp, for example by
> building the webapp bundle using
>
>  mvn -P autoInstallBundle clean install -D
> sling.url=http://localhost:8888/system/console


Thank you! running this command in jcr/webdav fixed my problem!

-- 
Torgeir Veimo
torgeir@pobox.com





Re: default node type for webdav collections

Posted by Bertrand Delacretaz <bd...@apache.org>.
Hi,

On Sat, Jan 3, 2009 at 7:09 AM, Torgeir Veimo <to...@pobox.com> wrote:
> ...If I take the current sling svn trunk code, do a mvn install in the root,
> then a mvn install in launchpad/webapp, then use the resulting war file in
> the target directory, then I should get the latest sling trunk code?...

Yes, but the launchpad app and webapp modules do not necessarily use
snapshot versions of all bundles, some dependencies are still on the
released versions of bundles.

> ...The simple webdav servlet configuration only has options for the
> authentication realm and the root path. Am a bit at a loss here.....

The launchpad/webapp was using the 2.0.2.incubator version of the
org.apache.sling.jcr.webdav bundle, as can be verified by looking at
the bundle details from the OSGi console.

I have fixed this in the launchpad/app module, which is used to build
launchpad/webapp. Rebuilding revision 730968 as you did should now get
you the webdav bundle from trunk.

Note that you could also have updated the org.apache.sling.jcr.webdav
bundle manually after starting the launchpad webapp, for example by
building the webapp bundle using

  mvn -P autoInstallBundle clean install -D
sling.url=http://localhost:8888/system/console

The bundles that are embedded in the war file are only used for the
initial installation, but if you update them manually after startup
the updated versions are permantently stored in the sling.home folder.

-Bertrand

Re: default node type for webdav collections

Posted by Torgeir Veimo <to...@pobox.com>.
On 3 Jan 2009, at 04:58, Felix Meschberger wrote:

> Torgeir Veimo schrieb:
>>
>> Do you know when? I have sling trunk from a few days ago running.  
>> Where
>
> Rev. 725679 dates from the 11. Dec. 2008.

If I take the current sling svn trunk code, do a mvn install in the  
root, then a mvn install in launchpad/webapp, then use the resulting  
war file in the target directory, then I should get the latest sling  
trunk code?

>> is the correct way to configure this manually? I had a look at the
>> configuration settings for the webdav servlet, but I couldn't find  
>> any
>> setting for the default node type.
>
> The configuration to look for is "Simple WebDAV Servlet
> (org.apache.sling.jcr.webdav.impl.servlets.SimpleWebDavServlet)". This
> should provide a whole lot of options. One of which is the "Collection
> Primary Type" option, which defaults to sling:Folder.


The simple webdav servlet configuration only has options for the  
authentication realm and the root path. Am a bit at a loss here..

-- 
Torgeir Veimo
torgeir@pobox.com





Re: default node type for webdav collections

Posted by Felix Meschberger <fm...@gmail.com>.
Hi Torgeir,

Torgeir Veimo schrieb:
> 
> On 2 Jan 2009, at 00:22, Felix Meschberger wrote:
> 
>> Functionality to easily configure the node types used is only available
>> with the jcr/webdav bundle as of Rev. 725679 (as per SLING-767). Using a
>> top of trunk build of the module should give you the configuration
>> option in the felix console Configuration page.
>>
>> It has IIRC also only recently been implemented, that the default node
>> type for folders is sling:Folder.
> 
> Do you know when? I have sling trunk from a few days ago running. Where

Rev. 725679 dates from the 11. Dec. 2008.

> is the correct way to configure this manually? I had a look at the
> configuration settings for the webdav servlet, but I couldn't find any
> setting for the default node type.

The configuration to look for is "Simple WebDAV Servlet
(org.apache.sling.jcr.webdav.impl.servlets.SimpleWebDavServlet)". This
should provide a whole lot of options. One of which is the "Collection
Primary Type" option, which defaults to sling:Folder.

Regards
Felix

> 

Re: default node type for webdav collections

Posted by Torgeir Veimo <to...@pobox.com>.
On 2 Jan 2009, at 00:22, Felix Meschberger wrote:

> Functionality to easily configure the node types used is only  
> available
> with the jcr/webdav bundle as of Rev. 725679 (as per SLING-767).  
> Using a
> top of trunk build of the module should give you the configuration
> option in the felix console Configuration page.
>
> It has IIRC also only recently been implemented, that the default node
> type for folders is sling:Folder.

Do you know when? I have sling trunk from a few days ago running.  
Where is the correct way to configure this manually? I had a look at  
the configuration settings for the webdav servlet, but I couldn't find  
any setting for the default node type.

-- 
Torgeir Veimo
torgeir@pobox.com





Re: default node type for webdav collections

Posted by Felix Meschberger <fm...@gmail.com>.
Hi Torgeir,

Torgeir Veimo schrieb:
> When mounting the sling webdav servlet in os x finder, creating
> directories result in them having primaryNodetype set to nt:folder. The
> docs indicates that the default type is configured to be sling:Folder,
> but I cannot find this setting when looking in the felix console. Do I
> need to add this configuration myself?

Functionality to easily configure the node types used is only available
with the jcr/webdav bundle as of Rev. 725679 (as per SLING-767). Using a
top of trunk build of the module should give you the configuration
option in the felix console Configuration page.

It has IIRC also only recently been implemented, that the default node
type for folders is sling:Folder.

So upgrading to a top-of-trunk build should do the trick for you.

Regards
Felix