Esempio n. 1
0
        public IList <Table.TableResult> ExecuteBatch(Table.TableBatchOperation batch, Table.TableRequestOptions requestOptions = null, OperationContext operationContext = null)
        {
            try
            {
                return(table.ExecuteBatch(batch, requestOptions, operationContext));
            }
            catch (StorageException e)
            {
                // find the error index
                // WARNING: this is not very reliable
                // c.f. http://stackoverflow.com/questions/14282385/azure-cloudtable-executebatchtablebatchoperation-throws-a-storageexception-ho/14290910#14290910
                var msg        = e.RequestInformation.ExtendedErrorInformation.ErrorMessage;
                var parts      = msg.Split(':');
                var errorIndex = int.Parse(parts[0]);

                throw new ChainTableInterface.ChainTableBatchException(errorIndex, e);
            }
        }
Esempio n. 2
0
 public Task <Table.TableResult> ExecuteAsync(Table.TableOperation operation, Table.TableRequestOptions requestOptions = null, OperationContext operationContext = null)
 {
     return(table.ExecuteAsync(operation, requestOptions, operationContext));
 }
Esempio n. 3
0
        public Table.TableResult Execute(Table.TableOperation operation, Table.TableRequestOptions requestOptions = null, OperationContext operationContext = null)
        {
            var res = table.Execute(operation, requestOptions, operationContext);

            return(res);
        }