Uploaded image for project: 'mod-inventory-storage'
  1. mod-inventory-storage
  2. MODINVSTOR-639

Domain events sending in inventory-storage for item

    XMLWordPrintable

Details

    • Falcon Sprint 104
    • 5
    • Falcon

    Description

      Overview:

      Apache Kafka should be used directly in inventory-storage for implementation of domain event pattern, which is needed for both remote-storage integration and new search module. This direct usage of Apache Kafka should be considered as a special case, as it was for data-import. Also it is special case, that storage module use more than one data storage. However, Kafka is used here not for data storage, but for event provision for interaction between modules.
      (see: https://wiki.folio.org/display/DD/Apache+Kafka+usage+in+inventory-storage)

      Requirements/Scope:

      1. On every create message should be sent with id of the created entity as the partition key and body, which contains update action name ("CREATE") in message header and entity in "new"
      2. On every update the similar message should be sent but with action name ("UPDATE") and difference of jsons in "old" and "new" fields (see below)
      3. On every detele the similar message should be sent but with action name ("DELETE") and with json of entity, that was deleted in "old" and empty "new"

      Technical details:
      The Kafka integration should be done according to POC, which is made by Taras_Spashchenko.
      The name of the topic should be inventory.entity_type .

      JSON structure:
      {
      "old" :

      {"title" : "old title" ...}

      ,
      "new" :

      {"title" : "new title" ...}

      "type" : "UPDATE"
      }

      NB: for each item instnace id should be sent, whih is taken from the corresponding holding (retriving of the holding has been already in place)

      TestRail: Results

        Attachments

          Issue Links

            Activity

              People

                bohdan-suprun Bohdan Suprun
                bohdan-suprun Bohdan Suprun
                Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved:

                  TestRail: Runs

                    TestRail: Cases