Skip to content
This repository has been archived by the owner on Jul 23, 2024. It is now read-only.

Commit

Permalink
Merge pull request #374 from klaytn/release/v1.11.1
Browse files Browse the repository at this point in the history
[Master] release/v1.11.1 QA Sign-off
  • Loading branch information
JayChoi1736 authored Nov 2, 2023
2 parents 570b0d4 + bf068c1 commit b770d62
Show file tree
Hide file tree
Showing 12 changed files with 427 additions and 188 deletions.
13 changes: 11 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ check_test_network: &check_test_network
echo "Klaytn RPC server is up"
break
else
echo "wait for Klyatn RPC server..."
echo "wait for Klaytn RPC server..."
sleep 5
fi
RETRY=$(($RETRY+5))
Expand Down Expand Up @@ -136,11 +136,17 @@ jobs:
- *pull_klaytn_image
- *start_test_network
- *check_test_network
- run:
name: "Check environment"
command: java --version && gradle --version
- run:
name: "Test"
command: ./gradlew clean test --debug
command: ./gradlew clean test --debug --scan
- store_test_results:
path: core/build/test-results/test
- store_artifacts:
path: /home/circleci/circleci-caver-java-major/core/build/reports/tests/test
destination: test-output

build_test:
<<: *machine_ubuntu
Expand Down Expand Up @@ -195,6 +201,9 @@ jobs:
command: ./gradlew connectedDebugAndroidTest --debug --stacktrace
- store_test_results:
path: android_instrumented_test/build/outputs/androidTest-results/connected
- store_artifacts:
path: android_instrumented_test/build/reports/androidTests/connected/flavors/debugAndroidTest
destination: /test-report

build_test_android:
<<: *android_machine_ubuntu
Expand Down
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
# @global-owner1 and @global-owner2 will be requested for
# review when someone opens a pull request.
#* @global-owner1 @global-owner2
* @jimni1222 @kjeom @JayChoi1736 @henry-will @kjhman21
* @kjeom @JayChoi1736 @kjhman21

# Order is important; the last matching pattern takes the most
# precedence. When someone opens a pull request that only
Expand Down
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ apply plugin: 'io.codearte.nexus-staging'


