chat creation using java language