concurrency: add java & javascript sample