Hi everyone, i'm new to SOAP and logicalDoc. I'm trying to make a java progect that use wsdl schemas to connect, make checkins, updates, and creations of new documents.
I'm using Eclipse with some web services client (Document, Auth, Folder).
I mean that I'm not using the logicalDoc Api (webesrvices, core) that gives the possibility of using a DocumentClient but I'm using DocumentServiceProxy.
The problem is that when I create a new document nothing happens: no Errors are thrown, but no document is created.
java code:
String host = "https://MYLogicalDoc:8080/services";
DocumentServiceProxy documentClient = new DocumentServiceProxy(host + "/Document");
AuthServiceProxy auth = new AuthServiceProxy(host + "/Auth");
String sid = auth.login(userName, password);
WsDocument document = new WsDocument();
document.setComment(comment);
document.setTitle("Title");
document.setFileName("name");
document.setLanguage("en");
document.setType("txt");
document.setFolderId(folder.getId());//id where I need the folder
WsDocumentHolder docHolder= new WsDocumentHolder(document);
InputStream stream = new FileInputStream("path\to\my\file.txt");
byte[] bytesArray= new byte[(int) file.length()];
documentClient.create(sid, docHolder, bytesArray);
The create function is supposed to create a new document, isn't it?
Something strange happens because when I try to create a document with a name it doesn't get created (if I search with a given id (or name) I don't get the document, so supposely it doesn't exist) but if I try to create a document with the same name from another java project (works with Logicaldoc api (webesrvices, core) -fully working-tested) the document is created but to the name given is added a round square with a number (e.g (2)) like there actually exist a document with that name.
The contents you find here are totally obsolete so do not use this website to obtain a solution for your issues: the indications you get from here will not be accurate and may lead to data loss or other mayor problems
Document wsdl create
Moderator: car031
Post
Re: Document wsdl create
Hi Xerion94,
try to catch the exceptions
and to initialize the variable "comments"
Also maybe the issue is on the https self signed certificate,
try to use directly the http variant:
try to catch the exceptions
and to initialize the variable "comments"
Also maybe the issue is on the https self signed certificate,
try to use directly the http variant:
Code: Select all
String host = "http://MYLogicalDoc:8080/services";
Post
Re: Document wsdl create
Thank you very much but I already resolved it: when I started with the tutorials I used the logicaldoc api then make a pgm that use only wsdl schema. Using the wsdl as I did, the creation of a document is a little different and the doc need a publish method to be called so you can see the actual document on Logicldoc otherwise I think that the document is saved but because of not being published you can't neither find the document (to actually publish it) nor to delete it.
I think that there is a very lack of documentation abuot all methods if you work withuot logicaldoc api. Moreover even in the Logicaldoc api sometimes you are not so sure of what are you doing because sometimes there aren't any kind of explanation of themethods. By the way the tutorials with the logicaldoc api are very well formed, of course is required to who is working on them to pay attention cause mistakes can be easily make.
Sorry for the not-perfect english
I think that there is a very lack of documentation abuot all methods if you work withuot logicaldoc api. Moreover even in the Logicaldoc api sometimes you are not so sure of what are you doing because sometimes there aren't any kind of explanation of themethods. By the way the tutorials with the logicaldoc api are very well formed, of course is required to who is working on them to pay attention cause mistakes can be easily make.
Sorry for the not-perfect english
Post
Re: Document wsdl create
Ok Xerion,
I'm glad you've solved.
I will pass your suggestions to those involved in the documentation.
If you need further help we are at your disposal.
Note: Speaking of Web-services, with the next release of LogicalDOC (LogicalDOC 7.5) there will be some significant innovations and changes in usage.
In fact, we are implementing a whole new set of REST methods
Br
Alex
I'm glad you've solved.
I will pass your suggestions to those involved in the documentation.
If you need further help we are at your disposal.
Note: Speaking of Web-services, with the next release of LogicalDOC (LogicalDOC 7.5) there will be some significant innovations and changes in usage.
In fact, we are implementing a whole new set of REST methods
Br
Alex
Who is online
Users browsing this forum: No registered users and 1 guest