Skip to content

Conversation

@nadeemb53
Copy link
Member

  • Modified DenyListManager and NullifierTracker to utilize gRPC for deny list operations and nullifier tracking.
  • Updated tests to reflect changes in deny list handling and nullifier tracking.
  • Adjusted Docker configurations to support new database schema for deny list and nullifiers.
  • Improved performance tests to validate high-throughput nullifier tracking and database persistence.

this(serviceName, 1_000_000L, nullifierExpiryHours); // Default to 1M capacity
LOG.info(
"{}: Using in-memory nullifier tracking (file path ignored for performance)", serviceName);
public NullifierTracker(String serviceName, String storagePath, long nullifierExpiryHours) {

Check notice

Code scanning / CodeQL

Useless parameter Note

The parameter 'storagePath' is never used.

Copilot Autofix

AI 1 day ago

To fix the problem, remove the unused parameter storagePath from the legacy constructor of NullifierTracker. This entails:

  • Edit the constructor signature at line 151 to remove the String storagePath parameter.
  • Remove mentions of storagePath in the Javadoc comment, updating @param accordingly.
  • Ensure the remaining constructor arguments still work as intended.
  • The log message inside this constructor already notes that the storage path is ignored, so it can remain, but the parameter string should be removed.
Suggested changeset 1
besu-plugins/linea-sequencer/sequencer/src/main/java/net/consensys/linea/sequencer/txpoolvalidation/shared/NullifierTracker.java

Autofix patch

Autofix patch
Run the following command in your local git repository to apply this patch
cat << 'EOF' | git apply
diff --git a/besu-plugins/linea-sequencer/sequencer/src/main/java/net/consensys/linea/sequencer/txpoolvalidation/shared/NullifierTracker.java b/besu-plugins/linea-sequencer/sequencer/src/main/java/net/consensys/linea/sequencer/txpoolvalidation/shared/NullifierTracker.java
--- a/besu-plugins/linea-sequencer/sequencer/src/main/java/net/consensys/linea/sequencer/txpoolvalidation/shared/NullifierTracker.java
+++ b/besu-plugins/linea-sequencer/sequencer/src/main/java/net/consensys/linea/sequencer/txpoolvalidation/shared/NullifierTracker.java
@@ -142,13 +142,12 @@
   }
 
   /**
-   * Legacy constructor for backward compatibility with file path parameter.
+   * Legacy constructor for backward compatibility.
    *
    * @param serviceName Service name for logging
-   * @param storagePath Ignored - DB storage is handled via gRPC
    * @param nullifierExpiryHours Expiry time in hours
    */
-  public NullifierTracker(String serviceName, String storagePath, long nullifierExpiryHours) {
+  public NullifierTracker(String serviceName, long nullifierExpiryHours) {
     this(serviceName, 1_000_000L, nullifierExpiryHours);
     LOG.info("{}: Storage path ignored - using PostgreSQL via gRPC", serviceName);
   }
EOF
@@ -142,13 +142,12 @@
}

/**
* Legacy constructor for backward compatibility with file path parameter.
* Legacy constructor for backward compatibility.
*
* @param serviceName Service name for logging
* @param storagePath Ignored - DB storage is handled via gRPC
* @param nullifierExpiryHours Expiry time in hours
*/
public NullifierTracker(String serviceName, String storagePath, long nullifierExpiryHours) {
public NullifierTracker(String serviceName, long nullifierExpiryHours) {
this(serviceName, 1_000_000L, nullifierExpiryHours);
LOG.info("{}: Storage path ignored - using PostgreSQL via gRPC", serviceName);
}
Copilot is powered by AI and may make mistakes. Always verify output.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants