> Vidar Ramdal wrote:
>> The maven-sling-plugin has the very useful feature mountByFS, which
>> automatically sets up FsResourceProviders for the initial-content in
>> the bundle.
>> This is great for development, as you can work directly on the files
>> in the bundle, without having to re-deploy the bundle for each change.
>>
>> However, the mountByFS feature relies on the Sling-Initial-Content
>> header to decide which paths should be mapped. This crashes with the
>> Sling Content Loader bundle, which also looks for that header. So, if
>> the Content Loader bundle is active when you deploy a bundle with
>> mountByFS, you'll end up with both FsResourceProviders AND initial
>> content in the repository. This defies the purpose of mountByFS, and
>> usually also leads to some unexpected behavior in resource resolution.

On Wed, Jan 6, 2010 at 2:29 PM, Carsten Ziegeler <[email protected]> wrote:
> [...]
> My usual development environment uses this feature together with initial
> content headers and so far I never experienced a problem - it is true
> that the content is also installed into the repository but the resources
> mounted through the fs provider take precedence - at least they do it in
> my case :)

That's useful information. I just took for granted that mountByFS and
the content loader combination was not particularly common. I'll keep
an eye open next time I deploy, to try to see exactly what fails.

>> So how about letting maven-sling-plugin support another config element
>> in addition to Sling-Initial-Content, say, Sling-Mount-File-Resources.
>> That way, the Content Loader bundle should not interfere when the
>> mountByFS bundle is deployed.

> I'm not against adding an additonal configuration element for this
> purpose. I started with the initial content header as this was already
> available and used :)
>
> Now, I think we should a) add the additional config element and b) see
> which problems you have when the initial content header is used. Maybe
> we can fix them as well.

Great. As I said, I'll gather some more details on b). Nonetheless, I
too believe it would be useful to have a method of just installing
FsResourceProviders without loading the content, if only to reduce the
time it takes to deploy. So a) =>
https://issues.apache.org/jira/browse/SLING-1271


-- 
Vidar S. Ramdal <[email protected]> - http://www.idium.no
Sommerrogata 13-15, N-0255 Oslo, Norway
+ 47 22 00 84 00 / +47 21 531941, ext 2070

Reply via email to