Uploaded image for project: 'Couchbase .NET client library'
  1. Couchbase .NET client library
  2. NCBC-3504

CLONE - Transactions possibly not performing MAV reads correctly

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • Major
    • None
    • None
    • None
    • None
    • 3
    • SDK34, SDK36

    Description

      Multiple test failures (48+) are because of "ActiveTransactionRecordEntryNotFound" exception. And same are passing for Java SDK.

      Jenkins failures:
      https://sdk.jenkins.couchbase.com/job/dotnet/job/sdk/job/TransactionsFITPerformer_SinglePerformer/1313/testReport/junit/com.couchbase.transactions/ForwardCompatibilityTest/replacesNotBlockedIfCompatible/

      https://sdk.jenkins.couchbase.com/job/dotnet/job/sdk/job/TransactionsFITPerformer_SinglePerformer/1312/testReport/junit/com.couchbase.transactions/ForwardCompatibilityTest/Setup_test_Infra_and_Execute_Tests___7_0_release_Vs_DOTNET_MASTER___replacesNotBlockedIfCompatible_2/

      https://sdk.jenkins.couchbase.com/job/dotnet/job/sdk/job/TransactionsFITPerformer_SinglePerformer/1312/testReport/junit/com.couchbase.transactions/ForwardCompatibilityTest/Setup_test_Infra_and_Execute_Tests___7_1_stable_Vs_DOTNET_MASTER___replacesNotBlockedIfCompatible_2/

      https://sdk.jenkins.couchbase.com/job/dotnet/job/sdk/job/TransactionsFITPerformer_SinglePerformer/1313/testReport/junit/com.couchbase.transactions/ForwardCompatibilityTest/removesNotBlockedIfCompatible/

      https://sdk.jenkins.couchbase.com/job/dotnet/job/sdk/job/TransactionsFITPerformer_SinglePerformer/1312/testReport/junit/com.couchbase.transactions/ForwardCompatibilityTest/Setup_test_Infra_and_Execute_Tests___6_6_release_Vs_DOTNET_MASTER___removesNotBlockedIfCompatible_2/

      https://sdk.jenkins.couchbase.com/job/dotnet/job/sdk/job/TransactionsFITPerformer_SinglePerformer/1312/testReport/junit/com.couchbase.transactions/ForwardCompatibilityTest/Setup_test_Infra_and_Execute_Tests___7_0_release_Vs_DOTNET_MASTER___removesNotBlockedIfCompatible_3/

      https://sdk.jenkins.couchbase.com/job/dotnet/job/sdk/job/TransactionsFITPerformer_SinglePerformer/1312/testReport/junit/com.couchbase.transactions/ForwardCompatibilityTest/Setup_test_Infra_and_Execute_Tests___7_1_stable_Vs_DOTNET_MASTER___removesNotBlockedIfCompatible_4/

       

      Below is the error message:

      ABORTED:  Operation failed unexpectedly, was expecting  one of
      [ { "success": true } ]
      but got
      { "autoRollbackAttempt": true, "toRaise": "EXCEPTION_FAILED", "cause": { "exception": "ActiveTransactionRecordEntryNotFound" } }: Exception of type 'Couchbase.Transactions.Error.External.TransactionOperationFailedException' was thrown. 

      Below are the 2 example tests that are failing:

      @IgnoreWhen(firstPerformerIsBelow = {"java-1.1.4"}) // needs log redaction fix TXNJ-337
      @TestFactory
      Stream<DynamicTest> replacesNotBlockedIfCompatible() {
          return Stream.of(true, false)
                  .flatMap(fastFail ->
                          Stream.of(true, false).flatMap(protocolFail ->
                                  retryAfter().map(retryAfter ->
                                          DynamicTest.dynamicTest(testName(fastFail, protocolFail, retryAfter), () -> {
                                              if (fastFail && retryAfter.isPresent()) {
                                                  return;   // retryAfter only used in retry mode
                                              }
       
                                              String docId = TestUtils.docId();
                                              createStagedReplaceOnPendingTransaction(docId, true);
       
                                              if (protocolFail) {
                                                  TestUtils.forceDocToRequireProtocol(collection, docId, ForwardCompatibilityStages.WRITE_WRITE_CONFLICT_REPLACING, PROTOCOL_VERSION_COMPATIBLE, fastFail, retryAfter);
                                              } else {
                                                  TestUtils.forceDocToRequireExtension(collection, docId, ForwardCompatibilityStages.WRITE_WRITE_CONFLICT_REPLACING, EXTENSION_COMPATIBLE, fastFail, retryAfter);
                                              }
       
                                              TransactionResult result = TransactionBuilder.create(shared)
                                                      .replace(docId, updated)
                                                      .sendToPerformer();
                                              ResultValidator.assertCompletedInSingleAttempt(shared, collection, result);
                                              DocValidator.assertDocExistsAndNotInTransactionAndContentEquals(collection, docId, updated);
                                          })
                                  )));
      }
       
      @IgnoreWhen(firstPerformerIsBelow = {"java-1.1.4"}) // needs log redaction fix
      @TestFactory
      Stream<DynamicTest> removesNotBlockedIfCompatible() {
          return Stream.of(true, false)
                  .flatMap(fastFail ->
                          Stream.of(true, false).flatMap(protocolFail ->
                                  retryAfter().map(retryAfter ->
                                          DynamicTest.dynamicTest(testName(fastFail, protocolFail, retryAfter), () -> {
                                              if (fastFail && retryAfter.isPresent()) {
                                                  return;   // retryAfter only used in retry mode
                                              }
       
                                              String docId = TestUtils.docId();
                                              createStagedReplaceOnPendingTransaction(docId, true);
       
                                              if (protocolFail) {
                                                  TestUtils.forceDocToRequireProtocol(collection, docId, ForwardCompatibilityStages.WRITE_WRITE_CONFLICT_REMOVING, PROTOCOL_VERSION_COMPATIBLE, fastFail, retryAfter);
                                              } else {
                                                  TestUtils.forceDocToRequireExtension(collection, docId, ForwardCompatibilityStages.WRITE_WRITE_CONFLICT_REMOVING, EXTENSION_COMPATIBLE, fastFail, retryAfter);
                                              }
       
                                              TransactionResult result = TransactionBuilder.create(shared)
                                                      .remove(docId)
                                                      .sendToPerformer();
                                              ResultValidator.assertCompletedInSingleAttempt(shared, collection, result);
                                              DocValidator.assertDocIsTombstoneAndHasNoTransactionMetadata(collection, docId);
                                          })
                                  )));
      }
      

       

      Attaching driver log of one failure of `replacesNotBlockedIfCompatible` and FIT Performer log of all failures of `replacesNotBlockedIfCompatible` for your reference. Please feel free to reach out for any further assistance.

      Thanks!

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              richard.ponton Richard Ponton
              aaliya.haque Aaliya Haque
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:

                Gerrit Reviews

                  There are no open Gerrit changes

                  PagerDuty