PostGIS dialect may not honor the provided geometry factory

Description

This happens if the same thread is calling on the read twice with different geometry factories, the thread local used to avoid reallocating the byte[] used for decoding is not updated (the thread local was added to get measurable speedups in map rendering).

Environment

None

Activity

Show:
codehaus
April 10, 2015, 3:01 PM

CodeHaus Comment From: aaime - Time: Thu, 28 Apr 2011 05:59:47 -0500
---------------------
Hi,

sorry to bother you for a PostGIS specific issue, the attached patch also adds a new unit test checking that we're actually respecting the geometry factory provided as part of the hints.

Which is something we should do, but a badly implemented dialect might in fact not use the provided geometry factory when decoding the geometries.

I've checked the patch works on H2, PostGIS and Oracle, reviewed the code in DB2, Spatialite and Teradata and they all seem to be using the geometry factory as expected, but if you want to double check here is the patch.

codehaus
April 10, 2015, 3:01 PM

CodeHaus Comment From: aaime - Time: Tue, 3 May 2011 03:41:26 -0500
---------------------
Fixed on 2.7.x and trunk

Andrea Aime
February 15, 2017, 11:45 AM

Mass closing all resolved issues not modified in the last 4 weeks

Fixed

Assignee

Unassigned

Reporter

codehaus

Triage

None

Components

Fix versions

Affects versions

Priority

Medium
Configure