Implements thread safe APIs