You are viewing a plain text version of this content. The canonical link for it is here.
Posted to slide-user@jakarta.apache.org by Ashikuzzaman <az...@hotmail.com> on 2004/01/24 20:15:10 UTC

FileContentStore disappers?!?

Dear List,
 
I am using Slide 1.0.16 as the nightly build 2.0 is, I am not sure, whether
I can use right now. I copied the necessary jar files in my webapp's
web-inf\lib dir and modified the Domain.xml file to use in Tomcat 4.1.27 and
Resin 2.1 with allowing guests to do all actions in contentStore dir. Now
when I copy files from file system through Windows XP Web Folders
functionality to the contentStore that I defined in the domain.xml file it
seems to work fine. I can even check that the file I copied, physically
exists. I can copy or download it but can't move, delete, rename or create
new folder. What's the problem? Anything about user privilege? My clients
should be able to add new and new files daily, so I have to allow them
modify those file, create new directories under the contentStore rootpath.
How can I do these using slide? Should I override slide's WebdavServlet?
Then which methods to override? Here is the Domain.xml file ---

<?xml version="1.0"?>
<slide logger="org.apache.slide.util.logger.SimpleLogger" logger-level="6"
default="biscomWebdav">
<!--
logger
~~~~~~
org.apache.slide.util.logger.SimpleLogger 
   default logger with 1 log level
log4j.Log4jLogger 
   logger with fine granularity
   see http://jakarta.apache.org/log4j/
logger-level 
~~~~~~~~~~~~
0 EMERGENCY
1 CRITICAL
2 ERROR
4 WARNING
6 INFO
7 DEBUG
-->
  <namespace name="biscomWebdav">
<!-- ### Memory Configuration ###
     The following memory configuration uses the MemoryDescriptorsStore
     for node,security,locks and revisions. For content the FileContentStore
     is used. Content is not reset before start. Database may also be used
instead.
-->
    <definition>
      <store name="contentStore">
        <nodestore classname="slidestore.reference.MemoryDescriptorsStore">
        </nodestore>
        <securitystore>
          <reference store="nodestore" />
        </securitystore>
        <lockstore>
          <reference store="nodestore" />
        </lockstore>
        <revisiondescriptorsstore>
          <reference store="nodestore" />
        </revisiondescriptorsstore>
        <contentstore classname="slidestore.reference.FileContentStore">
          <parameter
name="rootpath">C:/winxpsoft/javaGroup/resin-2.1.12/webapps/biscomWebdav/con
tentStore</parameter>
          <parameter name="version">false</parameter>
          <parameter name="resetBeforeStarting">true</parameter>
        </contentstore>
      </store>
      <scope match="/" store="contentStore" />
    </definition>

    <configuration>
      <!-- Actions mapping -->
      <default-action>/actions</default-action>
      <read-object>/actions/read</read-object>
      <create-object>/actions/write</create-object>
      <remove-object>/actions/write</remove-object>
      <grant-permission>/actions/manage</grant-permission>
      <revoke-permission>/actions/manage</revoke-permission>
      <read-permissions>/actions/manage</read-permissions>
      <lock-object>/actions/write</lock-object>
      <kill-lock>/actions/manage</kill-lock>
      <read-locks>/actions/read</read-locks>
      <read-revision-metadata>/actions/read</read-revision-metadata>
      <create-revision-metadata>/actions/write</create-revision-metadata>
      <modify-revision-metadata>/actions/write</modify-revision-metadata>
      <remove-revision-metadata>/actions/write</remove-revision-metadata>
      <read-revision-content>/actions/read</read-revision-content>
      <create-revision-content>/actions/write</create-revision-content>
      <modify-revision-content>/actions/write</modify-revision-content>
      <remove-revision-content>/actions/write</remove-revision-content>
      <!-- Paths configuration -->
      <userspath>/users</userspath>
      <guestpath>guest</guestpath>
      <filespath>/files</filespath>
      <parameter name="dav">true</parameter>
      <parameter name="standalone">true</parameter>
      <!-- Roles definition -->
      <role name="root">slideroles.basic.RootRole</role>
      <role name="user">slideroles.basic.UserRole</role>
      <role name="guest">slideroles.basic.GuestRole</role>
      <!-- Users management -->
      <auto-create-users>false</auto-create-users>
      <!-- Default properties mapping -->
      <default-property name="provider" namespace="biscomWebdav/"
value="SurroundApps" role="user"/>
      <default-property name="pass" namespace="biscomWebdav/" value=""
role="user"/>
    </configuration>
    
    <data>     
      <objectnode classname="org.apache.slide.structure.SubjectNode"
uri="/">
        <!-- Subject can be:
                self  "~"
                all   "nobody"
                user  "/users/john"
                group "+/users/groupA"
                role  "root"
        -->               
        <!-- Uncomment the following line to give all permissions to 
             principals have the root role -->
        <permission action="/actions" subject="root"/>
        <permission action="/actions" subject="/users/root"/>
        <permission action="/actions/read" subject="/users"
inheritable="false"/>
        <permission action="/actions/read" subject="nobody"
inheritable="false"/>        
        <!-- /users -->        
        <objectnode classname="org.apache.slide.structure.SubjectNode"
uri="/users">          
		  <permission action="/actions" subject="~"/>
		  <permission action="/actions" subject="/users/guest"
inheritable="true" negative="false"/>
			 <!-- by default, it was true -->
		  <permission action="/actions/read" subject="/users"
inheritable="false"/>
		  <!-- Permission group example -->
          <objectnode classname="org.apache.slide.structure.GroupNode"
uri="/users/groupA">
             <objectnode classname="org.apache.slide.structure.LinkNode"
uri="/users/groupA/john" linkedUri="/users/john" />
             <objectnode classname="org.apache.slide.structure.LinkNode"
uri="/users/groupA/ashik" linkedUri="/users/ashik" />
             <objectnode classname="org.apache.slide.structure.LinkNode"
