Shared maps should syncronize write operations

Because cache are shared across multiple threads.