changes to get Java examples working again