Uploaded image for project: 'Couchbase Server'
  1. Couchbase Server
  2. MB-27596

eventing audit log should have 1:1 relationship with lifecycle operations

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Unresolved
    • Minor
    • feature-backlog
    • 5.5.0
    • eventing
    • None
    • Enterprise Edition 5.5.0 build 1689

    Description

      Following are the audit messages printed for corresponding lifecycle operations

      Deploy:
      {"timestamp":"2018-01-16T01:33:24.820-08:00","real_userid":

      {"source":"ns_server","user":"Administrator"}

      ,"context":"test_audit2222","id":32768,"name":"Create Function","description":"Eventing function definition was created or updated"}
      {"timestamp":"2018-01-16T01:33:25.923-08:00","real_userid":

      {"source":"ns_server","user":"Administrator"}

      ,"context":"test_audit2222","id":32774,"name":"Save Draft","description":"Save a draft definition to the store"}

      Undeploy:
      {"timestamp":"2018-01-16T01:34:17.794-08:00","real_userid":

      {"source":"ns_server","user":"Administrator"}

      ,"context":"<nil>","id":32771,"name":"List Deployed","description":"Eventing deployed functions list was read"}
      {"timestamp":"2018-01-16T01:34:17.901-08:00","real_userid":

      {"source":"ns_server","user":"Administrator"}

      ,"context":"test_audit2222","id":32779,"name":"Set Settings","description":"Save settings for a given app"}
      {"timestamp":"2018-01-16T01:34:18.397-08:00","real_userid":

      {"source":"ns_server","user":"Administrator"}

      ,"context":"test_audit2222","id":32774,"name":"Save Draft","description":"Save a draft definition to the store"}

      Delete:
      {"timestamp":"2018-01-16T01:34:48.400-08:00","real_userid":

      {"source":"ns_server","user":"Administrator"}

      ,"context":"test_audit2222","id":32773,"name":"Delete Drafts","description":"Eventing function draft definitions were deleted"}
      {"timestamp":"2018-01-16T01:34:48.412-08:00","real_userid":

      {"source":"ns_server","user":"Administrator"}

      ,"context":"test_audit2222","id":32769,"name":"Delete Function","description":"Eventing function definition was deleted"}

      Import:
      {"timestamp":"2018-01-16T01:35:17.543-08:00","real_userid":

      {"source":"ns_server","user":"Administrator"}

      ,"context":"<nil>","id":32772,"name":"Fetch Drafts","description":"Eventing function draft definitions were read"}
      {"timestamp":"2018-01-16T01:35:19.658-08:00","real_userid":

      {"source":"ns_server","user":"Administrator"}

      ,"context":"test_audit","id":32774,"name":"Save Draft","description":"Save a draft definition to the store"}

      Pause:
      {"timestamp":"2018-01-16T01:39:01.259-08:00","real_userid":

      {"source":"ns_server","user":"Administrator"}

      ,"context":"<nil>","id":32771,"name":"List Deployed","description":"Eventing deployed functions list was read"}
      {"timestamp":"2018-01-16T01:39:01.391-08:00","real_userid":

      {"source":"ns_server","user":"Administrator"}

      ,"context":"test_audit","id":32779,"name":"Set Settings","description":"Save settings for a given app"}
      {"timestamp":"2018-01-16T01:39:01.586-08:00","real_userid":

      {"source":"ns_server","user":"Administrator"}

      ,"context":"test_audit","id":32774,"name":"Save Draft","description":"Save a draft definition to the store"}

      Resume:
      {"timestamp":"2018-01-16T01:38:39.639-08:00","real_userid":

      {"source":"ns_server","user":"Administrator"}

      ,"context":"<nil>","id":32771,"name":"List Deployed","description":"Eventing deployed functions list was read"}
      {"timestamp":"2018-01-16T01:38:39.661-08:00","real_userid":

      {"source":"ns_server","user":"Administrator"}

      ,"context":"test_audit","id":32779,"name":"Set Settings","description":"Save settings for a given app"}
      {"timestamp":"2018-01-16T01:38:39.713-08:00","real_userid":

      {"source":"ns_server","user":"Administrator"}

      ,"context":"test_audit","id":32774,"name":"Save Draft","description":"Save a draft definition to the store"}

      Audit messages don't have 1:1 relationship with the lifecycle operations, they do with API's. It works for some operations like delete. However here are the problems I see
      1) There is no discernible way to distinguish between a Undeploy or Pause or Resume.
      2) Since more than 1 API is called for particular lifecycle operation it is very easy to get confused as to which audit message stands for what operation. For eg Deploy/Delete/Import has 2 messages and Undeploy/Pause/Resume has 3 messages etc.

      Logs attached.

      Attachments

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

        Activity

          People

            srinivasan.raman Srinivasan Raman
            Balakumaran.Gopal Balakumaran Gopal
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty