cancel
Showing results for 
Search instead for 
Did you mean: 

Downloading file from Alfresco

subbu
Champ in-the-making
Champ in-the-making
I am using alfresco to upload/download file. While downloading file from alfresco, I am getting the following error on server,

14:02:15,977 INFO  [STDOUT] Connecting to: http://localhost:8081/alfresco
14:02:16,410 INFO  [STDOUT] Getting content of document with path /app:company_home/1.txt or id null.
14:02:17,399 ERROR [STDERR] Can not get the content.
14:02:17,401 ERROR [STDERR] AxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.generalException
faultSubcode:
faultString:
faultActor:
faultNode:
faultDetail:
   {http://www.alfresco.org/ws/service/content/1.0}ContentFault:<ns1:errorCode>0</ns1:errorCode><ns1:message>01040471 Error executing xpath:
   xpath: /app:company_home/1.txt</ns1:message>
   {http://xml.apache.org/axis/}exceptionNameSmiley Surprisedrg.alfresco.repo.webservice.content.ContentFault
   {http://xml.apache.org/axis/}stackTrace:
   at org.alfresco.repo.webservice.content.ContentWebService.read(ContentWebService.java:100)
   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
   at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
   at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
   at java.lang.reflect.Method.invoke(Method.java:597)

Please help me out

Thanks in Advance.

By,
Subbu.
4 REPLIES 4

mitpatoliya
Star Collaborator
Star Collaborator
Which version of Alfresco you are using.
Verify that it license is not expired from logs.
Are you able to do all other operations properly?

subbu
Champ in-the-making
Champ in-the-making
Thanks for reply..

I am using Community edition 4.0. License is not expired. what do you mean by all other option. I am new to alfresco and trying to upload/download file from alfresco. I am able to connect alfresco through java code. but the problem is getting content from alfresco. Can you help me out?

cpaul
Champ on-the-rise
Champ on-the-rise
It looks like you're trying to retrieve content for a file (1.txt) stored in the root (/app:company_home). Are you certain this is the location of the file?

mitpatoliya
Star Collaborator
Star Collaborator
Yes as cpaul said please make sure you have that file 1.txt lying directly under the company home.
But let me reconfirm are you trying to download file through alfresco's webclient or through your code?
If you are using your code please share that as well to figure out problem.