allprojects {
version '1.10.2'
version '1.11.1'
group 'com.klaytn.caver'
description 'caver-java project'

Expand Down
17 changes: 13 additions & 4 deletions core/src/main/java/com/klaytn/caver/JsonRpc2_0Klay.java
Original file line number Diff line number Diff line change
Expand Up @@ -462,15 +462,24 @@ public Request<?, Quantity> getGasPrice() {
}

@Override
public Request<?, Quantity> getGasPriceAt(DefaultBlockParameter defaultBlockParameter) {
public Request<?, Quantity> getGasPrice(DefaultBlockParameter defaultBlockParameter) {
return new Request<>(
"klay_gasPriceAt",
"klay_gasPrice",
Arrays.asList(defaultBlockParameter),
web3jService,
Quantity.class
);
Quantity.class);
}

// @Override
// public Request<?, Quantity> getGasPriceAt(DefaultBlockParameter defaultBlockParameter) {
// return new Request<>(
// "klay_gasPriceAt",
// Arrays.asList(defaultBlockParameter),
// web3jService,
// Quantity.class
// );
// }

@Override
public Request<?, Boolean> isParallelDBWrite() {
return new Request<>(
Expand Down
13 changes: 12 additions & 1 deletion core/src/main/java/com/klaytn/caver/Klay.java
Original file line number Diff line number Diff line change
Expand Up @@ -408,7 +408,18 @@ Request<?, KlayTransaction> getTransactionByBlockNumberAndIndex(
* @param defaultBlockParameter Integer block number, or the string "latest", "earliest" or "pending"
* @return Quantity - Integer of the current gas price in peb.
*/
Request<?, Quantity> getGasPriceAt(DefaultBlockParameter defaultBlockParameter);
Request<?, Quantity> getGasPrice(DefaultBlockParameter defaultBlockParameter);


/**
* Returns the unit price of the given block in peb.<br>
* NOTE: This API has different behavior from Ethereum's and returns a gas price of Klaytn instead
* of suggesting a gas price as in Ethereum.
*
* @param defaultBlockParameter Integer block number, or the string "latest", "earliest" or "pending"
* @return Quantity - Integer of the current gas price in peb.
*/
// Request<?, Quantity> getGasPriceAt(DefaultBlockParameter defaultBlockParameter);


/**
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
/*
* Copyright 2022 The caver-java Authors
*
* Licensed under the Apache License, Version 2.0 (the “License”);
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an “AS IS” BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

package com.klaytn.caver.methods.response;

import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.Map;
import org.web3j.protocol.core.Response;

public class ForkStatusResult
extends Response<ForkStatusResult.ForkStatusData> {

public static class ForkStatusData {

@JsonProperty("EthTxType")
private Boolean EthTxType;

@JsonProperty("Istanbul")
private Boolean Istanbul;

@JsonProperty("KIP103")
private Boolean KIP103;

@JsonProperty("Kore")
private Boolean Kore;

@JsonProperty("London")
private Boolean London;

@JsonProperty("Magma")
private Boolean Magma;

@JsonProperty("Mantle")
private Boolean Mantle;

public ForkStatusData() {}
public ForkStatusData (
Boolean EthTxType,
Boolean Istanbul,
Boolean KIP103,
Boolean Kore,
Boolean London,
Boolean Magma,
Boolean Mantle
) {
this.EthTxType = EthTxType;
this.Istanbul = Istanbul;
this.KIP103 = KIP103;
this.Kore = Kore;
this.London = London;
this.Magma = Magma;
this.Mantle = Mantle;
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
/*
* Copyright 2020 The caver-java Authors
*
* Licensed under the Apache License, Version 2.0 (the “License”);
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an “AS IS” BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

package com.klaytn.caver.methods.response;

import java.util.Map;

import org.web3j.protocol.core.Response;

import com.fasterxml.jackson.annotation.JsonProperty;

import java.util.List;

public class RewardsAccumulated extends Response<RewardsAccumulated.RewardsAccumulatedData> {
public static class RewardsAccumulatedData {

@JsonProperty("firstBlockTime")
private String firstBlockTime;

@JsonProperty("lastBlockTime")
private String lastBlockTime;

@JsonProperty("firstBlock")
private String firstBlock;

@JsonProperty("lastBlock")
private String lastBlock;

@JsonProperty("totalMinted")
private String totalMinted;

@JsonProperty("totalTxFee")
private String totalTxFee;

@JsonProperty("totalBurntTxFee")
private String totalBurntTxFee;

@JsonProperty("totalProposerRewards")
private String totalProposerRewards;

@JsonProperty("totalStakingRewards")
private String totalStakingRewards;

@JsonProperty("totalKFFRewards")
private String totalKFFRewards;

@JsonProperty("totalKCFRewards")
private String totalKCFRewards;

/**
* mapping from reward recipient to amounts
*/
@JsonProperty("rewards")
private Map<String, String> rewards;

public RewardsAccumulatedData() {}
public RewardsAccumulatedData(
String firstBlockTime,
String lastBlockTime,
String firstBlock,
String lastBlock,
String totalMinted,
String totalTxFee,
String totalBurntTxFee,
String totalProposerRewards,
String totalStakingRewards,
String totalKFFRewards,
String totalKCFRewards,
Map<String, String> Rewards
) {
this.firstBlockTime = firstBlockTime;
this.lastBlockTime = lastBlockTime;
this.firstBlock = firstBlock;
this.lastBlock = lastBlock;
this.totalMinted = totalMinted;
this.totalTxFee = totalTxFee;
this.totalBurntTxFee = totalBurntTxFee;
this.totalProposerRewards = totalProposerRewards;
this.totalStakingRewards = totalStakingRewards;
this.totalKFFRewards = totalKFFRewards;
this.totalKCFRewards = totalKCFRewards;
this.rewards = rewards;
}
}
}
Loading

0 comments on commit b770d62

Please sign in to comment.