private void ExecuteBatch(Action<StorageActionsAccessor> action)
{
if (current.Value != null)
{
action(current.Value);
return;
}
try
{
using (var storageActionsAccessor = new StorageActionsAccessor(tableColumnsCache, instance, database))
{
current.Value = storageActionsAccessor;
action(storageActionsAccessor);
storageActionsAccessor.Commit();
}
}
finally
{
current.Value = null;
}
}
}