incubator-connectors-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From piergior...@apache.org
Subject svn commit: r1207976 - /incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/alfresco/AlfrescoRepositoryConnector.java
Date Tue, 29 Nov 2011 17:20:08 GMT
Author: piergiorgio
Date: Tue Nov 29 17:20:07 2011
New Revision: 1207976

URL: http://svn.apache.org/viewvc?rev=1207976&view=rev
Log:
added the exception handling for the WebServiceException thrown by the Afresco Web Services
API

Modified:
    incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/alfresco/AlfrescoRepositoryConnector.java

Modified: incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/alfresco/AlfrescoRepositoryConnector.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/alfresco/AlfrescoRepositoryConnector.java?rev=1207976&r1=1207975&r2=1207976&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/alfresco/AlfrescoRepositoryConnector.java
(original)
+++ incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/alfresco/AlfrescoRepositoryConnector.java
Tue Nov 29 17:20:07 2011
@@ -20,6 +20,7 @@ import org.alfresco.webservice.types.Res
 import org.alfresco.webservice.types.ResultSetRow;
 import org.alfresco.webservice.util.AuthenticationDetails;
 import org.alfresco.webservice.util.AuthenticationUtils;
+import org.alfresco.webservice.util.WebServiceException;
 import org.alfresco.webservice.util.WebServiceFactory;
 import org.apache.commons.io.IOUtils;
 import org.apache.commons.lang.StringUtils;
@@ -152,6 +153,14 @@ public class AlfrescoRepositoryConnector
               + e.getMessage(), e);
       throw new ManifoldCFException("Alfresco: Error during authentication. Username: "+username
+ ", endpoint: "+endpoint
           + e.getMessage(), e);
+    } catch (WebServiceException e){
+      Logging.connectors.warn(
+          "Alfresco: Error during trying to authenticate the user. Username: "+username +
", endpoint: "+endpoint
+          +". Please check the connector parameters. " 
+          + e.getMessage(), e);
+      throw new ManifoldCFException("Alfresco: Error during trying to authenticate the user.
Username: "+username + ", endpoint: "+endpoint
+          +". Please check the connector parameters. "
+          + e.getMessage(), e);
     }
     
     lastSessionFetch = System.currentTimeMillis();



Mime
View raw message