jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From yamuna <yamuna.e...@gmail.com>
Subject javax.jcr.version.VersionException: Unable to perform operation. Node is checked-in. at org.apache.jackrabbit.rmi.server.ServerObject.getRepositoryException(ServerObject.java:141)
Date Wed, 08 Aug 2018 09:52:10 GMT
I have written a piece of java code to update the contents of the jack rabbit
repository

 	  System.out.println("node.getName()"+node.getName());
        	 if( node.getName().equals("1486135308708")) {
        		 InputStream inputStream = 
           		      new FileInputStream("D:/1103_LVA_Temp01_SEV.pdf");
        
  		 if (node.isCheckedOut()) {
        		 Binary localBinary =
localSession.getValueFactory().createBinary(inputStream);
        		 node.getNode("jcr:content").setProperty("jcr:data", localBinary);
        		 localSession.save();
        		 }
        	 }

Getting below exception

2018-08-08 15:13:14,401 [main] DEBUG CopyJCRFiles  - Unable to perform
operation. Node is checked-in.
javax.jcr.version.VersionException: Unable to perform operation. Node is
checked-in.
	at
org.apache.jackrabbit.rmi.server.ServerObject.getRepositoryException(ServerObject.java:141)
	at
org.apache.jackrabbit.rmi.server.ServerNode.setProperty(ServerNode.java:289)
	at sun.reflect.GeneratedMethodAccessor57.invoke(Unknown Source)
	at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:324)
	at sun.rmi.transport.Transport$1.run(Transport.java:200)
	at sun.rmi.transport.Transport$1.run(Transport.java:197)
	at java.security.AccessController.doPrivileged(Native Method)
	at sun.rmi.transport.Transport.serviceCall(Transport.java:196)
	at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:568)
	at
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:826)
	at
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.lambda$run$0(TCPTransport.java:683)
	at java.security.AccessController.doPrivileged(Native Method)
	at
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:682)
	at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
	at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
	at java.lang.Thread.run(Thread.java:745)
	at
sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:275)
	at
sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:252)
	at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:161)
	at org.apache.jackrabbit.rmi.server.ServerNode_Stub.setProperty(Unknown
Source)
	at
org.apache.jackrabbit.rmi.client.ClientNode.setProperty(ClientNode.java:128)


I tried by checkin out the version manager same issue is observed





--
Sent from: http://jackrabbit.510166.n4.nabble.com/Jackrabbit-Dev-f523400.html

Mime
View raw message