[Geoserver-devel] [JIRA] (GEOS-7380) Upgrade joda-time to support Amazon AWS S3 on Java 8u60 or later

Ben Caradoc-Davies [Administrator] created an issue

GeoServer / BugGEOS-7380

Upgrade joda-time to support Amazon AWS S3 on Java 8u60 or later

Issue Type:

BugBug

Affects Versions:

2.9-beta

Assignee:

Ben Caradoc-Davies [Administrator]

Components:

Global, GWC

Created:

17/Jan/16 10:58 PM

Environment:

Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015-11-11T05:41:47+13:00)
Maven home: /home/ben/java/maven
Java version: 1.8.0_72-internal, vendor: Oracle Corporation
Java home: /usr/lib/jvm/java-8-openjdk-amd64/jre
Default locale: en_GB, platform encoding: UTF-8
OS name: "linux", version: "4.3.0-1-amd64", arch: "amd64", family: "unix"

Priority:

MediumMedium

Reporter:

Ben Caradoc-Davies [Administrator]

joda-time before 2.8.1 causes Java 8u60 or later to fail to connect to Amazon AWS S3 with the error “AWS authentication requires a valid Date or x-amz-date header” when configuring a GeoWebCache S3 blob store via the GeoServer web interface:

See:
https://github.com/JodaOrg/joda-time/issues/288
https://github.com/aws/aws-sdk-java/issues/444
https://github.com/aws/aws-sdk-java/issues/484
https://github.com/elastic/elasticsearch-cloud-aws/issues/233
https://issues.jenkins-ci.org/browse/JENKINS-30420

GeoWebCache gwc-aws-s3 unit tests pass with Java 8u72 because aws-java-sdk-core 1.9.30 depends on joda-time [2.2,), which resolves to the latest joda-time 2.9.1, which works with Java 8u72:
https://repo1.maven.org/maven2/com/amazonaws/aws-java-sdk-core/1.9.30/aws-java-sdk-core-1.9.30.pom

GeoServer has a fixed dependency on joda-time to 2.2, which satisfies the transitive dependency on aws-java-sdk-core via gs-gwc-s3, but is incompatible with Java 8u60 or later.

The solution is to change the GeoServer dependencyManagement version of joda-time to 2.8.1 or later. Although GeoWebCache gwc-aws-s3 is currently building against 2.9.1, later aws-java-sdk-core (e.g. 1.10.47) has a fixed dependency on 2.8.1 so it may be more consistent to fix the GeoServer dependency as joda-time 2.8.1:
https://repo1.maven.org/maven2/com/amazonaws/aws-java-sdk-core/1.10.47/aws-java-sdk-core-1.10.47.pom

We could instead use explicit dependencies for both GeoServer and GeoWebCache on joda-time 2.9.1 and see if Maven can handle the version management.

There are other GeoServer modules that user joda-time.

Add Comment

Add Comment

This message was sent by Atlassian JIRA (v7.1.0-OD-04-012#71001-sha1:dd0493d)

Atlassian logo