-
Notifications
You must be signed in to change notification settings - Fork 108
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
feat: Add new opcodes endpoint #8245
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Konstantina Blazhukova <konstantina.blajukova@gmail.com>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
hedera-mirror-web3/src/main/java/com/hedera/mirror/web3/controller/OpcodesController.java
Outdated
Show resolved
Hide resolved
hedera-mirror-web3/src/main/java/com/hedera/mirror/web3/controller/OpcodesController.java
Outdated
Show resolved
Hide resolved
hedera-mirror-web3/src/main/java/com/hedera/mirror/web3/controller/OpcodesController.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Need to also add this endpoint to the ingress routes in the web3 helm chart. |
Will be done in the PR for the integration tests. |
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
# Conflicts: # hedera-mirror-web3/src/main/java/com/hedera/mirror/web3/controller/ContractController.java # hedera-mirror-web3/src/main/java/com/hedera/mirror/web3/service/ContractCallService.java # hedera-mirror-web3/src/test/java/com/hedera/mirror/web3/service/ContractCallServiceTest.java
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
…acheManagerRecordFileTimestamp() Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
…ed for receiver and sender Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
…Result Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
…hParameter Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
hedera-mirror-web3/src/main/java/com/hedera/mirror/web3/controller/OpcodesController.java
Outdated
Show resolved
Hide resolved
hedera-mirror-web3/src/main/java/com/hedera/mirror/web3/controller/OpcodesController.java
Outdated
Show resolved
Hide resolved
hedera-mirror-web3/src/test/java/com/hedera/mirror/web3/common/TransactionIdParameterTest.java
Outdated
Show resolved
Hide resolved
hedera-mirror-web3/src/test/java/com/hedera/mirror/web3/common/TransactionIdParameterTest.java
Outdated
Show resolved
Hide resolved
hedera-mirror-web3/src/test/java/com/hedera/mirror/web3/common/TransactionIdParameterTest.java
Outdated
Show resolved
Hide resolved
...irror-web3/src/test/java/com/hedera/mirror/web3/common/TransactionIdOrHashParameterTest.java
Outdated
Show resolved
Hide resolved
hedera-mirror-web3/src/main/java/com/hedera/mirror/web3/service/OpcodeServiceImpl.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
…pcodeService` Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
…onIdParameterTest Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
hedera-mirror-web3/src/main/java/com/hedera/mirror/web3/evm/config/EvmConfiguration.java
Outdated
Show resolved
Hide resolved
hedera-mirror-web3/src/main/java/com/hedera/mirror/web3/common/TransactionIdParameter.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
# Conflicts: # docs/configuration.md # hedera-mirror-web3/src/main/java/com/hedera/mirror/web3/evm/config/EvmConfiguration.java
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
…reAfterAccess` Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
Quality Gate passedIssues Measures |
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.
LGTM
Description:
This MR adds the following changes:
TransactionIdOrHashParameter
^(0x)?([0-9A-Fa-f]{64})$
^(\\d+)\\.(\\d+)\\.(\\d+)-(\\d{1,19})-(\\d{1,9})$
OpcodeSerivce
:ContractCallServiceParameters
:ContractTransactionHash
EthereumTransaction
ContractResult
ContractCallServiceParameters
from the fetched dataTransaction
EthereumTransaction
ContractResult
ContractCallServiceParameters
from the fetched dataOpcodesResponse
from theOpcodesProcessingResult
which is after callingContractCallService
:EntityDatabaseAccessor
to the get the EVM addresses of the sender and the receiverOpcodesController
:hedera.mirror.opcode.tracer.enabled
(false
by default)/api/v1/contracts/results/{transactionIdOrHash}/opcodes
OpcodeService
to construct theCallServiceParameters
from the giventransactionIdOrHash
processOpcodeCall
method inContractCallService
OpcodeService
to build anOpcodesResponse
from the resultMore info can be found here.
Related issue(s):
Fixes #8174
Notes for reviewer:
The actual logic for
ContractCallService.processOpcodeCall
is currently in progress in another PR.I've added it as an empty method which throws
UnsupportedOperationException
.Tests Added
OpcodesControllerTests
:CallServiceParameters
for different type of transactions:OpcodesResponse
with different values passed forstack
,memory
andstorage
TransactionProviderEnum
:Legacy
,EIP-1559
,EIP-2930
transactions which are used throughout the testsChecklist