diff --git a/gradle.properties b/gradle.properties index 9ed8fa7..9171047 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,3 +1,3 @@ -releaseVersion=0.3.2 -besuVersion=24.10.0 +releaseVersion=0.4.0 +besuVersion=24.12.1 diff --git a/gradle/versions.gradle b/gradle/versions.gradle index 52efced..f0f2dbe 100644 --- a/gradle/versions.gradle +++ b/gradle/versions.gradle @@ -59,7 +59,7 @@ dependencyManagement { } // junit - dependencySet(group: 'org.junit.jupiter', version: '5.8.2') { + dependencySet(group: 'org.junit.jupiter', version: '5.11.2') { entry 'junit-jupiter' entry 'junit-jupiter-api' entry 'junit-jupiter-engine' diff --git a/src/main/java/net/consensys/shomei/rpc/BesuShomeiRpcPlugin.java b/src/main/java/net/consensys/shomei/rpc/BesuShomeiRpcPlugin.java index b308402..c2cca98 100644 --- a/src/main/java/net/consensys/shomei/rpc/BesuShomeiRpcPlugin.java +++ b/src/main/java/net/consensys/shomei/rpc/BesuShomeiRpcPlugin.java @@ -21,8 +21,8 @@ import java.util.List; import com.google.auto.service.AutoService; -import org.hyperledger.besu.plugin.BesuContext; import org.hyperledger.besu.plugin.BesuPlugin; +import org.hyperledger.besu.plugin.ServiceManager; import org.hyperledger.besu.plugin.services.RpcEndpointService; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -32,13 +32,13 @@ public class BesuShomeiRpcPlugin implements BesuPlugin { private static final Logger LOG = LoggerFactory.getLogger(BesuShomeiRpcPlugin.class); @Override - public void register(final BesuContext context) { + public void register(final ServiceManager serviceManager) { LOG.debug("Registering RPC plugins"); var methods = List.of( new ShomeiGetTrieLogsByRange(ZkTrieLogService.getInstance()), new ShomeiGetTrieLog(ZkTrieLogService.getInstance())); - context + serviceManager .getService(RpcEndpointService.class) .ifPresent( rpcEndpointService -> diff --git a/src/main/java/net/consensys/shomei/trielog/ZkTrieLogPlugin.java b/src/main/java/net/consensys/shomei/trielog/ZkTrieLogPlugin.java index 78677c1..128f149 100644 --- a/src/main/java/net/consensys/shomei/trielog/ZkTrieLogPlugin.java +++ b/src/main/java/net/consensys/shomei/trielog/ZkTrieLogPlugin.java @@ -17,8 +17,8 @@ import java.util.Optional; import com.google.auto.service.AutoService; -import org.hyperledger.besu.plugin.BesuContext; import org.hyperledger.besu.plugin.BesuPlugin; +import org.hyperledger.besu.plugin.ServiceManager; import org.hyperledger.besu.plugin.services.PicoCLIOptions; import org.hyperledger.besu.plugin.services.TrieLogService; import org.slf4j.Logger; @@ -31,11 +31,11 @@ public class ZkTrieLogPlugin implements BesuPlugin { private static ShomeiCliOptions options = ShomeiCliOptions.create(); @Override - public void register(final BesuContext besuContext) { + public void register(final ServiceManager serviceManager) { LOG.info("Registering ZkTrieLog plugin"); LOG.debug("Adding command line params"); - final Optional cmdlineOptions = besuContext.getService(PicoCLIOptions.class); + final Optional cmdlineOptions = serviceManager.getService(PicoCLIOptions.class); if (cmdlineOptions.isEmpty()) { throw new IllegalStateException( @@ -43,7 +43,7 @@ public void register(final BesuContext besuContext) { } cmdlineOptions.get().addPicoCLIOptions(NAME, options); - besuContext.addService(TrieLogService.class, ZkTrieLogService.getInstance()); + serviceManager.addService(TrieLogService.class, ZkTrieLogService.getInstance()); } @Override