timoninmaxim commented on code in PR #10527:
URL: https://github.com/apache/ignite/pull/10527#discussion_r1103064298
##########
modules/core/src/test/java/org/apache/ignite/testframework/junits/common/GridCommonAbstractTest.java:
##########
@@ -2810,4 +2815,35 @@ protected DistributedChangeableProperty<Serializable>
computeJobWorkerInterruptT
return timeoutProperty;
}
+
+ /** Clean work directory, excluding snapshot directory. */
+ protected IgniteEx restartWithCleanPersistence(int nodes,
Collection<String> caches) throws Exception {
+ stopAllGrids();
+
+ assertTrue(U.delete(Paths.get(U.defaultWorkDirectory(),
"cp").toFile()));
+ assertTrue(U.delete(Paths.get(U.defaultWorkDirectory(),
DFLT_MARSHALLER_PATH).toFile()));
+
+ deleteNodesDirs(nodes, DFLT_STORE_DIR, DFLT_BINARY_METADATA_PATH,
DFLT_WAL_PATH, DFLT_WAL_ARCHIVE_PATH);
+
+ IgniteEx ign = startGrids(nodes);
+
+ ign.cluster().state(ClusterState.ACTIVE);
+
+ // Destroy caches configured with IgniteConfiguration before restoring
snapshot.
+ ign.destroyCaches(caches);
Review Comment:
Cool, nice catch.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]