GeoServer

Trying to update a FeatureTypeInfo to point to a new StoreInfo leads to error

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 2.1.1
  • Fix Version/s: 2.1.2, 2.2.x
  • Component/s: Configuration
  • Labels:
    None
  • Patch Submitted:
    Yes
  • Number of attachments :
    2

Description

Use case is: trying to update a LayerInfo to point to a new StoreInfo. Internally, the correct procedure seems to be to update the LayerInfo's FeatureTypeInfo resource. However, if you try to do that you'll end up with file path problems because changing the store also changes the path where the 'featuretype.xml' and 'layer.xml' are expected to be.
A patch is provided to fix this in GeoServerPersister.java: it follows the same approach used when updating a given StoreInfo's workspace.

Activity

Hide
Justin Deoliveira added a comment -

Hi Milton, thanks for the patch, it makes sense. Any chance you could update GEoServerPersisterTest as well and add a quick test case?

Show
Justin Deoliveira added a comment - Hi Milton, thanks for the patch, it makes sense. Any chance you could update GEoServerPersisterTest as well and add a quick test case?
Hide
Milton Jonathan added a comment -

OK, Andrea, here it goes. The test did fail without the fix.

Show
Milton Jonathan added a comment - OK, Andrea, here it goes. The test did fail without the fix.
Hide
Justin Deoliveira added a comment -

Thanks for the patch (and the test) Milton!

Show
Justin Deoliveira added a comment - Thanks for the patch (and the test) Milton!
Hide
Andrea Aime added a comment -

Mass transition all resolved issue that did not see any further comment in the last month to closed status

Show
Andrea Aime added a comment - Mass transition all resolved issue that did not see any further comment in the last month to closed status

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: