Hola a todos,Os cuento mis avances, he conseguido generar el servicio web que invoca al de alfresco correctamente de la forma tradicional (generando el wsdl y y colocando el war en un tomcat) Pero ahora tengo el siguiente problema, mi método crear documento sube un documento a Alfresco a un "lugar" especifico de la siguiente forma: RdoAlfresco rdo = new RdoAlfresco();
// Start the session
AuthenticationUtils.startSession(LOGIN, PASS);
System.out.println("Se ha logado!!");
// Create a reference to the parent where we want to create content
Store storeRef = new Store(Constants.WORKSPACE_STORE, "SpacesStore");
ParentReference companyHomeParent = new ParentReference(storeRef, null, "/app:company_home" + "/cm:"+ codAplicacion + "/cm:" + directorio, Constants.ASSOC_CONTAINS, null);
System.out.println("Ha creado el ruta de referencia!!");
// Assign name
String name = "Web Services sample " + nameDoc + " (" + System.currentTimeMillis() + ")";
companyHomeParent.setChildName("cm:" + name);
System.out.println("Ha asignado el nombre!!");
// Construct CML statement to create content node
// Note: Assign "1" as a local id, so we can refer to it in subsequent
// CML statements within the same CML block
NamedValue[] contentProps = new NamedValue[1];
contentProps[0] = Utils.createNamedValue(Constants.PROP_NAME, name);
CMLCreate create = new CMLCreate("1", companyHomeParent, null, null, null, Constants.TYPE_CONTENT, contentProps);
System.out.println("Ha asignado el nombre!!");
// Construct CML statement to add titled aspect
NamedValue[] titledProps = new NamedValue[2];
titledProps[0] = Utils.createNamedValue(Constants.PROP_TITLE, name);
titledProps[1] = Utils.createNamedValue(Constants.PROP_DESCRIPTION, name);
CMLAddAspect addAspect = new CMLAddAspect(Constants.ASPECT_TITLED, titledProps, null, "1");
System.out.println("Ha creado el addAspect!!");
// Construct CML Block
CML cml = new CML();
cml.setCreate(new CMLCreate[] {create});
cml.setAddAspect(new CMLAddAspect[] {addAspect});
System.out.println("Ha construido el CML Block!!");
// Issue CML statement via Repository Web Service and retrieve result
// Note: Batching of multiple statements into a single web call
String url = "http://localhost:8090/alfresco/api";
UpdateResult[] result = WebServiceFactory.getRepositoryService(url).update(cml);
Reference content = result[0].getDestination();
System.out.println("Ha construido el UpdateResult!!");
//Write
ContentServiceSoapBindingStub contentService = WebServiceFactory.getContentService();
System.out.println("Ha obtenido el contentService!!");
//Se le asigna el mimetype del documento
ContentFormat contentFormat = new ContentFormat(mimetype, "UTF-8");
System.out.println("Ha obtenido el contentFormat!!");
//Obtengo los bytes del Documento a Subir
byte[] fileBytes = getBytesFile(rutaFile);
Content contentRef = contentService.write(content, Constants.PROP_CONTENT, fileBytes, contentFormat);
System.out.println("FIN!!! Content Length: " + contentRef.getLength());
rdo.setTamanyo(contentRef.getLength());
rdo.setMimetype(contentRef.getFormat().getMimetype());
rdo.setCodRdo("200"); //OK!!!
Pero el servicioWeb no me pasa de esta línea: UpdateResult[] result = WebServiceFactory.getRepositoryService(url).update(cml);(WebServiceFactory.getRepositoryService(url) >> si me devuelve valor!) He sacado las trazas de Alfresco por consola, y solo obtengo esta línea:13:02:27,723 User:admin DEBUG [webservice.authentication.AuthenticationWebService] Issued ticket 'TICKET_1b946b9d25ea2787b056316c4c82d3f03663449a' for
'admin'Cuando ejecuto el método desde el eclipse todo me va ok, y las trazas que me saca Alfresco son las siguientes:12:55:59,101 User:admin DEBUG [webservice.authentication.AuthenticationWebService] Issued ticket 'TICKET_40bf0d649fc60e16c6a591afd6a2a7633bda4c03' for
'admin'
12:55:59,726 User:admin DEBUG [webservice.axis.TicketCallbackHandler] Verifying ticket for: ticket
12:55:59,726 User:admin DEBUG [webservice.axis.TicketCallbackHandler] Ticket: TICKET_40bf0d649fc60e16c6a591afd6a2a7633bda4c03
12:55:59,726 User:admin DEBUG [webservice.axis.TicketCallbackHandler] Ticket validated successfully
12:55:59,742 User:admin DEBUG [webservice.axis.QueryConfigHandler] QueryHeader was not found for call to update
12:55:59,804 User:admin DEBUG [repo.webservice.Utils] Resolving path: /app:company_home/cm:Tartanga/cmepartamento2
12:55:59,835 User:admin DEBUG [repo.webservice.Utils] Converting single-valued property '{http://www.alfresco.org/model/content/1.0}name' with value W
eb Services sample PRUEBA (1255690559132)
12:55:59,867 User:admin DEBUG [node.integrity.IntegrityChecker] Added event to event set:
event: IntegrityEvent[ name=org.alfresco.repo.node.integrity.PropertiesIntegrityEvent, nodeRef=workspace://SpacesStore/4bd46030-7406-4873-868d-5c9a
f4a90180]
12:55:59,867 User:admin DEBUG [node.integrity.IncompleteNodeTagger] Added node reference to property set: workspace://SpacesStore/4bd46030-7406-4873-8
68d-5c9af4a90180
12:55:59,913 User:admin DEBUG [node.integrity.IntegrityChecker] Event already present in event set:
event: IntegrityEvent[ name=org.alfresco.repo.node.integrity.PropertiesIntegrityEvent, nodeRef=workspace://SpacesStore/4bd46030-7406-4873-868d-5c9a
f4a90180]
12:55:59,913 User:admin DEBUG [node.integrity.IntegrityChecker] Added event to event set:
event: IntegrityEvent[ name=org.alfresco.repo.node.integrity.AssocSourceTypeIntegrityEvent, nodeRef=workspace://SpacesStore/dfbec6ca-a7ba-4b6d-a01a
-ee5f11297ec9, typeQName={http://www.alfresco.org/model/content/1.0}contains]
12:55:59,913 User:admin DEBUG [node.integrity.IntegrityChecker] Added event to event set:
event: IntegrityEvent[ name=org.alfresco.repo.node.integrity.AssocTargetTypeIntegrityEvent, nodeRef=workspace://SpacesStore/4bd46030-7406-4873-868d
-5c9af4a90180, typeQName={http://www.alfresco.org/model/content/1.0}contains]
12:55:59,913 User:admin DEBUG [node.integrity.IntegrityChecker] Added event to event set:
event: IntegrityEvent[ name=org.alfresco.repo.node.integrity.AssocSourceMultiplicityIntegrityEvent, nodeRef=workspace://SpacesStore/4bd46030-7406-4
873-868d-5c9af4a90180, typeQName={http://www.alfresco.org/model/content/1.0}contains]
12:55:59,913 User:admin DEBUG [node.integrity.IntegrityChecker] Added event to event set:
event: IntegrityEvent[ name=org.alfresco.repo.node.integrity.AssocTargetMultiplicityIntegrityEvent, nodeRef=workspace://SpacesStore/dfbec6ca-a7ba-4
b6d-a01a-ee5f11297ec9, typeQName={http://www.alfresco.org/model/content/1.0}contains]
12:55:59,913 User:admin DEBUG [node.integrity.IntegrityChecker] Added event to event set:
event: IntegrityEvent[ name=org.alfresco.repo.node.integrity.AssocTargetRoleIntegrityEvent, nodeRef=workspace://SpacesStore/dfbec6ca-a7ba-4b6d-a01a
-ee5f11297ec9, typeQName={http://www.alfresco.org/model/content/1.0}contains, qname={}cm:Web Services sample PRUEBA (1255690559132)]
12:55:59,913 User:admin DEBUG [node.integrity.IntegrityChecker] Added event to event set:
event: IntegrityEvent[ name=org.alfresco.repo.node.integrity.AspectsIntegrityEvent, nodeRef=workspace://SpacesStore/4bd46030-7406-4873-868d-5c9af4a
90180]
12:55:59,913 User:admin DEBUG [node.integrity.IncompleteNodeTagger] Added node reference to property set: workspace://SpacesStore/4bd46030-7406-4873-8
68d-5c9af4a90180
12:55:59,913 User:admin DEBUG [node.integrity.IncompleteNodeTagger] Added node reference to property set: workspace://SpacesStore/4bd46030-7406-4873-8
68d-5c9af4a90180
12:55:59,913 User:admin DEBUG [node.integrity.IncompleteNodeTagger] Added association to node: workspace://SpacesStore/4bd46030-7406-4873-868d-5c9af4a
90180, null
12:55:59,945 User:admin DEBUG [node.integrity.IncompleteNodeTagger] Added node reference to property set: workspace://SpacesStore/4bd46030-7406-4873-8
68d-5c9af4a90180
12:55:59,945 User:admin DEBUG [node.integrity.IntegrityChecker] Event already present in event set:
event: IntegrityEvent[ name=org.alfresco.repo.node.integrity.PropertiesIntegrityEvent, nodeRef=workspace://SpacesStore/4bd46030-7406-4873-868d-5c9a
f4a90180]
12:55:59,960 User:admin DEBUG [repo.webservice.Utils] setting path for reference to: /app:company_home/cm:Tartanga/cmepartamento2/cm_x003a_Web_x0020
_Services_x0020_sample_x0020_PRUEBA_x0020__x0028_1255690559132_x0029_
12:55:59,960 User:admin DEBUG [repo.webservice.CMLUtil] Local node ref has been resolved for id = 1
12:55:59,960 User:admin DEBUG [repo.webservice.Utils] Converting single-valued property '{http://www.alfresco.org/model/content/1.0}title' with value
Web Services sample PRUEBA (1255690559132)
12:55:59,960 User:admin DEBUG [repo.webservice.Utils] Converting single-valued property '{http://www.alfresco.org/model/content/1.0}description' with
value Web Services sample PRUEBA (1255690559132)
12:55:59,976 User:admin DEBUG [node.integrity.IntegrityChecker] Event already present in event set:
event: IntegrityEvent[ name=org.alfresco.repo.node.integrity.PropertiesIntegrityEvent, nodeRef=workspace://SpacesStore/4bd46030-7406-4873-868d-5c9a
f4a90180]
12:55:59,976 User:admin DEBUG [node.integrity.IncompleteNodeTagger] Added node reference to property set: workspace://SpacesStore/4bd46030-7406-4873-8
68d-5c9af4a90180
12:55:59,976 User:admin DEBUG [repo.webservice.Utils] setting path for reference to: /app:company_home/cm:Tartanga/cmepartamento2/cm_x003a_Web_x0020
_Services_x0020_sample_x0020_PRUEBA_x0020__x0028_1255690559132_x0029_
12:55:59,976 User:admin DEBUG [repo.webservice.Utils] setting path for reference to: /app:company_home/cm:Tartanga/cmepartamento2/cm_x003a_Web_x0020
_Services_x0020_sample_x0020_PRUEBA_x0020__x0028_1255690559132_x0029_
12:56:00,273 User:admin DEBUG [webservice.axis.TicketCallbackHandler] Verifying ticket for: ticket
12:56:00,273 User:admin DEBUG [webservice.axis.TicketCallbackHandler] Ticket: TICKET_40bf0d649fc60e16c6a591afd6a2a7633bda4c03
12:56:00,273 User:admin DEBUG [webservice.axis.TicketCallbackHandler] Ticket validated successfully
12:56:00,320 User:admin DEBUG [node.integrity.IncompleteNodeTagger] Added node reference to property set: workspace://SpacesStore/4bd46030-7406-4873-8
68d-5c9af4a90180
12:56:00,335 User:admin DEBUG [node.integrity.IntegrityChecker] Added event to event set:
event: IntegrityEvent[ name=org.alfresco.repo.node.integrity.PropertiesIntegrityEvent, nodeRef=workspace://SpacesStore/4bd46030-7406-4873-868d-5c9a
f4a90180]
12:56:00,335 User:admin DEBUG [webservice.content.ContentWebService] Updated content for node with id: 4bd46030-7406-4873-868d-5c9af4a90180
12:56:00,351 User:admin DEBUG [repo.webservice.Utils] setting path for reference to: /app:company_home/cm:Tartanga/cmepartamento2/cm_x003a_Web_x0020
_Services_x0020_sample_x0020_PRUEBA_x0020__x0028_1255690559132_x0029_
12:56:00,351 User:admin DEBUG [webservice.content.ContentWebService] Content: 4bd46030-7406-4873-868d-5c9af4a90180 name=Web Services sample PRUEBA (12
55690559132) encoding=UTF-8 mimetype=application/msword size=28160 downloadURL=http://localhost:8090/alfresco/download/direct/workspace/SpacesStore/4b
d46030-7406-4873-868d-5c9af4a90180/Web+Services+sample+PRUEBA+%281255690559132%29¿Alguna sugerencia de porque no me hace el update?muchas gracias