Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion docs/implement-a-customized-actuator-en.md
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ public class SumActuatorTest {
appTest.startServices();
appTest.startup();
channelFull = ManagedChannelBuilder.forTarget(serviceNode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);
}
Expand Down
2 changes: 1 addition & 1 deletion docs/implement-a-customized-actuator-zh.md
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ public class SumActuatorTest {
appTest.startServices();
appTest.startup();
channelFull = ManagedChannelBuilder.forTarget(serviceNode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public class CreateCommonTransactionTest {
*/
public static void testCreateUpdateBrokerageContract() {
WalletBlockingStub walletStub = WalletGrpc
.newBlockingStub(ManagedChannelBuilder.forTarget(FULL_NODE).usePlaintext(true).build());
.newBlockingStub(ManagedChannelBuilder.forTarget(FULL_NODE).usePlaintext().build());
UpdateBrokerageContract.Builder updateBrokerageContract = UpdateBrokerageContract.newBuilder();
updateBrokerageContract.setOwnerAddress(
ByteString.copyFrom(decodeFromBase58Check("TN3zfjYUmMFK3ZsHSsrdJoNRtGkQmZLBLz")))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public DelegationServiceTest(TronApplicationContext context) {
public static void testGrpc() {
WalletBlockingStub walletStub = WalletGrpc
.newBlockingStub(ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build());
BytesMessage.Builder builder = BytesMessage.newBuilder();
builder.setValue(ByteString.copyFromUtf8("TLTDZBcPoJ8tZ6TTEeEqEvwYFk2wgotSfD"));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public void test() {
public void testGrpc() {
WalletBlockingStub walletStub = WalletGrpc
.newBlockingStub(ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build());
logger.info("getNodeInfo: {}", walletStub.getNodeInfo(EmptyMessage.getDefaultInstance()));
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public void init() {
public void listNodesTest() {
WalletGrpc.WalletBlockingStub walletStub = WalletGrpc
.newBlockingStub(ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build());
Assert.assertTrue(walletStub.listNodes(EmptyMessage.getDefaultInstance())
.getNodesList().size() == 0);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,10 @@ public void init() {
String pBFTNode = String.format("%s:%d", Args.getInstance().getNodeDiscoveryBindIp(),
Args.getInstance().getRpcOnPBFTPort());
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
channelpBFT = ManagedChannelBuilder.forTarget(pBFTNode)
.usePlaintext(true)
.usePlaintext()
.build();
context = new TronApplicationContext(DefaultConfig.class);
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,10 @@ public void startApp() {
appTest.startup();

String fullNode = String.format("%s:%d", "127.0.0.1",
Args.getInstance().getRpcPort());
ManagedChannel channelFull = ManagedChannelBuilder.forTarget(fullNode)
.usePlaintext()
.build();
Args.getInstance().getRpcPort());
channelFull = ManagedChannelBuilder.forTarget(fullNode)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,22 +53,22 @@ public class BrokerageTest001 {
public void beforeClass() {

channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);

channelSolidity = ManagedChannelBuilder.forTarget(soliditynode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubSolidity = WalletSolidityGrpc.newBlockingStub(channelSolidity);

channelSoliInFull = ManagedChannelBuilder.forTarget(soliInFullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubSoliInFull = WalletSolidityGrpc.newBlockingStub(channelSoliInFull);

channelPbft = ManagedChannelBuilder.forTarget(soliInPbft)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubPbft = WalletSolidityGrpc.newBlockingStub(channelPbft);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,12 +50,12 @@ public class WalletTestAccount001 {
@BeforeClass
public void beforeClass() {
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);

channelSolidity = ManagedChannelBuilder.forTarget(soliditynode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubSolidity = WalletSolidityGrpc.newBlockingStub(channelSolidity);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ public static String getRandomStr(int length) {
public void beforeClass() {
PublicMethed.printAddress(lowBalTest);
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,12 +68,12 @@ public static String loadPubKey() {
@BeforeClass
public void beforeClass() {
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);

searchChannelFull = ManagedChannelBuilder.forTarget(searchFullnode)
.usePlaintext(true)
.usePlaintext()
.build();
searchBlockingStubFull = WalletGrpc.newBlockingStub(searchChannelFull);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,12 +68,12 @@ public static String loadPubKey() {
@BeforeClass
public void beforeClass() {
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);

searchChannelFull = ManagedChannelBuilder.forTarget(searchFullnode)
.usePlaintext(true)
.usePlaintext()
.build();
searchBlockingStubFull = WalletGrpc.newBlockingStub(searchChannelFull);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public void beforeClass() {
PublicMethed.printAddress(account006Key);

channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public void beforeClass() {
logger.info(account007Key);

channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public void beforeClass() {
PublicMethed.printAddress(account009Key);
PublicMethed.printAddress(account009SecondKey);
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,12 @@ public class WalletTestAccount011 {
public void beforeClass() {
PublicMethed.printAddress(account011Key);
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);

channelSolidity = ManagedChannelBuilder.forTarget(soliditynode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubSolidity = WalletSolidityGrpc.newBlockingStub(channelSolidity);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,12 +52,12 @@ public static String loadPubKey() {
public void beforeClass() {

channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);

channelSolidity = ManagedChannelBuilder.forTarget(soliditynode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubSolidity = WalletSolidityGrpc.newBlockingStub(channelSolidity);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public static String loadPubKey() {
@BeforeClass
public void beforeClass() {
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public static String loadPubKey() {
@BeforeClass
public void beforeClass() {
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,12 @@ public class WalletTestBlock006 {
@BeforeClass
public void beforeClass() {
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);

channelSolidity = ManagedChannelBuilder.forTarget(soliditynode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubSolidity = WalletSolidityGrpc.newBlockingStub(channelSolidity);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,12 +70,12 @@ public class WalletTestCommittee001 {
@BeforeClass
public void beforeClass() {
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);

channelSolidity = ManagedChannelBuilder.forTarget(soliditynode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubSolidity = WalletSolidityGrpc.newBlockingStub(channelSolidity);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,12 +66,12 @@ public class WalletTestCommittee002 {
@BeforeClass
public void beforeClass() {
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);

channelSolidity = ManagedChannelBuilder.forTarget(soliditynode)
.usePlaintext(true)
.usePlaintext()
.build();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,12 +69,12 @@ public class WalletTestCommittee003 {
@BeforeClass
public void beforeClass() {
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);

channelSolidity = ManagedChannelBuilder.forTarget(soliditynode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubSolidity = WalletSolidityGrpc.newBlockingStub(channelSolidity);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,12 +73,12 @@ public class WalletTestCommittee004 {
@BeforeClass
public void beforeClass() {
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);

channelSolidity = ManagedChannelBuilder.forTarget(soliditynode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubSolidity = WalletSolidityGrpc.newBlockingStub(channelSolidity);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public class GrpcClient {

// public GrpcClient(String host, int port) {
// channel = ManagedChannelBuilder.forAddress(host, port)
// .usePlaintext(true)
// .usePlaintext()
// .build();
// blockingStub = WalletGrpc.newBlockingStub(channel);
// }
Expand All @@ -58,13 +58,13 @@ public class GrpcClient {
public GrpcClient(String fullnode, String soliditynode) {
if (!(fullnode.isEmpty())) {
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);
}
if (!(soliditynode.isEmpty())) {
channelSolidity = ManagedChannelBuilder.forTarget(soliditynode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubSolidity = WalletSolidityGrpc.newBlockingStub(channelSolidity);
blockingStubExtension = WalletExtensionGrpc.newBlockingStub(channelSolidity);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ public void onFinish(ITestContext testContext) {
*/
public List<Map.Entry<String, Integer>> calculateAfterDailyBuild() {
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);
endBlockNum = blockingStubFull.getNowBlock(GrpcAPI.EmptyMessage.newBuilder().build())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ public class JsonRpcBase {
@BeforeSuite(enabled = true, description = "Deploy json rpc test case resource")
public void deployJsonRpcUseResource() throws Exception {
Wallet.setAddressPreFixByte(CommonConstant.ADD_PRE_FIX_BYTE_MAINNET);
channelFull = ManagedChannelBuilder.forTarget(fullnode).usePlaintext(true).build();
channelFull = ManagedChannelBuilder.forTarget(fullnode).usePlaintext().build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);
Assert.assertTrue(
PublicMethed.sendcoin(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public class ShieldWrapper {
private String fullnode = Configuration.getByPath("testng.conf").getStringList("fullnode.ip.list")
.get(0);
private ManagedChannel channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
private WalletGrpc.WalletBlockingStub blockingStubFull = WalletGrpc.newBlockingStub(channelFull);
private Thread thread;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ public class ZenTrc20Base {
@BeforeSuite(enabled = true, description = "Deploy shield trc20 depend contract")
public void deployShieldTrc20DependContract() {
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,11 +61,11 @@ public void beforeSuite() {
public void beforeClass() {
PublicMethed.printAddress(linkage002Key);
channelFull = ManagedChannelBuilder.forTarget(fullnode)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull = WalletGrpc.newBlockingStub(channelFull);
channelFull1 = ManagedChannelBuilder.forTarget(fullnode1)
.usePlaintext(true)
.usePlaintext()
.build();
blockingStubFull1 = WalletGrpc.newBlockingStub(channelFull1);
}
Expand Down
Loading