-
Notifications
You must be signed in to change notification settings - Fork 867
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature addition for tracing private transactions #5534
Conversation
|
4e0e4b1
to
aef0213
Compare
...yperledger/besu/ethereum/api/jsonrpc/internal/privacy/methods/priv/PrivTraceTransaction.java
Fixed
Show fixed
Hide fixed
aef0213
to
e38b014
Compare
...ledger/besu/ethereum/api/jsonrpc/internal/processor/privateProcessor/PrivateBlockReplay.java
Dismissed
Show dismissed
Hide dismissed
...ledger/besu/ethereum/api/jsonrpc/internal/processor/privateProcessor/PrivateBlockReplay.java
Dismissed
Show dismissed
Hide dismissed
e38b014
to
f188cb6
Compare
...besu/ethereum/api/jsonrpc/internal/results/privacy/privateTracing/PrivateTraceGenerator.java
Dismissed
Show dismissed
Hide dismissed
...besu/ethereum/api/jsonrpc/internal/results/privacy/privateTracing/PrivateTraceGenerator.java
Dismissed
Show dismissed
Hide dismissed
...besu/ethereum/api/jsonrpc/internal/results/privacy/privateTracing/PrivateTraceGenerator.java
Dismissed
Show dismissed
Hide dismissed
2d6e2ae
to
cfaf6ee
Compare
@NickSneo for context can you add notes on any testing you've done with this in privacy-enabled networks? |
Hey @macfarla , sorry for the delay in replying
Then I called the same api from node with no access to private tx -
Seems the API is working fine. Planning to add the tests for this feature in another PR, since this PR is already very big |
Hey @macfarla , can you please review the PR
|
...yperledger/besu/ethereum/api/jsonrpc/internal/privacy/methods/priv/PrivTraceTransaction.java
Outdated
Show resolved
Hide resolved
...dger/besu/ethereum/api/jsonrpc/internal/privacy/methods/priv/PrivateAbstractTraceByHash.java
Outdated
Show resolved
Hide resolved
...ledger/besu/ethereum/api/jsonrpc/internal/processor/privateProcessor/PrivateBlockReplay.java
Outdated
Show resolved
Hide resolved
...rledger/besu/ethereum/api/jsonrpc/internal/processor/privateProcessor/PrivateBlockTrace.java
Outdated
Show resolved
Hide resolved
...ledger/besu/ethereum/api/jsonrpc/internal/processor/privateProcessor/PrivateBlockTracer.java
Outdated
Show resolved
Hide resolved
...hyperledger/besu/ethereum/api/jsonrpc/internal/processor/privateProcessor/PrivateTracer.java
Outdated
Show resolved
Hide resolved
...r/besu/ethereum/api/jsonrpc/internal/processor/privateProcessor/PrivateTransactionTrace.java
Outdated
Show resolved
Hide resolved
...dger/besu/ethereum/api/jsonrpc/internal/results/privacy/privateTracing/PrivateFlatTrace.java
Outdated
Show resolved
Hide resolved
...besu/ethereum/api/jsonrpc/internal/results/privacy/privateTracing/PrivateTraceGenerator.java
Outdated
Show resolved
Hide resolved
Hey @pinges , can you please review this PR? |
...dger/besu/ethereum/api/jsonrpc/internal/privacy/methods/priv/PrivateAbstractTraceByHash.java
Outdated
Show resolved
Hide resolved
...dger/besu/ethereum/api/jsonrpc/internal/privacy/methods/priv/PrivateAbstractTraceByHash.java
Outdated
Show resolved
Hide resolved
final String privacyGroupId) { | ||
return (transaction, header, blockchain, transactionProcessor, dataGasPrice) -> { | ||
// if we have no prior updater, it must be the first TX, so use the block's initial state | ||
if (chainedUpdater == null) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
won't chainedUpdater always be null at this point since it doesn't get set until below?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am using the same logic as used in BlockTracer, just added extra logic for PrivateTransaction type and private world states.
Also I guess it will be null for first transaction only, once updater is set it will reuse it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Line 59 in 7605351
if (chainedUpdater == null) { |
...hyperledger/besu/ethereum/api/jsonrpc/internal/processor/privateProcessor/PrivateTracer.java
Outdated
Show resolved
Hide resolved
...dger/besu/ethereum/api/jsonrpc/internal/privacy/methods/priv/PrivateAbstractTraceByHash.java
Outdated
Show resolved
Hide resolved
...dger/besu/ethereum/api/jsonrpc/internal/privacy/methods/priv/PrivateAbstractTraceByHash.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Nischal Sharma <nischal@web3labs.com>
Signed-off-by: Nischal Sharma <nischal@web3labs.com>
Signed-off-by: Nischal Sharma <nischal@web3labs.com>
Signed-off-by: Nischal Sharma <nischal@web3labs.com>
Signed-off-by: Nischal Sharma <nischal@web3labs.com>
Signed-off-by: Nischal Sharma <nischal@web3labs.com>
Signed-off-by: Nischal Sharma <nischal@web3labs.com>
Signed-off-by: Nischal Sharma <nischal@web3labs.com>
Signed-off-by: Nischal Sharma <nischal@web3labs.com>
Signed-off-by: Nischal Sharma <nischal@web3labs.com>
Signed-off-by: Nischal Sharma <nischal@web3labs.com>
* Accept input or data as payload for RPC calls Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com> * Add json new rpc valid and invalid request to test the changes Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com> * Change JsonCallParameter signature to avoid duplicating constructor Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com> * Add changelog Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com> --------- Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
* Fix some typos * Update plugin version Signed-off-by: GoodDaisy <90915921+GoodDaisy@users.noreply.github.com> --------- Signed-off-by: GoodDaisy <90915921+GoodDaisy@users.noreply.github.com>
* Correct reference test blobgas calculation Fix tpyo that resulted in an NPE in t8n blob gas calculations. Signed-off-by: Danno Ferrin <danno.ferrin@swirldslabs.com> * changelog Signed-off-by: Danno Ferrin <danno.ferrin@swirldslabs.com> * spotless Signed-off-by: Danno Ferrin <danno.ferrin@swirldslabs.com> --------- Signed-off-by: Danno Ferrin <danno.ferrin@swirldslabs.com>
Makes Idea happy again as documented here https://docs.gradle.org/6.8.3/userguide/dependency_verification.html#sec:skipping-javadocs Signed-off-by: Fabio Di Fabio <fabio.difabio@consensys.net>
Signed-off-by: Fabio Di Fabio <fabio.difabio@consensys.net>
…perledger#6067) * Don't put NONCE_TOO_LOW transactions into the invalid nonce cache Signed-off-by: Matthew Whitehead <matthew1001@gmail.com> * Update unit tests Signed-off-by: Matthew Whitehead <matthew1001@gmail.com> * Use list of errors to ignore Signed-off-by: Matthew Whitehead <matthew1001@gmail.com> --------- Signed-off-by: Matthew Whitehead <matthew1001@gmail.com> Signed-off-by: Matt Whitehead <matthew1001@gmail.com> Signed-off-by: Fabio Di Fabio <fabio.difabio@consensys.net> Co-authored-by: Fabio Di Fabio <fabio.difabio@consensys.net>
Introduce a new Journaled World State Updater. Within a transaction it keeps one copy of account and storage state, restoring previous revisions on reverts and exceptional halts. This updater only supports post-merge semantics with regard to empty accounts, namely that they do not exist in world state. Adds an EvmConfiguration option for stacked vs journaled updater, and wire it in where needed. The staked updater is default mode, which is the current behavior prior to this patch. Signed-off-by: Danno Ferrin <danno.ferrin@swirldslabs.com>
…imal instead of Long (hyperledger#6099) Signed-off-by: Gabriel-Trintinalia <gabriel.trintinalia@consensys.net>
Signed-off-by: Gabriel-Trintinalia <gabriel.trintinalia@consensys.net>
…dger#6083) Signed-off-by: Gabriel-Trintinalia <gabriel.trintinalia@consensys.net>
…ledger#6082) Signed-off-by: Jason Frame <jason.frame@consensys.net>
There was a slight problem on the bonsai side because all account reads did not go through a single method. One of the two add the account to the cache but the other did not. This had two consequences: Less good performance because certain accounts had to be read several times and also all account reads were not marked in the trielog. This will fix both problems. Signed-off-by: Karim TAAM <karim.t2am@gmail.com>
v13 of the official Ethereum Reference Tests. Signed-off-by: Danno Ferrin <danno.ferrin@swirldslabs.com>
* clean up Signed-off-by: stefan.pingel@consensys.net <stefan.pingel@consensys.net>
Signed-off-by: Matthew Whitehead <matthew1001@gmail.com>
Update the GraphQL and JSON-RPC endpoints to provide `yParity` instead of `v` for non-legacy transactions. Update the JSON-RPC tests to use the Hive data. Add tests for Shanghai and Cancun Blocks. Signed-off-by: Danno Ferrin <danno.ferrin@swirldslabs.com>
Signed-off-by: stefan.pingel@consensys.net <stefan.pingel@consensys.net>
* Revert "Log missing chain head as warning, not trace (hyperledger#6127)" * leave chain head at warning, just revert the discard warning Signed-off-by: garyschulte <garyschulte@gmail.com>
* Reverse added order and sequence number Signed-off-by: Matthew Whitehead <matthew1001@gmail.com> * Remove extraneous 'addedAt' check Signed-off-by: Matthew Whitehead <matthew1001@gmail.com> --------- Signed-off-by: Matthew Whitehead <matthew1001@gmail.com>
…configured (hyperledger#6079) Signed-off-by: Fabio Di Fabio <fabio.difabio@consensys.net>
Signed-off-by: Fabio Di Fabio <fabio.difabio@consensys.net> Co-authored-by: Sally MacFarlane <macfarla.github@gmail.com>
Signed-off-by: Jason Frame <jason.frame@consensys.net>
…ution (hyperledger#6102) * Delete leftPad when capturing the stack before and after the execution * Still use leftPad when displaying the stack in the output (ex. for debug_traceTransaction) * Fix integration test * Use StringBuilder to left pad the hex representation of a 32 bytes Signed-off-by: Ameziane H <ameziane.hamlat@consensys.net>
Fix the flakeiness in EthGetTransactionByHashTest as well as some other sonar identified cleanup. Signed-off-by: Danno Ferrin <danno.ferrin@swirldslabs.com>
hyperledger#6146) * Apply the same reverse sort order as hyperledger#6106 but to the base fee sorter Signed-off-by: Matthew Whitehead <matthew1001@gmail.com> * Fix unit tests Signed-off-by: Matthew Whitehead <matthew1001@gmail.com> * Update eviction unit tests to expect highest-sequence TXs be evicted first Signed-off-by: Matthew Whitehead <matthew1001@gmail.com> * Update change log Signed-off-by: Matthew Whitehead <matthew1001@gmail.com> * Spotless fixes Signed-off-by: Matthew Whitehead <matthew1001@gmail.com> --------- Signed-off-by: Matthew Whitehead <matthew1001@gmail.com>
Signed-off-by: Matthew Whitehead <matthew1001@gmail.com>
Signed-off-by: Justin Florentine <justin+github@florentine.us>
Closing this PR. |
PR description
PR for adding priv_traceTransaction API
Fixed Issue(s)
#5280