I'm trying to deploy a smart contract (7 nodes sample from Quorum) using web3j. It fails at get() to get the contract wrapper object. If I check the logs, a new transaction will show up, but if I call any contract function, it will give me a null pointer exception. My code looks like this:
String deployeraccount = "0xed9d02e382b34818e88b88a309c7fe71e65f419d";
String privfor = "QfeDAys9MPDs2XHExtc84jKGHxZg/aj52DTh0vtA3Xc=";
try {
Quorum quorum = Quorum.build(new HttpService("http://localhost:22000"));
ClientTransactionManager transactionManager = new ClientTransactionManager(
quorum, deployeraccount, Arrays.asList(privfor));
BigInteger gasPrice = BigInteger.valueOf(30000);
BigInteger gasLimit = BigInteger.valueOf(100000);
BigInteger initialWeiValue = BigInteger.valueOf(0);
Uint256 initVal = new Uint256(BigInteger.valueOf(0));
System.out.println(">> Before deploy");
Future<Simplestorage> ft = Simplestorage.deploy( quorum,
transactionManager,
gasPrice,
gasLimit,
initialWeiValue,
initVal );
System.out.println(">> deploy");
while (!ft.isDone()) {
Thread.sleep(500);
}
System.out.println(">> after wait");
Simplestorage ss = ft.get();
I already tried changing the gas value, but still got the same issue. Thanks.