uri="/users/groupA/root" linkedUri="/users/root" />
             <objectnode classname="org.apache.slide.structure.SubjectNode"
uri="/users/groupA/singleGroupMember"  />
          </objectnode>
          <!-- /users/root represents the administrator -->          
          <objectnode classname="slideroles.basic.RootRoleImpl"
uri="/users/root">
            <revision>
              <property name="password">root</property>
            </revision>
          </objectnode>          
          <!-- /users/john represents an authenticated user -->         
          <objectnode classname="slideroles.basic.UserRoleImpl"
uri="/users/john">
            <revision>
              <property name="password">john</property>
            </revision>
          </objectnode>          
          <!-- /users/ashik represents an authenticated user -->         
          <objectnode classname="slideroles.basic.UserRoleImpl"
uri="/users/ashik">
            <revision>
              <property name="password">ashik</property>
            </revision>
          </objectnode>
          <!-- /users/guest represents an authenticated or unauthenticated
guest user -->          
          <objectnode classname="slideroles.basic.GuestRoleImpl"
uri="/users/guest">
            <revision>
              <property name="password"></property>
            </revision>
          </objectnode>          
        </objectnode>        
        <objectnode classname="org.apache.slide.structure.ActionNode"
uri="/actions">          
          <objectnode classname="org.apache.slide.structure.ActionNode"
uri="/actions/read"/>          
          <objectnode classname="org.apache.slide.structure.ActionNode"
uri="/actions/write"/>          
          <objectnode classname="org.apache.slide.structure.ActionNode"
uri="/actions/manage"/>          
        </objectnode>        
        <objectnode classname="org.apache.slide.structure.SubjectNode"
uri="/files">
          <!-- ### Give read/write/manage permission to guest ### 
               Uncomment the following line to give permission to do
               all actions on /files to guest (unauthenticated users) -->
          <!-- <permission action="/actions" subject="/users/guest"/> -->
          <permission action="/actions/manage" subject="/users/john"/>
          <permission action="/actions/write" subject="+/users/groupA"/>
          <permission action="/actions/read" subject="nobody"/>          
        </objectnode>        
        <objectnode classname="org.apache.slide.structure.SubjectNode"
uri="/documents">
          <!-- ### Give read/write/manage permission to guest ### 
               Uncomment the following line to give permission to do
               all actions on /docs to guest (unauthenticated users) -->
          <permission action="/actions" subject="/users/guest"/>
          <permission action="/actions" subject="/users/ashik"/>
          <!--permission action="/actions/manage" subject="/users/ashik"/>
          <permission action="/actions/write" subject="/users/ashik"/>
          <permission action="/actions/read" subject="/users/ashik"/-->

        </objectnode>
        <objectnode classname="org.apache.slide.structure.SubjectNode"
uri="/emails">
          <permission action="/actions" subject="/users/guest"/>
          <permission action="/actions" subject="/users/ashik"/>
        </objectnode>
        <objectnode classname="org.apache.slide.structure.SubjectNode"
uri="/faxes">
          <permission action="/actions" subject="/users/guest"/>
          <permission action="/actions" subject="/users/ashik"/>
        </objectnode>        
      </objectnode>      
    </data>    
  </namespace>  
</slide>
	
