Java gateway configuration