Nuno Oliveira ( 
https://osgeo-org.atlassian.net/secure/ViewProfile.jspa?accountId=557058%3A045c74f7-38ab-4dfa-af2b-2d9e961e7a48
 ) *created* an issue

GeoServer ( 
https://osgeo-org.atlassian.net/browse/GEOS?atlOrigin=eyJpIjoiZmNiY2Q4ZDZiOGFjNDJkNDkwYWNjN2FiMjYwNTBmZTUiLCJwIjoiaiJ9
 ) / New Feature ( 
https://osgeo-org.atlassian.net/browse/GEOS-9810?atlOrigin=eyJpIjoiZmNiY2Q4ZDZiOGFjNDJkNDkwYWNjN2FiMjYwNTBmZTUiLCJwIjoiaiJ9
 ) GEOS-9810 ( 
https://osgeo-org.atlassian.net/browse/GEOS-9810?atlOrigin=eyJpIjoiZmNiY2Q4ZDZiOGFjNDJkNDkwYWNjN2FiMjYwNTBmZTUiLCJwIjoiaiJ9
 ) [Backup & Restore] Restore will fail if two workspaces have a store with the 
same name ( 
https://osgeo-org.atlassian.net/browse/GEOS-9810?atlOrigin=eyJpIjoiZmNiY2Q4ZDZiOGFjNDJkNDkwYWNjN2FiMjYwNTBmZTUiLCJwIjoiaiJ9
 )

Issue Type: New Feature Affects Versions: 2.18.1 Assignee: Unassigned Created: 
26/Nov/20 5:37 PM Priority: Medium Reporter: Nuno Oliveira ( 
https://osgeo-org.atlassian.net/secure/ViewProfile.jspa?accountId=557058%3A045c74f7-38ab-4dfa-af2b-2d9e961e7a48
 )

To reproduce:

* Create two workspaces, and one store whit the same name on each workspace, 
and publish on layer from each store.
* Perform a backup using Backup and Restore.
* Restore the backup, the restore will fail with catalog validation error.

If the original workspaces are still around, the GeoServer data directory will 
be corrupted.

This happens because Backup and Restore always retrieves the resources by name 
when restoring, this happens here ( 
https://github.com/geoserver/geoserver/blob/b76bba7178d3505cd45e318e659c3b32faee4b5e/src/community/backup-restore/core/src/main/java/org/geoserver/backuprestore/writer/CatalogItemWriter.java#L45-L133
 ). It should instead retrive them by name and workspace.

( 
https://osgeo-org.atlassian.net/browse/GEOS-9810#add-comment?atlOrigin=eyJpIjoiZmNiY2Q4ZDZiOGFjNDJkNDkwYWNjN2FiMjYwNTBmZTUiLCJwIjoiaiJ9
 ) Add Comment ( 
https://osgeo-org.atlassian.net/browse/GEOS-9810#add-comment?atlOrigin=eyJpIjoiZmNiY2Q4ZDZiOGFjNDJkNDkwYWNjN2FiMjYwNTBmZTUiLCJwIjoiaiJ9
 )

Get Jira notifications on your phone! Download the Jira Cloud app for Android ( 
https://play.google.com/store/apps/details?id=com.atlassian.android.jira.core&referrer=utm_source%3DNotificationLink%26utm_medium%3DEmail
 ) or iOS ( 
https://itunes.apple.com/app/apple-store/id1006972087?pt=696495&ct=EmailNotificationLink&mt=8
 ) This message was sent by Atlassian Jira (v1001.0.0-SNAPSHOT#100151- 
sha1:c8fcc1e )
_______________________________________________
Geoserver-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-devel

Reply via email to