You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@manifoldcf.apache.org by kw...@apache.org on 2013/09/17 10:23:23 UTC

svn commit: r1523952 - in /manifoldcf/branches/CONNECTORS-772/connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint: SPSProxyHelper.java SharePointRepository.java

Author: kwright
Date: Tue Sep 17 08:23:22 2013
New Revision: 1523952

URL: http://svn.apache.org/r1523952
Log:
Update check() method to call new method if used

Modified:
    manifoldcf/branches/CONNECTORS-772/connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint/SPSProxyHelper.java
    manifoldcf/branches/CONNECTORS-772/connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint/SharePointRepository.java

Modified: manifoldcf/branches/CONNECTORS-772/connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint/SPSProxyHelper.java
URL: http://svn.apache.org/viewvc/manifoldcf/branches/CONNECTORS-772/connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint/SPSProxyHelper.java?rev=1523952&r1=1523951&r2=1523952&view=diff
==============================================================================
--- manifoldcf/branches/CONNECTORS-772/connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint/SPSProxyHelper.java (original)
+++ manifoldcf/branches/CONNECTORS-772/connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint/SPSProxyHelper.java Tue Sep 17 08:23:22 2013
@@ -1437,7 +1437,7 @@ public class SPSProxyHelper {
   * @throws javax.xml.rpc.ServiceException
   * @throws java.rmi.RemoteException
   */
-  public boolean checkConnection( String site, boolean sps30 )
+  public boolean checkConnection( String site, boolean sps30, boolean websBroken )
     throws ManifoldCFException, ServiceInterruption
   {
     long currentTime;
@@ -1456,15 +1456,16 @@ public class SPSProxyHelper {
       {
         // The web service allows us to get acls for a site, so that's what we will attempt
 
-        // This fails:
         MCPermissionsWS aclService = new MCPermissionsWS( baseUrl + site, userName, password, configuration, httpClient );
         com.microsoft.sharepoint.webpartpages.PermissionsSoap aclCall = aclService.getPermissionsSoapHandler( );
 
-        // This works:
-        //PermissionsWS aclService = new PermissionsWS( baseUrl + site, userName, password, myFactory, configuration );
-        //com.microsoft.schemas.sharepoint.soap.directory.PermissionsSoap aclCall = aclService.getPermissionsSoapHandler( );
-
         aclCall.getPermissionCollection( "/", "Web" );
+        
+        // SharePoint 2010-AWS: Make sure the plugin supports the webs fix
+        if (websBroken)
+        {
+          aclCall.getSites( );
+        }
       }
 
       return true;
@@ -1500,7 +1501,7 @@ public class SPSProxyHelper {
           else if (httpErrorCode.equals("403"))
             throw new ManifoldCFException("Http error "+httpErrorCode+" while reading from "+baseUrl+site+" - check IIS and SharePoint security settings! "+e.getMessage(),e);
 	  else if (httpErrorCode.equals("302"))
-	    throw new ManifoldCFException("ManifoldCF's MCPermissions web service may not be installed on the target SharePoint server.  MCPermissions service is needed for SharePoint repositories version 3.0 or higher, to allow access to security information for files and folders.  Consult your system administrator.");
+	    throw new ManifoldCFException("The correct version of ManifoldCF's MCPermissions web service may not be installed on the target SharePoint server.  MCPermissions service is needed for SharePoint repositories version 3.0 or higher, to allow access to security information for files and folders.  Consult your system administrator.");
           else
             throw new ManifoldCFException("Unexpected http error code "+httpErrorCode+" accessing SharePoint at "+baseUrl+site+": "+e.getMessage(),e);
         }

Modified: manifoldcf/branches/CONNECTORS-772/connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint/SharePointRepository.java
URL: http://svn.apache.org/viewvc/manifoldcf/branches/CONNECTORS-772/connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint/SharePointRepository.java?rev=1523952&r1=1523951&r2=1523952&view=diff
==============================================================================
--- manifoldcf/branches/CONNECTORS-772/connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint/SharePointRepository.java (original)
+++ manifoldcf/branches/CONNECTORS-772/connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint/SharePointRepository.java Tue Sep 17 08:23:22 2013
@@ -379,7 +379,7 @@ public class SharePointRepository extend
 
     try
     {
-      proxy.checkConnection( "/", supportsItemSecurity );
+      proxy.checkConnection( "/", supportsItemSecurity, websBroken );
     }
     catch ( ServiceInterruption e )
     {