This is an automated email from the ASF dual-hosted git repository. iuliana pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/brooklyn-server.git
The following commit(s) were added to refs/heads/master by this push: new 6846fcd removing extra subdir causing import issues new a80e876 Merge pull request #1251 from zan-mateusz/fix/data-dir-not-present-for-persistence-import 6846fcd is described below commit 6846fcde9cc659075ed0c3c2a2fbd660659ae629 Author: zan-mateusz <mateusz....@cloudsoftcorp.com> AuthorDate: Tue Sep 7 16:37:35 2021 +0100 removing extra subdir causing import issues --- .../main/java/org/apache/brooklyn/rest/resources/ServerResource.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rest/rest-resources/src/main/java/org/apache/brooklyn/rest/resources/ServerResource.java b/rest/rest-resources/src/main/java/org/apache/brooklyn/rest/resources/ServerResource.java index 0d6b83e..9a7205e 100644 --- a/rest/rest-resources/src/main/java/org/apache/brooklyn/rest/resources/ServerResource.java +++ b/rest/rest-resources/src/main/java/org/apache/brooklyn/rest/resources/ServerResource.java @@ -527,7 +527,7 @@ public class ServerResource extends AbstractBrooklynRestResource implements Serv BrooklynPersistenceUtils.writeMemento(mgmt(), targetStore, preferredOrigin); ByteArrayOutputStream baos = new ByteArrayOutputStream(); - ArchiveBuilder.zip().addDirContentsAt( ((FileBasedObjectStore)targetStore).getBaseDir(), ((FileBasedObjectStore)targetStore).getBaseDir().getName() + "/data" ).stream(baos); + ArchiveBuilder.zip().addDirContentsAt( ((FileBasedObjectStore)targetStore).getBaseDir(), "data" ).stream(baos); Os.deleteRecursively(dir); String filename = "brooklyn-state-"+label+".zip"; return Response.ok(baos.toByteArray(), MediaType.APPLICATION_OCTET_STREAM_TYPE)