Skip to content

Releases: hyperledger-web3j/web3j

v2.0.1

21 Feb 08:29
Compare
Choose a tag to compare

This is a minor release addressing #58 where the generated code for event functions wrappers was always using a lowercase function name.

This release only affects the smart contract wrapper generator, so will only require an upgrade to the web3j command line tools for most users.

Transaction managers and event wrappers (v2.0.0-android)

11 Feb 03:23
Compare
Choose a tag to compare

Transaction managers and event wrappers (v2.0.0)

10 Feb 06:54
Compare
Choose a tag to compare

This milestone release incorporates a number of key features:

Transaction managers

Transaction managers allow you to choose how you transact with Ethereum clients via web3j's smart contract wrappers. For instance, you can now choose if you wish to have web3j sign your transactions, or the Ethereum client that you submit the transaction to the network via. You can also specify the chain id as per EIP-155 to prevent replay of transactions.

This also simplifies working with other Ethereum platforms such Quorum via web3j-quorum, which works natively with web3j 2.0+ generated smart contract wrappers, with full transaction privacy support.

A fast transaction manager has also been created to facilitate sending multiple raw transactions per block.

Thanks to ferOnti for all of his input on working with higher throughput transactions.

Reactive, typed events

Events in generated smart contracts wrappers are now fully typed. E.g. in the ERC20 smart contract wrappers, you have the following event definition:

event Transfer(address indexed _from, address indexed _to, uint256 _value);

You now have the following event object type in the corresponding smart contract wrapper Java code:

public static class TransferEventResponse {
        public Address _from;

        public Address _to;

        public Uint256 _value;
    }

You can then get details of those events via the transaction receipt:

public List<TransferEventResponse> getTransferEvents(TransactionReceipt transactionReceipt)

Or get an Observable that creates a filter providing events as they happen on the blockchain:

public Observable<TransferEventResponse> transferEventObservable()

See HumanStandardToken for further details.

Thanks to @tramonex-nate for this great enhancement.

Default values

Default values are now available on all Solidity types. E.g. if you wish to provide an empty value to a smart contract wrapper, use <Type>.DEFAULT.

Thanks to @thedoctor who provided this change.

Versioning

web3j jars now contain details of the build version. You can query this from your code via the Version class.

The version is now provided with the web3j command line tools, which incidentally are now available on Homebrew.

$ brew tap web3j/web3j
$ brew install web3j
$ web3j version

              _      _____ _     _        
             | |    |____ (_)   (_)       
__      _____| |__      / /_     _   ___  
\ \ /\ / / _ \ '_ \     \ \ |   | | / _ \ 
 \ V  V /  __/ |_) |.___/ / | _ | || (_) |
  \_/\_/ \___|_.__/ \____/| |(_)|_| \___/ 
                         _/ |             
                        |__/              

Version: 2.0.0
Build timestamp: 2017-02-10 06:45:22.537 UTC

Light wallet generation

For working with resource constrained devices such as smartphones, web3j now provides two types of wallet file generation, full and light. Previously only the full generation was available. Running a simple benchmark locally, full wallet files can be generated in ~700 msecs, versus ~50 msecs for light.

See the WalletUtils class for more information.

Breaking changes

The Contract class has been migrated to the tx package along with the TransactionManager components.
Block and Transaction responses from Ethereum clients are no longer contained within an optional. This is to reduce the number of Optional.get() calls that were required when working with the Future and Observable APIs.

Bug fixes

  • #43 RLP zero prefixed string
  • #46 Replace Java internal API and make file seprator OS-specific
  • #53 Compiling contract inside Java code

v1.1.2 The IPC Release

16 Jan 12:23
Compare
Choose a tag to compare

Provides IpcService for connecting to Ethereum clients over IPC for *nix based OS's.

Contains a number of bug fixes & pull requests submitted by the community.

Update web3j command line tools are now available via Homebrew of OS X users:

brew tap web3j/web3j
brew install web3j

v1.1.1

03 Jan 09:31
Compare
Choose a tag to compare

This release contains a fix for the following issue:

Additionally web3j-tests.jar artifacts are now being published to Maven/JFrog.

web3j goes reactive (v1.1.0-android)

20 Dec 10:25
Compare
Choose a tag to compare

web3j goes reactive (v1.1.0)

20 Dec 10:25
Compare
Choose a tag to compare

This milestone release provides a couple of significant new features to web3j.

Firstly the JSON-RPC client API has been enhanced to integrate with RxJava's Observables. In addition to web3j.< methodName >.[ send() | sendAsync ], you also have observable() which will wrap the request in an observable, allowing straight forwards composition of JSON-RPC calls.

Secondly is the addition of web3j's filter API. web3j provides a fully asynchronous API for working with Ethereum client filters, so you no longer need to poll the client for filter updates. For instance, receiving a callback with all new blocks or transactions being created in Ethereum is very trivial. For more details refer to the new Filters and Events section in the documentation.

v1.0.9-android

01 Dec 00:53
Compare
Choose a tag to compare

This release addresses issues with the Apache HttpClient on Android.
See here for details of core web3j changes.

v1.0.9

01 Dec 00:45
Compare
Choose a tag to compare

Workaround for differences in the Transaction objects returned by Geth and Parity. See this issue for details.

v1.0.8-android

29 Nov 06:58
Compare
Choose a tag to compare

See v1.0.8 for release notes.