jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jascpaint <Vivian.Ngu...@dsto.defence.gov.au>
Subject Re: Uploading files via WebDav questions
Date Tue, 17 Jun 2008 03:18:14 GMT

Thank you for your reply.
I have written a custom IOHandler that simply extends the DefaultHandler
with method importProperties being overridden. 

I have changed jackrabbit-war.1.4.war's config.xml to use
"myproject.mypackage.MyHandler" instead of the DefaultHandler.

I now have this problem when uploading a file through WebDav:

17.06.2008 12:40:18 *INFO * AbstractConfig: Configuration of BootstrapConfig
(AbstractConfig.java, line 101)
17.06.2008 12:40:18 *INFO * AbstractConfig:
---------------------------------------------- (AbstractConfig.java, line
102)
17.06.2008 12:40:18 *INFO * AbstractConfig:   jndiConfig:
org.apache.jackrabbit.j2ee.JNDIConfig@1aaf194 (AbstractConfig.java, li
 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:   rmiConfig:
org.apache.jackrabbit.j2ee.RMIConfig@1da5362 (AbstractConfig.java, line
06)
17.06.2008 12:40:18 *INFO * AbstractConfig:   repositoryHome:
data/repository (AbstractConfig.java, line 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:   repositoryConfig:
data/repository/repository.xml (AbstractConfig.java, line 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:   class: class
org.apache.jackrabbit.j2ee.BootstrapConfig (AbstractConfig.java, line
06)
17.06.2008 12:40:18 *INFO * AbstractConfig:   valid: true
(AbstractConfig.java, line 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:   repositoryName: my.repository
(AbstractConfig.java, line 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:
---------------------------------------------- (AbstractConfig.java, line
108)
17.06.2008 12:40:18 *INFO * AbstractConfig: Configuration of JNDIConfig
(AbstractConfig.java, line 101)
17.06.2008 12:40:18 *INFO * AbstractConfig:
---------------------------------------------- (AbstractConfig.java, line
102)
17.06.2008 12:40:18 *INFO * AbstractConfig:   jndiName: my.repository
(AbstractConfig.java, line 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:   class: class
org.apache.jackrabbit.j2ee.JNDIConfig (AbstractConfig.java, line 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:   jndiEnv:
{java.naming.provider.url=http://www.apache.org/jackrabbit, java.naming.f
tory.initial=org.apache.jackrabbit.core.jndi.provider.DummyInitialContextFactory}
(AbstractConfig.java, line 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:   valid: true
(AbstractConfig.java, line 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:   jndiEnabled: true
(AbstractConfig.java, line 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:
---------------------------------------------- (AbstractConfig.java, line
108)
17.06.2008 12:40:18 *INFO * AbstractConfig: Configuration of RMIConfig
(AbstractConfig.java, line 101)
17.06.2008 12:40:18 *INFO * AbstractConfig:
---------------------------------------------- (AbstractConfig.java, line
102)
17.06.2008 12:40:18 *INFO * AbstractConfig:   rmiName: my.repository
(AbstractConfig.java, line 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:   rmiUri:
//localhost:1099/my.repository (AbstractConfig.java, line 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:   rmiEnabled: true
(AbstractConfig.java, line 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:   rmiPort: 1099
(AbstractConfig.java, line 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:   rmiHost: localhost
(AbstractConfig.java, line 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:   class: class
org.apache.jackrabbit.j2ee.RMIConfig (AbstractConfig.java, line 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:   valid: true
(AbstractConfig.java, line 106)
17.06.2008 12:40:18 *INFO * AbstractConfig:
---------------------------------------------- (AbstractConfig.java, line
108)
17.06.2008 12:40:18 *INFO * RepositoryAccessServlet: Acquired repository via
JNDI. (RepositoryAccessServlet.java, line 207)
[stderr] java.io.IOException: Error transferring file:
Unsupported_Media_Type

Maybe my custom handler is implemented incorrectly?




Alexander Klimetschek wrote:
> 
> On Mon, Jun 16, 2008 at 9:49 AM, jascpaint
> <Vivian.Nguyen@dsto.defence.gov.au> wrote:
>>
>> I am new with Jackrabbit and would appreciate your help.
>> Currently I use WebDav for upload files into repository. I am wondering
>> how
>> nt:primaryType
> 
> You probably mean jcr:primaryType. It is the auto-created property
> which indicates the primary node type of the current node. Have a look
> at the JCR specification (JSR-170), section 6.7 "Node Types".
> 
>> property is assigned to the newly created node and whether it
>> is possible to assign this property to a subtype of nt:file. It seems
>> like
>> all files are assigned to this primaryType automatically, or I am missing
>> some config settings somewhere?
> 
> Folders and files are mapped to nt:folder and nt:file node types,
> which are part of the JCR specification (you can also define your own
> node types). They can be found in the spec starting at section
> 6.7.22.5 "nt:hierarchyNode". Any JCR application working with files
> should map the content onto these node types, so that's why WebDAV is
> doing this.
> 
> You can write custom IOHandlers [1] if you want to import different
> content structures via WebDAV. They are configured in the file
> config.xml [2] (that can be found in the jackrabbit webapp under
> WEB-INF).
> 
> Regards,
> Alex
> 
> [1]
> http://svn.apache.org/repos/asf/jackrabbit/trunk/jackrabbit-jcr-server/src/main/java/org/apache/jackrabbit/server/io/IOHandler.java
> [2]
> http://svn.apache.org/repos/asf/jackrabbit/trunk/jackrabbit-webapp/src/main/webapp/WEB-INF/config.xml
> 
> -- 
> Alexander Klimetschek
> alexander.klimetschek@day.com
> 
> 

-- 
View this message in context: http://www.nabble.com/Uploading-files-via-WebDav-questions-tp17859587p17877318.html
Sent from the Jackrabbit - Users mailing list archive at Nabble.com.


Mime
View raw message