Uploaded image for project: 'WildFly'
  1. WildFly
  2. WFLY-9021

Unhelpful failure message if transaction subsystem 'delete' op is run against a non-existent resource on a domain mode server

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Minor
    • 11.0.0.Beta1
    • None
    • Transactions
    • None

    Description

      In a domain if you run the 'delete' op against an invalid transaction resource you get an invalid failure message about trying to directly call a write op on a server:

      [domain@localhost:9990 /] /host=master/server=server-one/subsystem=transactions/log-store=log-store/transactions=0\:ffff0afc4420\:3b2568af\:594b9528\::delete()
      {
          "outcome" => "failed",
          "result" => undefined,
          "failure-description" => "WFLYCTL0249: Operation 'delete' targeted at resource '[
          (\"subsystem\" => \"transactions\"),
          (\"log-store\" => \"log-store\"),
          (\"transactions\" => \"0:ffff0afc4420:3b2568af:594b9528:\")
      ]' was directly invoked by a user. User operations are not permitted to directly update the persistent configuration of a server in a managed domain.",
          "rolled-back" => true
      }
      

      This is because if the resource doesn't exist, the check for mods to non-runtime-only resources is checking the MRR to see if it's runtime only. But this MRR doesn't declare it is so the kernel thinks a direct write to the model is happening and rejects that.

      A fix results in the appropriate failure for invoking against a non-existent resource:

      [domain@localhost:9990 /] /host=master/server=server-one/subsystem=transactions/log-store=log-store/transactions=0\:ffff0afc4420\:3b2568af\:594b9528\::delete()
      {
          "outcome" => "failed",
          "result" => undefined,
          "failure-description" => "WFLYCTL0216: Management resource '[
          (\"subsystem\" => \"transactions\"),
          (\"log-store\" => \"log-store\"),
          (\"transactions\" => \"0:ffff0afc4420:3b2568af:594b9528:\")
      ]' not found",
          "rolled-back" => true
      }
      

      Attachments

        Issue Links

          Activity

            People

              bstansbe@redhat.com Brian Stansberry
              bstansbe@redhat.com Brian Stansberry
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: