moved sync counter internals to LocalSyncLayer