manifoldcf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kwri...@apache.org
Subject svn commit: r1625442 - in /manifoldcf/branches/release-1.7-branch: ./ CHANGES.txt connectors/sharepoint/ connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint/SPSProxyHelper.java
Date Wed, 17 Sep 2014 00:54:29 GMT
Author: kwright
Date: Wed Sep 17 00:54:28 2014
New Revision: 1625442

URL: http://svn.apache.org/r1625442
Log:
Pull up fix for CONNECTORS-1013 from dev_1x branch

Modified:
    manifoldcf/branches/release-1.7-branch/   (props changed)
    manifoldcf/branches/release-1.7-branch/CHANGES.txt
    manifoldcf/branches/release-1.7-branch/connectors/sharepoint/   (props changed)
    manifoldcf/branches/release-1.7-branch/connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint/SPSProxyHelper.java

Propchange: manifoldcf/branches/release-1.7-branch/
------------------------------------------------------------------------------
  Merged /manifoldcf/trunk:r1619703

Modified: manifoldcf/branches/release-1.7-branch/CHANGES.txt
URL: http://svn.apache.org/viewvc/manifoldcf/branches/release-1.7-branch/CHANGES.txt?rev=1625442&r1=1625441&r2=1625442&view=diff
==============================================================================
--- manifoldcf/branches/release-1.7-branch/CHANGES.txt (original)
+++ manifoldcf/branches/release-1.7-branch/CHANGES.txt Wed Sep 17 00:54:28 2014
@@ -2,11 +2,15 @@ ManifoldCF Change Log
 $Id$
 
 
+======================= Release 1.7.1 =====================
+
 CONNECTORS-1031: Fix Zookeeper synchronization to be resilient
 against short tick time settings.
 (Karl Wright)
 
-======================= Release 1.7.1 =====================
+CONNECTORS-1013: Handle new kind of XML we see coming back from
+SharePoint on getLists metadata field list requests.
+(Lalit Jangra, Karl Wright)
 
 
 ======================= Release 1.7 =====================

Propchange: manifoldcf/branches/release-1.7-branch/connectors/sharepoint/
------------------------------------------------------------------------------
  Merged /manifoldcf/trunk/connectors/sharepoint:r1619703

Modified: manifoldcf/branches/release-1.7-branch/connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint/SPSProxyHelper.java
URL: http://svn.apache.org/viewvc/manifoldcf/branches/release-1.7-branch/connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint/SPSProxyHelper.java?rev=1625442&r1=1625441&r2=1625442&view=diff
==============================================================================
--- manifoldcf/branches/release-1.7-branch/connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint/SPSProxyHelper.java
(original)
+++ manifoldcf/branches/release-1.7-branch/connectors/sharepoint/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/sharepoint/SPSProxyHelper.java
Wed Sep 17 00:54:28 2014
@@ -1738,28 +1738,27 @@ public class SPSProxyHelper {
       nodeList.clear();
       doc.processPath(nodeList, "*", parent);  // <ns1:Fields>
 
-      Object fields = nodeList.get(0);
-      if ( !doc.getNodeName(fields).equals("ns1:Fields") )
-        throw new ManifoldCFException( "Bad xml - child node 0 '" + doc.getNodeName(fields)
+ "' is not 'ns1:Fields'");
-
-      nodeList.clear();
-      doc.processPath(nodeList, "*", fields);
-
-      int i = 0;
-      while (i < nodeList.size())
+      for (Object metaField : nodeList)
       {
-        Object o = nodeList.get( i++ );
-        // Logging.connectors.debug( i + ": " + o );
-        String name = doc.getValue( o, "DisplayName" );
-        String fieldName = doc.getValue( o, "Name" );
-        String hidden = doc.getValue( o, "Hidden" );
-        // System.out.println( "Hidden :" + hidden );
-        if ( name.length() != 0 && fieldName.length() != 0 && ( !hidden.equalsIgnoreCase(
"true") ) )
+        if ( doc.getNodeName(metaField).equals("ns1:Fields") )
         {
-          // make sure we don't include the same field more than once.
-          // This may happen if the Library has more than one view.
-          if ( result.containsKey( fieldName ) == false)
-            result.put(fieldName, name);
+          ArrayList fieldsList = new ArrayList();
+          doc.processPath(fieldsList, "*", metaField);
+
+          for (Object o : fieldsList)
+          {
+            String name = doc.getValue( o, "DisplayName" );
+            String fieldName = doc.getValue( o, "Name" );
+            String hidden = doc.getValue( o, "Hidden" );
+            // System.out.println( "Hidden :" + hidden );
+            if ( name.length() != 0 && fieldName.length() != 0 && ( !hidden.equalsIgnoreCase(
"true") ) )
+            {
+              // make sure we don't include the same field more than once.
+              // This may happen if the Library has more than one view.
+              if ( result.containsKey( fieldName ) == false)
+                result.put(fieldName, name);
+            }
+          }
         }
       }
       // System.out.println(result.size());



Mime
View raw message