Thanks Vidar, that works great. When mapping the filesystem I don't
have the delay issue (tested with esp) any longer.

Any other tip for the dev environment? ;-)

Regards,
 Markus

On Fri, Jan 7, 2011 at 10:08 AM, Vidar Ramdal <[email protected]> wrote:
> On Thu, Jan 6, 2011 at 10:12 PM, Markus Joschko
> <[email protected]> wrote:
>> Hi,
>> I decided to build a prototype using sling.
>> Currently I wonder about the best practice to edit the esp/jsp files.
>>
>> As I don't want to create a bundle and upload it everytime I make a
>> small change in the scripts,
>> I have mapped the repository via webdav and modify the scripts directly.
>>
>> But I  notice a delay of 10 seconds before the change gets picked up.
>> Can this be configured? Or is this a limitation of the webdav driver?
>> How do you edit your scripts?
>
> I usually map the scripts folder as a FsResource. Install the
> org.apache.sling.fsresource bundle, and you'll be able to map a file
> system directory directly into the Sling resource tree. Thus, you
> don't have to deal with WebDav.
>
> The FsResource mappings can also be automatically created by the Sling
> Maven plugin. I have the following in my pom.xml:
> <profiles>
>        <profile>
>            <id>dev</id>
>            <build>
>                <plugins>
>                    <plugin>
>                        <groupId>org.apache.felix</groupId>
>                        <artifactId>maven-bundle-plugin</artifactId>
>                        <extensions>true</extensions>
>                        <configuration>
>                            <instructions>
>
> <Bundle-Category>com.idium.kolibri</Bundle-Category>
>
> <Bundle-SymbolicName>kolibri-files</Bundle-SymbolicName>
>                                <Sling-Initial-Content>
>
> apps;overwrite:=true;uninstall:=true;path:=/apps,
>
> templates;overwrite:=true;uninstall:=true;path:=/templates
>                                </Sling-Initial-Content>
>                            </instructions>
>                        </configuration>
>                    </plugin>
>                    <plugin>
>                        <groupId>org.apache.sling</groupId>
>                        <artifactId>maven-sling-plugin</artifactId>
>                        <executions>
>                            <execution>
>                                <id>install-bundle</id>
>                                <goals>
>                                    <goal>validate</goal>
>                                    <goal>install</goal>
>                                </goals>
>                                <configuration>
>                                    <skip>false</skip>
>                                    <mountByFS>true</mountByFS> <!--
> This causes the paths specified as Sling-Initial-Content to be mapped
> to file system directories. Make sure you have installed
> o.a.s.fsresource first.  -->
>                                </configuration>
>                            </execution>
>                        </executions>
>                    </plugin>
>
>                </plugins>
>
>            </build>
>        </profile>
>
> </profiles>
>
> When activating this profile (mvn install -Pdev) the file system
> mappings are automatically created for me.
>
> --
> Vidar S. Ramdal <[email protected]> - http://www.idium.no
> Sommerrogata 13-15, N-0255 Oslo, Norway
> + 47 22 00 84 00 / +47 22 00 84 76
> Quando omni flunkus moritatus!
>

Reply via email to