diff --git a/simulator/src/main/java/com/hedera/block/simulator/BlockStreamSimulator.java b/simulator/src/main/java/com/hedera/block/simulator/BlockStreamSimulator.java index 5344f689b..c376d2778 100644 --- a/simulator/src/main/java/com/hedera/block/simulator/BlockStreamSimulator.java +++ b/simulator/src/main/java/com/hedera/block/simulator/BlockStreamSimulator.java @@ -16,6 +16,8 @@ package com.hedera.block.simulator; +import static java.lang.System.Logger.Level.INFO; + import com.swirlds.config.api.Configuration; import com.swirlds.config.api.ConfigurationBuilder; import com.swirlds.config.extensions.sources.ClasspathFileConfigSource; @@ -40,7 +42,7 @@ private BlockStreamSimulator() {} */ public static void main(String[] args) throws IOException { - LOGGER.log(Logger.Level.INFO, "Starting Block Stream Simulator"); + LOGGER.log(INFO, "Starting Block Stream Simulator"); ConfigurationBuilder configurationBuilder = ConfigurationBuilder.create() diff --git a/simulator/src/main/java/com/hedera/block/simulator/config/data/GrpcConfig.java b/simulator/src/main/java/com/hedera/block/simulator/config/data/GrpcConfig.java index abfbd4a61..dea9e07d2 100644 --- a/simulator/src/main/java/com/hedera/block/simulator/config/data/GrpcConfig.java +++ b/simulator/src/main/java/com/hedera/block/simulator/config/data/GrpcConfig.java @@ -29,5 +29,5 @@ */ @ConfigData("grpc") public record GrpcConfig( - @ConfigProperty(defaultValue = "localhost") @Min(0) @Max(65535) String serverAddress, + @ConfigProperty(defaultValue = "localhost") String serverAddress, @ConfigProperty(defaultValue = "8080") @Min(0) @Max(65535) int port) {} diff --git a/simulator/src/main/java/com/hedera/block/simulator/config/types/GenerationMode.java b/simulator/src/main/java/com/hedera/block/simulator/config/types/GenerationMode.java index 5b637dcb1..cf61bdaab 100644 --- a/simulator/src/main/java/com/hedera/block/simulator/config/types/GenerationMode.java +++ b/simulator/src/main/java/com/hedera/block/simulator/config/types/GenerationMode.java @@ -19,7 +19,7 @@ /** The GenerationMode enum defines the modes of generation for the block stream. */ public enum GenerationMode { /** Reads Blocks from a Folder. */ - FOLDER, + DIR, /** Generates Blocks from rules */ - SELF + ADHOC } diff --git a/simulator/src/test/java/com/hedera/block/simulator/config/ConfigInjectionModuleTest.java b/simulator/src/test/java/com/hedera/block/simulator/config/ConfigInjectionModuleTest.java index 84846eae2..36126a4b1 100644 --- a/simulator/src/test/java/com/hedera/block/simulator/config/ConfigInjectionModuleTest.java +++ b/simulator/src/test/java/com/hedera/block/simulator/config/ConfigInjectionModuleTest.java @@ -52,7 +52,7 @@ void provideBlockStreamConfig() { ConfigInjectionModule.provideBlockStreamConfig(configuration); Assertions.assertNotNull(blockStreamConfig); - Assertions.assertEquals(GenerationMode.SELF, blockStreamConfig.generationMode()); + Assertions.assertEquals(GenerationMode.ADHOC, blockStreamConfig.generationMode()); } @Test diff --git a/simulator/src/test/java/com/hedera/block/simulator/config/types/GenerationModeTest.java b/simulator/src/test/java/com/hedera/block/simulator/config/types/GenerationModeTest.java index b78a41def..1a4448ffd 100644 --- a/simulator/src/test/java/com/hedera/block/simulator/config/types/GenerationModeTest.java +++ b/simulator/src/test/java/com/hedera/block/simulator/config/types/GenerationModeTest.java @@ -24,9 +24,9 @@ class GenerationModeTest { @Test void testGenerationMode() { - GenerationMode mode = GenerationMode.FOLDER; - assertEquals(GenerationMode.FOLDER, mode); - mode = GenerationMode.SELF; - assertEquals(GenerationMode.SELF, mode); + GenerationMode mode = GenerationMode.DIR; + assertEquals(GenerationMode.DIR, mode); + mode = GenerationMode.ADHOC; + assertEquals(GenerationMode.ADHOC, mode); } }