Updating for new java driver api