When I restart my server, I find all the newly uploaded files are gone, but
when I physically check it in file system, I see they are present there. :-(
I made sure that "resetBeforeStarting" is set to "false" (I tried with the
value "true" also). What can I do to solve this problem?

I would appreciate your comments here.

Regards,
 
Muhammad Ashikuzzaman (Fahim)
Software Engineer, SurroundApps Inc.

---------------------------------------------------------------------
To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-user-help@jakarta.apache.org


RE: FileContentStore disappers?!?

Posted by Ashikuzzaman <az...@hotmail.com>.
Dear K.C., thanks but I pointed out that in my email. I made sure that
resetBeforeStarting was set to "false". Here is what I wrote ---- 

>>When I restart my server, I find all the newly uploaded files are gone, 
>>but when I physically check it in file system, I see they are present 
>>there. :-( I made sure that "resetBeforeStarting" is set to "false" (I 
>>tried with the value "true" also). What can I do to solve this problem?

Any other guess? :-(

Regards,
 
Muhammad Ashikuzzaman (Fahim)
Senior Software Engineer, SurroundApps Inc.


-----Original Message-----
From: K.C. Baltz [mailto:kc.baltz@firefox.co.uk] 
Sent: Sunday, January 25, 2004 7:45 AM
To: Slide Users Mailing List
Subject: Re: FileContentStore disappers?!?

I suspect you want to change the parameter "resetBeforeStarting".  If it's
set to true, it will delete the contents of your file store every time you
restart Slide.

K.C.

Ashikuzzaman wrote:

>Dear List,
> 
>I am using Slide 1.0.16 as the nightly build 2.0 is, I am not sure, 
>whether I can use right now. I copied the necessary jar files in my 
>webapp's web-inf\lib dir and modified the Domain.xml file to use in 
>Tomcat 4.1.27 and Resin 2.1 with allowing guests to do all actions in 
>contentStore dir. Now when I copy files from file system through 
>Windows XP Web Folders functionality to the contentStore that I defined 
>in the domain.xml file it seems to work fine. I can even check that the 
>file I copied, physically exists. I can copy or download it but can't 
>move, delete, rename or create new folder. What's the problem? Anything 
>about user privilege? My clients should be able to add new and new 
>files daily, so I have to allow them modify those file, create new
directories under the contentStore rootpath.
>How can I do these using slide? Should I override slide's WebdavServlet?
>Then which methods to override? Here is the Domain.xml file ---
>
><?xml version="1.0"?>
><slide logger="org.apache.slide.util.logger.SimpleLogger" logger-level="6"
>default="biscomWebdav">
><!--
>logger
>~~~~~~
>org.apache.slide.util.logger.SimpleLogger 
>   default logger with 1 log level
>log4j.Log4jLogger 
>   logger with fine granularity
>   see http://jakarta.apache.org/log4j/ logger-level ~~~~~~~~~~~~ 0 
>EMERGENCY
>1 CRITICAL
>2 ERROR
>4 WARNING
>6 INFO
>7 DEBUG
>-->
>  <namespace name="biscomWebdav">
><!-- ### Memory Configuration ###
>     The following memory configuration uses the MemoryDescriptorsStore
>     for node,security,locks and revisions. For content the
FileContentStore
>     is used. Content is not reset before start. Database may also be 
>used instead.
>-->
>    <definition>
>      <store name="contentStore">
>        <nodestore classname="slidestore.reference.MemoryDescriptorsStore">
>        </nodestore>
>        <securitystore>
>          <reference store="nodestore" />
>        </securitystore>
>        <lockstore>
>          <reference store="nodestore" />
>        </lockstore>
>        <revisiondescriptorsstore>
>          <reference store="nodestore" />
>        </revisiondescriptorsstore>
>        <contentstore classname="slidestore.reference.FileContentStore">
>          <parameter
>name="rootpath">C:/winxpsoft/javaGroup/resin-2.1.12/webapps/biscomWebda
>v/con
>tentStore</parameter>
>          <parameter name="version">false</parameter>
>          <parameter name="resetBeforeStarting">true</parameter>
>        </contentstore>
>      </store>
>      <scope match="/" store="contentStore" />
>    </definition>
>
>    <configuration>
>      <!-- Actions mapping -->
>      <default-action>/actions</default-action>
>      <read-object>/actions/read</read-object>
>      <create-object>/actions/write</create-object>
>      <remove-object>/actions/write</remove-object>
>      <grant-permission>/actions/manage</grant-permission>
>      <revoke-permission>/actions/manage</revoke-permission>
>      <read-permissions>/actions/manage</read-permissions>
>      <lock-object>/actions/write</lock-object>
>      <kill-lock>/actions/manage</kill-lock>
>      <read-locks>/actions/read</read-locks>
>      <read-revision-metadata>/actions/read</read-revision-metadata>
>      <create-revision-metadata>/actions/write</create-revision-metadata>
>      <modify-revision-metadata>/actions/write</modify-revision-metadata>
>      <remove-revision-metadata>/actions/write</remove-revision-metadata>
>      <read-revision-content>/actions/read</read-revision-content>
>      <create-revision-content>/actions/write</create-revision-content>
>      <modify-revision-content>/actions/write</modify-revision-content>
>      <remove-revision-content>/actions/write</remove-revision-content>
>      <!-- Paths configuration -->
>      <userspath>/users</userspath>
>      <guestpath>guest</guestpath>
>      <filespath>/files</filespath>
>      <parameter name="dav">true</parameter>
>      <parameter name="standalone">true</parameter>
>      <!-- Roles definition -->
>      <role name="root">slideroles.basic.RootRole</role>
>      <role name="user">slideroles.basic.UserRole</role>
>      <role name="guest">slideroles.basic.GuestRole</role>
>      <!-- Users management -->
>      <auto-create-users>false</auto-create-users>
>      <!-- Default properties mapping -->
>      <default-property name="provider" namespace="biscomWebdav/"
>value="SurroundApps" role="user"/>
>      <default-property name="pass" namespace="biscomWebdav/" value=""
>role="user"/>
>    </configuration>
>    
>    <data>     
>      <objectnode classname="org.apache.slide.structure.SubjectNode"
>uri="/">
>        <!-- Subject can be:
>                self  "~"
>                all   "nobody"
>                user  "/users/john"
>                group "+/users/groupA"
>                role  "root"
>        -->               
>        <!-- Uncomment the following line to give all permissions to 
>             principals have the root role -->
>        <permission action="/actions" subject="root"/>
>        <permission action="/actions" subject="/users/root"/>
>        <permission action="/actions/read" subject="/users"
>inheritable="false"/>
>        <permission action="/actions/read" subject="nobody"
>inheritable="false"/>        
>        <!-- /users -->        
>        <objectnode classname="org.apache.slide.structure.SubjectNode"
>uri="/users">          
>		  <permission action="/actions" subject="~"/>
>		  <permission action="/actions" subject="/users/guest"
>inheritable="true" negative="false"/>
>			 <!-- by default, it was true -->
>		  <permission action="/actions/read" subject="/users"
>inheritable="false"/>
>		  <!-- Permission group example -->
>          <objectnode classname="org.apache.slide.structure.GroupNode"
>uri="/users/groupA">
>             <objectnode classname="org.apache.slide.structure.LinkNode"
>uri="/users/groupA/john" linkedUri="/users/john" />
>             <objectnode classname="org.apache.slide.structure.LinkNode"
>uri="/users/groupA/ashik" linkedUri="/users/ashik" />
>             <objectnode classname="org.apache.slide.structure.LinkNode"
>uri="/users/groupA/root" linkedUri="/users/root" />
>             <objectnode classname="org.apache.slide.structure.SubjectNode"
>uri="/users/groupA/singleGroupMember"  />
>          </objectnode>
>          <!-- /users/root represents the administrator -->          
>          <objectnode classname="slideroles.basic.RootRoleImpl"
>uri="/users/root">
>            <revision>
>              <property name="password">root</property>
>            </revision>
>          </objectnode>          
>          <!-- /users/john represents an authenticated user -->         
>          <objectnode classname="slideroles.basic.UserRoleImpl"
>uri="/users/john">
>            <revision>
>              <property name="password">john</property>
>            </revision>
>          </objectnode>          
>          <!-- /users/ashik represents an authenticated user -->         
>          <objectnode classname="slideroles.basic.UserRoleImpl"
>uri="/users/ashik">
>            <revision>
>              <property name="password">ashik</property>
>            </revision>
>          </objectnode>
>          <!-- /users/guest represents an authenticated or unauthenticated
>guest user -->          
>          <objectnode classname="slideroles.basic.GuestRoleImpl"
>uri="/users/guest">
>            <revision>
>              <property name="password"></property>
>            </revision>
>          </objectnode>          
>        </objectnode>        
>        <objectnode classname="org.apache.slide.structure.ActionNode"
>uri="/actions">          
>          <objectnode classname="org.apache.slide.structure.ActionNode"
>uri="/actions/read"/>          
>          <objectnode classname="org.apache.slide.structure.ActionNode"
>uri="/actions/write"/>          
>          <objectnode classname="org.apache.slide.structure.ActionNode"
>uri="/actions/manage"/>          
>        </objectnode>        
>        <objectnode classname="org.apache.slide.structure.SubjectNode"
>uri="/files">
>          <!-- ### Give read/write/manage permission to guest ### 
>               Uncomment the following line to give permission to do
>               all actions on /files to guest (unauthenticated users) -->
>          <!-- <permission action="/actions" subject="/users/guest"/> -->
>          <permission action="/actions/manage" subject="/users/john"/>
>          <permission action="/actions/write" subject="+/users/groupA"/>
>          <permission action="/actions/read" subject="nobody"/>          
>        </objectnode>        
>        <objectnode classname="org.apache.slide.structure.SubjectNode"
>uri="/documents">
>          <!-- ### Give read/write/manage permission to guest ### 
>               Uncomment the following line to give permission to do
>               all actions on /docs to guest (unauthenticated users) -->
>          <permission action="/actions" subject="/users/guest"/>
>          <permission action="/actions" subject="/users/ashik"/>
>          <!--permission action="/actions/manage" subject="/users/ashik"/>
>          <permission action="/actions/write" subject="/users/ashik"/>
>          <permission action="/actions/read" subject="/users/ashik"/-->
>
>        </objectnode>
>        <objectnode classname="org.apache.slide.structure.SubjectNode"
>uri="/emails">
>          <permission action="/actions" subject="/users/guest"/>
>          <permission action="/actions" subject="/users/ashik"/>
>        </objectnode>
>        <objectnode classname="org.apache.slide.structure.SubjectNode"
>uri="/faxes">
>          <permission action="/actions" subject="/users/guest"/>
>          <permission action="/actions" subject="/users/ashik"/>
>        </objectnode>        
>      </objectnode>      
>    </data>    
>  </namespace>
></slide>
>	
>When I restart my server, I find all the newly uploaded files are gone, 
>but when I physically check it in file system, I see they are present 
>there. :-( I made sure that "resetBeforeStarting" is set to "false" (I 
>tried with the value "true" also). What can I do to solve this problem?
>
>I would appreciate your comments here.
>
>Regards,
> 
>Muhammad Ashikuzzaman (Fahim)
>Software Engineer, SurroundApps Inc.
>

---------------------------------------------------------------------
To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-user-help@jakarta.apache.org


Re: FileContentStore disappers?!?

Posted by "K.C. Baltz" <kc...@firefox.co.uk>.
I suspect you want to change the parameter "resetBeforeStarting".  If 
it's set to true, it will delete the contents of your file store every 
time you restart Slide.

K.C.

Ashikuzzaman wrote:

>Dear List,
> 
>I am using Slide 1.0.16 as the nightly build 2.0 is, I am not sure, whether
>I can use right now. I copied the necessary jar files in my webapp's
>web-inf\lib dir and modified the Domain.xml file to use in Tomcat 4.1.27 and
>Resin 2.1 with allowing guests to do all actions in contentStore dir. Now
>when I copy files from file system through Windows XP Web Folders
>functionality to the contentStore that I defined in the domain.xml file it
>seems to work fine. I can even check that the file I copied, physically
>exists. I can copy or download it but can't move, delete, rename or create
>new folder. What's the problem? Anything about user privilege? My clients
>should be able to add new and new files daily, so I have to allow them
>modify those file, create new directories under the contentStore rootpath.
>How can I do these using slide? Should I override slide's WebdavServlet?
>Then which methods to override? Here is the Domain.xml file ---
>
><?xml version="1.0"?>
><slide logger="org.apache.slide.util.logger.SimpleLogger" logger-level="6"
>default="biscomWebdav">
><!--
>logger
>~~~~~~
>org.apache.slide.util.logger.SimpleLogger 
>   default logger with 1 log level
>log4j.Log4jLogger 
>   logger with fine granularity
>   see http://jakarta.apache.org/log4j/
>logger-level 
>~~~~~~~~~~~~
>0 EMERGENCY
>1 CRITICAL
>2 ERROR
>4 WARNING
>6 INFO
>7 DEBUG
>-->
>  <namespace name="biscomWebdav">
><!-- ### Memory Configuration ###
>     The following memory configuration uses the MemoryDescriptorsStore
>     for node,security,locks and revisions. For content the FileContentStore
>     is used. Content is not reset before start. Database may also be used
>instead.
>-->
>    <definition>
>      <store name="contentStore">
>        <nodestore classname="slidestore.reference.MemoryDescriptorsStore">
>        </nodestore>
>        <securitystore>
>          <reference store="nodestore" />
>        </securitystore>
>        <lockstore>
>          <reference store="nodestore" />
>        </lockstore>
>        <revisiondescriptorsstore>
>          <reference store="nodestore" />
>        </revisiondescriptorsstore>
>        <contentstore classname="slidestore.reference.FileContentStore">
>          <parameter
>name="rootpath">C:/winxpsoft/javaGroup/resin-2.1.12/webapps/biscomWebdav/con
>tentStore</parameter>
>          <parameter name="version">false</parameter>
>          <parameter name="resetBeforeStarting">true</parameter>
>        </contentstore>
>      </store>
>      <scope match="/" store="contentStore" />
>    </definition>
>
>    <configuration>
>      <!-- Actions mapping -->
>      <default-action>/actions</default-action>
>      <read-object>/actions/read</read-object>
>      <create-object>/actions/write</create-object>
>      <remove-object>/actions/write</remove-object>
>      <grant-permission>/actions/manage</grant-permission>
>      <revoke-permission>/actions/manage</revoke-permission>
>      <read-permissions>/actions/manage</read-permissions>
>      <lock-object>/actions/write</lock-object>
>      <kill-lock>/actions/manage</kill-lock>
>      <read-locks>/actions/read</read-locks>
>      <read-revision-metadata>/actions/read</read-revision-metadata>
>      <create-revision-metadata>/actions/write</create-revision-metadata>
>      <modify-revision-metadata>/actions/write</modify-revision-metadata>
>      <remove-revision-metadata>/actions/write</remove-revision-metadata>
>      <read-revision-content>/actions/read</read-revision-content>
>      <create-revision-content>/actions/write</create-revision-content>
>      <modify-revision-content>/actions/write</modify-revision-content>
>      <remove-revision-content>/actions/write</remove-revision-content>
>      <!-- Paths configuration -->
>      <userspath>/users</userspath>
>      <guestpath>guest</guestpath>
>      <filespath>/files</filespath>
>      <parameter name="dav">true</parameter>
>      <parameter name="standalone">true</parameter>
>      <!-- Roles definition -->
>      <role name="root">slideroles.basic.RootRole</role>
>      <role name="user">slideroles.basic.UserRole</role>
>      <role name="guest">slideroles.basic.GuestRole</role>
>      <!-- Users management -->
>      <auto-create-users>false</auto-create-users>
>      <!-- Default properties mapping -->
>      <default-property name="provider" namespace="biscomWebdav/"
>value="SurroundApps" role="user"/>
>      <default-property name="pass" namespace="biscomWebdav/" value=""
>role="user"/>
>    </configuration>
>    
>    <data>     
>      <objectnode classname="org.apache.slide.structure.SubjectNode"
>uri="/">
>        <!-- Subject can be:
>                self  "~"
>                all   "nobody"
>                user  "/users/john"
>                group "+/users/groupA"
>                role  "root"
>        -->               
>        <!-- Uncomment the following line to give all permissions to 
>             principals have the root role -->
>        <permission action="/actions" subject="root"/>
>        <permission action="/actions" subject="/users/root"/>
>        <permission action="/actions/read" subject="/users"
>inheritable="false"/>
>        <permission action="/actions/read" subject="nobody"
>inheritable="false"/>        
>        <!-- /users -->        
>        <objectnode classname="org.apache.slide.structure.SubjectNode"
>uri="/users">          
>		  <permission action="/actions" subject="~"/>
>		  <permission action="/actions" subject="/users/guest"
>inheritable="true" negative="false"/>
>			 <!-- by default, it was true -->
>		  <permission action="/actions/read" subject="/users"
>inheritable="false"/>
>		  <!-- Permission group example -->
>          <objectnode classname="org.apache.slide.structure.GroupNode"
>uri="/users/groupA">
>             <objectnode classname="org.apache.slide.structure.LinkNode"
>uri="/users/groupA/john" linkedUri="/users/john" />
>             <objectnode classname="org.apache.slide.structure.LinkNode"
>uri="/users/groupA/ashik" linkedUri="/users/ashik" />
>             <objectnode classname="org.apache.slide.structure.LinkNode"
>uri="/users/groupA/root" linkedUri="/users/root" />
>             <objectnode classname="org.apache.slide.structure.SubjectNode"
>uri="/users/groupA/singleGroupMember"  />
>          </objectnode>
>          <!-- /users/root represents the administrator -->          
>          <objectnode classname="slideroles.basic.RootRoleImpl"
>uri="/users/root">
>            <revision>
>              <property name="password">root</property>
>            </revision>
>          </objectnode>          
>          <!-- /users/john represents an authenticated user -->         
>          <objectnode classname="slideroles.basic.UserRoleImpl"
>uri="/users/john">
>            <revision>
>              <property name="password">john</property>
>            </revision>
>          </objectnode>          
>          <!-- /users/ashik represents an authenticated user -->         
>          <objectnode classname="slideroles.basic.UserRoleImpl"
>uri="/users/ashik">
>            <revision>
>              <property name="password">ashik</property>
>            </revision>
>          </objectnode>
>          <!-- /users/guest represents an authenticated or unauthenticated
>guest user -->          
>          <objectnode classname="slideroles.basic.GuestRoleImpl"
>uri="/users/guest">
>            <revision>
>              <property name="password"></property>
>            </revision>
>          </objectnode>          
>        </objectnode>        
>        <objectnode classname="org.apache.slide.structure.ActionNode"
>uri="/actions">          
>          <objectnode classname="org.apache.slide.structure.ActionNode"
>uri="/actions/read"/>          
>          <objectnode classname="org.apache.slide.structure.ActionNode"
>uri="/actions/write"/>          
>          <objectnode classname="org.apache.slide.structure.ActionNode"
>uri="/actions/manage"/>          
>        </objectnode>        
>        <objectnode classname="org.apache.slide.structure.SubjectNode"
>uri="/files">
>          <!-- ### Give read/write/manage permission to guest ### 
>               Uncomment the following line to give permission to do
>               all actions on /files to guest (unauthenticated users) -->
>          <!-- <permission action="/actions" subject="/users/guest"/> -->
>          <permission action="/actions/manage" subject="/users/john"/>
>          <permission action="/actions/write" subject="+/users/groupA"/>
>          <permission action="/actions/read" subject="nobody"/>          
>        </objectnode>        
>        <objectnode classname="org.apache.slide.structure.SubjectNode"
>uri="/documents">
>          <!-- ### Give read/write/manage permission to guest ### 
>               Uncomment the following line to give permission to do
>               all actions on /docs to guest (unauthenticated users) -->
>          <permission action="/actions" subject="/users/guest"/>
>          <permission action="/actions" subject="/users/ashik"/>
>          <!--permission action="/actions/manage" subject="/users/ashik"/>
>          <permission action="/actions/write" subject="/users/ashik"/>
>          <permission action="/actions/read" subject="/users/ashik"/-->
>
>        </objectnode>
>        <objectnode classname="org.apache.slide.structure.SubjectNode"
>uri="/emails">
>          <permission action="/actions" subject="/users/guest"/>
>          <permission action="/actions" subject="/users/ashik"/>
>        </objectnode>
>        <objectnode classname="org.apache.slide.structure.SubjectNode"
>uri="/faxes">
>          <permission action="/actions" subject="/users/guest"/>
>          <permission action="/actions" subject="/users/ashik"/>
>        </objectnode>        
>      </objectnode>      
>    </data>    
>  </namespace>  
></slide>
>	
>When I restart my server, I find all the newly uploaded files are gone, but
>when I physically check it in file system, I see they are present there. :-(
>I made sure that "resetBeforeStarting" is set to "false" (I tried with the
>value "true" also). What can I do to solve this problem?
>
>I would appreciate your comments here.
>
>Regards,
> 
>Muhammad Ashikuzzaman (Fahim)
>Software Engineer, SurroundApps Inc.
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: slide-user-help@jakarta.apache.org
>
>  
>


---------------------------------------------------------------------
To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-user-help@jakarta.apache.org


Re: FileContentStore disappers?!?

Posted by Emiliano Heyns <em...@iris-advies.nl>.
On Sun, Jan 25, 2004 at 08:12:28PM +0100, Martin Holz wrote:

> Its a little bit confusing. There are 7 interfaces. 
> - Store     (                 
> - NodeStore, 
> - RevisionDescriptorStore
> - RevisionDescriptorsStore
> - SecurityStore 
> - LockStore
> - ContentStore,
> 
> 
> While Store extends the other 6 interfaces, the default implementation
> of Store  (org.apache.slide.store.StandardStore in slide 1.0.16) delegates
> the work to implementations of the other interfaces.You choose a implementation 
> for each of them in Domain.xml. 
> JDBCDescriptorsStore, MemoryDescriptorsStore and FileDescriptorsStore
> implement  the NodeStore, RevisionDescriptorStore, RevisionDescriptorsStore,
> SecurityStore and LockStore interfaces. You could choose FileDescriptorsStore
> as a start.  

I'm looking to implement a slightly altered RDBMS Store. Everything goes
into a database, but I need file attachments, so I want to
auto-create/delete 'shadow directories' for each non-attachment file;
the shadow directory (like 'data.xml' => shadow dir 'data@') is where
the attachments will go, and permissions of the attachments and the
shadow dir will follow those of the file they're attached to[0].

Is there any documentation (even if it's just a mailinglist thread) that
explains stores and their interfaces? Reading the source is pretty slow
going.

-- 
Emiliano
[0] suggestions for other ways to implement file attachments most
welcome!

---------------------------------------------------------------------
To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-user-help@jakarta.apache.org


RE: FileContentStore disappers?!?

Posted by Ashikuzzaman <az...@hotmail.com>.
Thank you Martin. 

I tried using slidestore.file.FileDescriptorsStoreNoVersioning with
slidestore.file.FileContentStoreNoVersioning and
slidestore.reference.FileDescriptorsStore with
slidestore.reference.FileContentStore but in both cases get class cast
exception. So now I am downloading nightly build 2.0 and will start working
with that.

Do you think the nightly build will suffice to interface an existing file
system repository to slide webdav server via Domain.xml? I would like to
wait for the beta release but I have not much time to complete the project,
so have to go with whatever is avaialble now. :-(

Regards,
 
Muhammad Ashikuzzaman (Fahim)
Senior Software Engineer, SurroundApps Inc.


-----Original Message-----
From: news [mailto:news@sea.gmane.org] On Behalf Of Martin Holz
Sent: Monday, January 26, 2004 1:12 AM
To: slide-user@jakarta.apache.org
Subject: Re: FileContentStore disappers?!?

"Ashikuzzaman" <az...@hotmail.com> writes:

> Thank you Martin for your response.
> 
> >Replace the MemoryDescriptorsStore with any persistent store.
> 
> Memory descriptor is volatile, ok. But my contents are mainly various 
> sort of files and directories (not database records) and so I chose 
> for it to prepare a demo first. Now I when I am actually developing 
> the module, I need to point to the file system contents through 
> "webdav". So far I found JDBC descriptor store, node revision 
> descriptor store and memory descriptor store. Other stores are not 
> descriptor stores (example, file content store that I am using). Then 
> what are the descriptor stores? In which doc I can find details of 
> them? I changed the "MemoryDescriptorsStore" to "FileContentStore" but 
> getting the same disappearance of files when restarting slide. I don't 
> understand well what is revision descriptor store and guess its related to
versioning not content so did not try it yet.
Its a little bit confusing. There are 7 interfaces. 
- Store     (                 
- NodeStore,
- RevisionDescriptorStore
- RevisionDescriptorsStore
- SecurityStore
- LockStore
- ContentStore,


While Store extends the other 6 interfaces, the default implementation of
Store  (org.apache.slide.store.StandardStore in slide 1.0.16) delegates the
work to implementations of the other interfaces.You choose a implementation
for each of them in Domain.xml. 
JDBCDescriptorsStore, MemoryDescriptorsStore and FileDescriptorsStore
implement  the NodeStore, RevisionDescriptorStore, RevisionDescriptorsStore,
SecurityStore and LockStore interfaces. You could choose
FileDescriptorsStore as a start.  


> >And since you seem to start a new project now, you should really switch
to
> the CVS head.
> 
> As versioning is not needed, I did not consider CVS. BTW, is there any
> built-in capacity of slide to use CVS for file/dir management (are you
using
> CVS head and CVS as synonymous term?)?

Sorry, a complete  misunderstanding. By CVS HEAD I meant, that you should
get
the newest development version of slide from the cvs server. Version 1.0.16
is 
more than a year old. We are currently preparing Slide 2.0beta.   
For instructions to get a development snapshoot  see 
http://jakarta.apache.org/site/cvsindex.html


Martin


---------------------------------------------------------------------
To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-user-help@jakarta.apache.org


Re: FileContentStore disappers?!?

Posted by Martin Holz <ho...@fiz-chemie.de>.
"Ashikuzzaman" <az...@hotmail.com> writes:

> Thank you Martin for your response.
> 
> >Replace the MemoryDescriptorsStore with any persistent store.
> 
> Memory descriptor is volatile, ok. But my contents are mainly various sort
> of files and directories (not database records) and so I chose for it to
> prepare a demo first. Now I when I am actually developing the module, I need
> to point to the file system contents through "webdav". So far I found JDBC
> descriptor store, node revision descriptor store and memory descriptor
> store. Other stores are not descriptor stores (example, file content store
> that I am using). Then what are the descriptor stores? In which doc I can
> find details of them? I changed the "MemoryDescriptorsStore" to
> "FileContentStore" but getting the same disappearance of files when
> restarting slide. I don't understand well what is revision descriptor store
> and guess its related to versioning not content so did not try it yet.
Its a little bit confusing. There are 7 interfaces. 
- Store     (                 
- NodeStore, 
- RevisionDescriptorStore
- RevisionDescriptorsStore
- SecurityStore 
- LockStore
- ContentStore,


While Store extends the other 6 interfaces, the default implementation
of Store  (org.apache.slide.store.StandardStore in slide 1.0.16) delegates
the work to implementations of the other interfaces.You choose a implementation 
for each of them in Domain.xml. 
JDBCDescriptorsStore, MemoryDescriptorsStore and FileDescriptorsStore
implement  the NodeStore, RevisionDescriptorStore, RevisionDescriptorsStore,
SecurityStore and LockStore interfaces. You could choose FileDescriptorsStore
as a start.  


> >And since you seem to start a new project now, you should really switch to
> the CVS head.
> 
> As versioning is not needed, I did not consider CVS. BTW, is there any
> built-in capacity of slide to use CVS for file/dir management (are you using
> CVS head and CVS as synonymous term?)?

Sorry, a complete  misunderstanding. By CVS HEAD I meant, that you should get
the newest development version of slide from the cvs server. Version 1.0.16 is 
more than a year old. We are currently preparing Slide 2.0beta.   
For instructions to get a development snapshoot  see 
http://jakarta.apache.org/site/cvsindex.html


Martin


---------------------------------------------------------------------
To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-user-help@jakarta.apache.org


RE: FileContentStore disappers?!?

Posted by Ashikuzzaman <az...@hotmail.com>.
Thank you Martin for your response.

>Replace the MemoryDescriptorsStore with any persistent store.

Memory descriptor is volatile, ok. But my contents are mainly various sort
of files and directories (not database records) and so I chose for it to
prepare a demo first. Now I when I am actually developing the module, I need
to point to the file system contents through "webdav". So far I found JDBC
descriptor store, node revision descriptor store and memory descriptor
store. Other stores are not descriptor stores (example, file content store
that I am using). Then what are the descriptor stores? In which doc I can
find details of them? I changed the "MemoryDescriptorsStore" to
"FileContentStore" but getting the same disappearance of files when
restarting slide. I don't understand well what is revision descriptor store
and guess its related to versioning not content so did not try it yet.

Slide seemed to be a good choice to me because it supports "content
management" in Java.

Content Management 
==================

* 100% Pure Java (important for my project)
* Hierarchical object storage 
* Data storage abstraction (important for my project)
* Distributable over a network (important for my project)
* User management (important for my project)
* Security 
* Locking 
* Versioning 
* Indexing 
* Searching 
* Integrated process engine 
* Manageable (important for my project)

>And since you seem to start a new project now, you should really switch to
the CVS head.

As versioning is not needed, I did not consider CVS. BTW, is there any
built-in capacity of slide to use CVS for file/dir management (are you using
CVS head and CVS as synonymous term?)?

If the slide client would be a browser, I could easily prepare a servlet
based webapp to manipulate slide api for content manipulation. But the slide
client is windows xp and 2k web folders (through add network place). So I
don't see any way other than setting up the slide server properly to point
to my file system content repository. Is there any known alternatives that I
am missing? I think I have started messing up things a little.

Once again thanks for your response and future responses.
 
Muhammad Ashikuzzaman (Fahim)
Senior Software Engineer, SurroundApps Inc.


-----Original Message-----
From: news [mailto:news@sea.gmane.org] On Behalf Of Martin Holz
Sent: Sunday, January 25, 2004 10:17 PM
To: slide-user@jakarta.apache.org
Subject: Re: FileContentStore disappers?!?


Hello,

"Ashikuzzaman" <az...@hotmail.com> writes:

> Dear List,
>  
> I am using Slide 1.0.16 as the nightly build 2.0 is, I am not sure, 
> whether I can use right now. I copied the necessary jar files in my 
> webapp's web-inf\lib dir and modified the Domain.xml file to use in 
> Tomcat 4.1.27 and Resin 2.1 with allowing guests to do all actions in 
> contentStore dir. Now when I copy files from file system through 
> Windows XP Web Folders functionality to the contentStore that I 
> defined in the domain.xml file it seems to work fine. I can even check 
> that the file I copied, physically exists. I can copy or download it 
> but can't move, delete, rename or create new folder. What's the 
> problem? Anything about user privilege? My clients should be able to 
> add new and new files daily, so I have to allow them modify those file,
create new directories under the contentStore rootpath.
> How can I do these using slide? Should I override slide's WebdavServlet?
> Then which methods to override? Here is the Domain.xml file ---
> 
> <?xml version="1.0"?>
> <slide logger="org.apache.slide.util.logger.SimpleLogger" logger-level="6"
> default="biscomWebdav">
> <!--
> logger
> ~~~~~~
> org.apache.slide.util.logger.SimpleLogger 
>    default logger with 1 log level
> log4j.Log4jLogger 
>    logger with fine granularity
>    see http://jakarta.apache.org/log4j/ logger-level ~~~~~~~~~~~~ 0 
> EMERGENCY
> 1 CRITICAL
> 2 ERROR
> 4 WARNING
> 6 INFO
> 7 DEBUG
> -->
>   <namespace name="biscomWebdav">
> <!-- ### Memory Configuration ###
>      The following memory configuration uses the MemoryDescriptorsStore
>      for node,security,locks and revisions. For content the
FileContentStore
>      is used. Content is not reset before start. Database may also be 
> used instead.
> -->
>     <definition>
>       <store name="contentStore">
>         <nodestore
classname="slidestore.reference.MemoryDescriptorsStore">
>         </nodestore>
>         <securitystore>
>           <reference store="nodestore" />
>         </securitystore>
>         <lockstore>
>           <reference store="nodestore" />
>         </lockstore>
>         <revisiondescriptorsstore>
>           <reference store="nodestore" />
>         </revisiondescriptorsstore>
>         <contentstore classname="slidestore.reference.FileContentStore">
>           <parameter
> name="rootpath">C:/winxpsoft/javaGroup/resin-2.1.12/webapps/biscomWebd
> av/con
> tentStore</parameter>
>           <parameter name="version">false</parameter>
>           <parameter name="resetBeforeStarting">true</parameter>
>         </contentstore>
>       </store>
>       <scope match="/" store="contentStore" />
>     </definition>
 [...]

> When I restart my server, I find all the newly uploaded files are 
> gone, but when I physically check it in file system, I see they are 
> present there. :-( I made sure that "resetBeforeStarting" is set to 
> "false" (I tried with the value "true" also). What can I do to solve this
problem?

Slide uses different stores for metadata and content. While you configured
the content store to be persistent, the MemoryDescriptorsStore is always
volatile. 
So once you shut down slide, it will loose all information, about the
directory structure and not find the content. Replace the
MemoryDescriptorsStore with any persistent store.

And since you seem to start a new project now, you should really switch to
the CVS head.

Martin

--
Martin Holz     <ho...@fiz-chemie.de>

Softwareentwicklung / Vernetztes Studium - Chemie FIZ CHEMIE Berlin
Franklinstrasse 11
D-10587 Berlin     



---------------------------------------------------------------------
To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-user-help@jakarta.apache.org


Re: FileContentStore disappers?!?

Posted by Martin Holz <ho...@fiz-chemie.de>.
Hello,

"Ashikuzzaman" <az...@hotmail.com> writes:

> Dear List,
>  
> I am using Slide 1.0.16 as the nightly build 2.0 is, I am not sure, whether
> I can use right now. I copied the necessary jar files in my webapp's
> web-inf\lib dir and modified the Domain.xml file to use in Tomcat 4.1.27 and
> Resin 2.1 with allowing guests to do all actions in contentStore dir. Now
> when I copy files from file system through Windows XP Web Folders
> functionality to the contentStore that I defined in the domain.xml file it
> seems to work fine. I can even check that the file I copied, physically
> exists. I can copy or download it but can't move, delete, rename or create
> new folder. What's the problem? Anything about user privilege? My clients
> should be able to add new and new files daily, so I have to allow them
> modify those file, create new directories under the contentStore rootpath.
> How can I do these using slide? Should I override slide's WebdavServlet?
> Then which methods to override? Here is the Domain.xml file ---
> 
> <?xml version="1.0"?>
> <slide logger="org.apache.slide.util.logger.SimpleLogger" logger-level="6"
> default="biscomWebdav">
> <!--
> logger
> ~~~~~~
> org.apache.slide.util.logger.SimpleLogger 
>    default logger with 1 log level
> log4j.Log4jLogger 
>    logger with fine granularity
>    see http://jakarta.apache.org/log4j/
> logger-level 
> ~~~~~~~~~~~~
> 0 EMERGENCY
> 1 CRITICAL
> 2 ERROR
> 4 WARNING
> 6 INFO
> 7 DEBUG
> -->
>   <namespace name="biscomWebdav">
> <!-- ### Memory Configuration ###
>      The following memory configuration uses the MemoryDescriptorsStore
>      for node,security,locks and revisions. For content the FileContentStore
>      is used. Content is not reset before start. Database may also be used
> instead.
> -->
>     <definition>
>       <store name="contentStore">
>         <nodestore classname="slidestore.reference.MemoryDescriptorsStore">
>         </nodestore>
>         <securitystore>
>           <reference store="nodestore" />
>         </securitystore>
>         <lockstore>
>           <reference store="nodestore" />
>         </lockstore>
>         <revisiondescriptorsstore>
>           <reference store="nodestore" />
>         </revisiondescriptorsstore>
>         <contentstore classname="slidestore.reference.FileContentStore">
>           <parameter
> name="rootpath">C:/winxpsoft/javaGroup/resin-2.1.12/webapps/biscomWebdav/con
> tentStore</parameter>
>           <parameter name="version">false</parameter>
>           <parameter name="resetBeforeStarting">true</parameter>
>         </contentstore>
>       </store>
>       <scope match="/" store="contentStore" />
>     </definition>
 [...]

> When I restart my server, I find all the newly uploaded files are gone, but
> when I physically check it in file system, I see they are present there. :-(
> I made sure that "resetBeforeStarting" is set to "false" (I tried with the
> value "true" also). What can I do to solve this problem?

Slide uses different stores for metadata and content. While you configured the 
content store to be persistent, the MemoryDescriptorsStore is always volatile. 
So once you shut down slide, it will loose all information, about the directory structure
and not find the content. Replace the MemoryDescriptorsStore with any persistent store.

And since you seem to start a new project now, you should really switch to the CVS head.

Martin

--
Martin Holz     <ho...@fiz-chemie.de>

Softwareentwicklung / Vernetztes Studium - Chemie
FIZ CHEMIE Berlin
Franklinstrasse 11
D-10587 Berlin     


---------------------------------------------------------------------
To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-user-help@jakarta.apache.org