jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Julian Reschke <julian.resc...@gmx.de>
Subject Re: Issue with node with double byte space
Date Tue, 23 Apr 2013 12:19:24 GMT
On 2013-04-23 13:36, Abhinav Mathur wrote:
> Hi,
> 
> When I try to create a node with double byte space I get following error
> 
> Exception in thread "main" javax.jcr.RepositoryException: Failed to resolve path 2byte space.jpg
relative to node /
>         at org.apache.jackrabbit.core.session.AddNodeOperation.perform(AddNodeOperation.java:65)
>         at org.apache.jackrabbit.core.session.AddNodeOperation.perform(AddNodeOperation.java:1)
>         at org.apache.jackrabbit.core.session.SessionState.perform(SessionState.java:216)
>         at org.apache.jackrabbit.core.ItemImpl.perform(ItemImpl.java:91)
>         at org.apache.jackrabbit.core.NodeImpl.addNodeWithUuid(NodeImpl.java:1814)
>         at org.apache.jackrabbit.core.NodeImpl.addNode(NodeImpl.java:1766)
>         at Test.main(Test.java:29)
> Caused by: org.apache.jackrabbit.spi.commons.conversion.MalformedPathException: '2byte space.jpg'
is not a valid path. Whitespace not a allowed in name.
>         at org.apache.jackrabbit.spi.commons.conversion.PathParser.parse(PathParser.java:393)
>         at org.apache.jackrabbit.spi.commons.conversion.PathParser.parse(PathParser.java:122)
>         at org.apache.jackrabbit.spi.commons.conversion.ParsingPathResolver.getQPath(ParsingPathResolver.java:90)
>         at org.apache.jackrabbit.spi.commons.conversion.CachingPathResolver.getQPath(CachingPathResolver.java:98)
>         at org.apache.jackrabbit.spi.commons.conversion.CachingPathResolver.getQPath(CachingPathResolver.java:77)
>         at org.apache.jackrabbit.spi.commons.conversion.DefaultNamePathResolver.getQPath(DefaultNamePathResolver.java:82)
>         at org.apache.jackrabbit.core.SessionImpl.getQPath(SessionImpl.java:648)
>         at org.apache.jackrabbit.core.session.SessionContext.getQPath(SessionContext.java:338)
>         at org.apache.jackrabbit.core.session.AddNodeOperation.perform(AddNodeOperation.java:63)
>         ... 6 more
> 
> This can be reproduced by following code
> 
> 
> public static void main(String[] args) throws Exception {
>                Repository repository = new TransientRepository();
>                Session session = repository.login(new SimpleCredentials("username",
>                             "password".toCharArray()));
>                try {
>                       Node root = session.getRootNode();
> 
>                       // Store content
>                       Node hello = root.addNode("2byte space.jpg");
> 
>                       session.save();
>                } finally {
>                       session.logout();
>                }
>         }
> 
> 
> Is this is a bug. I am using jackrabbit-2.6.0

So it seems your node node contains whitespace which is not ASCII white
space. Is this intended?

Best regards, Julian




Mime
View raw message