added code so I could compare against java lock / condition just to make sure it worked as expected