Author: kwright
Date: Sat Oct 4 12:11:09 2014
New Revision: 1629376
URL: http://svn.apache.org/r1629376
Log:
Pull up fix for CONNECTORS-1055 from trunk.
Modified:
manifoldcf/branches/dev_1x/ (props changed)
manifoldcf/branches/dev_1x/CHANGES.txt
manifoldcf/branches/dev_1x/framework/core/pom.xml
manifoldcf/branches/dev_1x/framework/core/src/main/java/org/apache/manifoldcf/core/common/DateParser.java
manifoldcf/branches/dev_1x/framework/core/src/test/java/org/apache/manifoldcf/core/common/DateTest.java
Propchange: manifoldcf/branches/dev_1x/
------------------------------------------------------------------------------
Merged /manifoldcf/trunk:r1629375
Modified: manifoldcf/branches/dev_1x/CHANGES.txt
URL:
http://svn.apache.org/viewvc/manifoldcf/branches/dev_1x/CHANGES.txt?rev=1629376&r1=1629375&r2=1629376&view=diff
==============================================================================
--- manifoldcf/branches/dev_1x/CHANGES.txt (original)
+++ manifoldcf/branches/dev_1x/CHANGES.txt Sat Oct 4 12:11:09 2014
@@ -3,6 +3,9 @@ $Id$
======================= 1.8-dev =====================
+CONNECTORS-1055: Fix Zulu date parsing.
+(Karl Wright)
+
CONNECTORS-1043: Wrong url generated for SharePoint list items.
(Lalit Jangra, Karl Wright)
Modified: manifoldcf/branches/dev_1x/framework/core/pom.xml
URL:
http://svn.apache.org/viewvc/manifoldcf/branches/dev_1x/framework/core/pom.xml?rev=1629376&r1=1629375&r2=1629376&view=diff
==============================================================================
--- manifoldcf/branches/dev_1x/framework/core/pom.xml (original)
+++ manifoldcf/branches/dev_1x/framework/core/pom.xml Sat Oct 4 12:11:09 2014
@@ -55,7 +55,7 @@
</build>
<dependencies>
- <dependency>
+ <dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>${httpcomponent.httpclient.version}</version>
Modified:
manifoldcf/branches/dev_1x/framework/core/src/main/java/org/apache/manifoldcf/core/common/DateParser.java
URL:
http://svn.apache.org/viewvc/manifoldcf/branches/dev_1x/framework/core/src/main/java/org/apache/manifoldcf/core/common/DateParser.java?rev=1629376&r1=1629375&r2=1629376&view=diff
==============================================================================
---
manifoldcf/branches/dev_1x/framework/core/src/main/java/org/apache/manifoldcf/core/common/DateParser.java
(original)
+++
manifoldcf/branches/dev_1x/framework/core/src/main/java/org/apache/manifoldcf/core/common/DateParser.java
Sat Oct 4 12:11:09 2014
@@ -51,7 +51,10 @@ public class DateParser
if (isoDateValue.indexOf(".") != -1)
isoFormatString.append(".SSS");
if (isoDateValue.endsWith("Z"))
- isoFormatString.append("'Z'");
+ {
+ isoDateValue = isoDateValue.substring(0,isoDateValue.length()-1) +
"-0000";
+ isoFormatString.append("Z");
+ }
else
{
// We need to be able to parse either "-08:00" or "-0800". The 'Z'
specifier only handles
Modified:
manifoldcf/branches/dev_1x/framework/core/src/test/java/org/apache/manifoldcf/core/common/DateTest.java
URL:
http://svn.apache.org/viewvc/manifoldcf/branches/dev_1x/framework/core/src/test/java/org/apache/manifoldcf/core/common/DateTest.java?rev=1629376&r1=1629375&r2=1629376&view=diff
==============================================================================
---
manifoldcf/branches/dev_1x/framework/core/src/test/java/org/apache/manifoldcf/core/common/DateTest.java
(original)
+++
manifoldcf/branches/dev_1x/framework/core/src/test/java/org/apache/manifoldcf/core/common/DateTest.java
Sat Oct 4 12:11:09 2014
@@ -31,8 +31,9 @@ public class DateTest
{
Date d = DateParser.parseISO8601Date("96-11-15T01:32:33.344GMT");
assertNotNull(d);
- d = DateParser.parseISO8601Date("2012-11-15T01:32:33.344Z");
- assertNotNull(d);
+ Date d2 = DateParser.parseISO8601Date("1996-11-15T01:32:33.344Z");
+ assertNotNull(d2);
+ assertEquals(d,d2);
d = DateParser.parseISO8601Date("2012-11-15T01:32:33Z");
assertNotNull(d);
d = DateParser.parseISO8601Date("2012-11-15T01:32:33+0100");