reverted back to old code because of too much contention