internal CommitTransactionPreRequest(List<object> events,
			string journalName, TransactionUID transactionUID)
        {
            this.Events = events;
            this.JournalName = journalName;
            this.TransactionUID = transactionUID;
        }
        internal static DataStoreRequest Create(string journalName, 
			TransactionUID transactionUID, RequestUID requestUID, WorkerUID workerUID)
        {
            var request = new RollbackTransactionRequest(journalName, transactionUID);
            var header = new Header(RequestType.ROLLBACK_TRANSACTION, request.SizeOf, requestUID, HeaderProperties.None,
                workerUID);

            return new DataStoreRequest(header, request);
        }
        internal static DataStoreRequest Create(List<object> events, string journalName, 
			TransactionUID transactionUID, RequestUID requestUID, WorkerUID workerUID)
        {
            var request = new CommitTransactionPreRequest(events, journalName, transactionUID);
            var header = new Header(RequestType.COMMIT_TRANSACTION, 0, requestUID, HeaderProperties.None,
                workerUID);

            return new DataStoreRequest(header, request);
        }
 internal RollbackTransactionRequest(string journalName, TransactionUID transactionUID)
 {
     this.JournalName = journalName;
     this.TransactionUID = transactionUID;
 }
 public NewTransactionResponseState(Offset journalSize, TransactionUID transactionUID)
 {
     Response = new Some<IMessageResponse>(new NewTransactionResponse(journalSize, transactionUID));
 }
 public IResponseState Parse(Header header, IEndianAwareReader reader)
 {
     var journalSize = new Offset(reader.ReadInt32());
     var transactionUID = new TransactionUID(reader.ReadInt32());
     return new NewTransactionResponseState(journalSize, transactionUID);
 }
 public NewTransactionResponse(Offset journalSize, TransactionUID transactionUID)
 {
     this.JournalSize = journalSize;
     this.TransactionUID = transactionUID;
 }