Service - Monitor Manager

From Izara Wiki
Jump to navigation Jump to search

Overview

Each monitor is handled by a Service - Monitor (handlers) service.

The Monitor Manager service handles shared orchestration of the Monitor Handler services and the base monitor objectType.

Repository

https://bitbucket.org/izara-supply-supply-locations/izara-supply-monitoring-monitor-manager

DynamoDB tables

MonitorRecord

Records which Handler manages each Monitor

{
	monitorId
	monitorHandlerServiceNameTag
}
  • partition key: monitorId
  • sort key: (none)

objectSchemas

{
	objectType: "monitor",
	storageResources:{
		"xxx":{
			storageType: "graph",
			graphServerTag: "xx",
		}
	},
	fieldNames: {
		monitorId: {
			type: "string",
            randomOnCreate: true
		},
	},
	identifiers: [
		{
			fieldName: "monitorId"
		},
	]
},
{
	objectType: "monitorMarker",
    belongTo: { // maybe in future when add RBAC to eg stages
		serviceTag: "iii",
		objectType: "jjj"
	},
	storageResources:{
		"xxx":{
			storageType: "graph",
			graphServerTag: "xx",
		}
	},
	fieldNames: {
		monitorMarkerId: {
			type: "string",
            randomOnCreate: true
		},
		monitorMarker: { // string sent to monitor project during the period of the stage
			type: "string",
		},
	},
	identifiers: [
		{
			fieldName: "monitorMarkerId"
		},
	]
},
  • Is a marker that can be connected to any object, eg appliedStages
  • Is sent to the monitor project to offer more granular monitoring

relationshipSchemas

[
  {
    "markerForMonitor": {
      storageResources:{
		"xxx":{
			storageType: "graph",
			graphServerTag: "xx",
		}
      },
      links: [
        {
          storageResourceTags: ["xxx"],
          from: {
            objType: {
              serviceTag: "monitorManager",
              objectType: "monitorMarker"
            },
            linkType: "one",
          },
          to: {
            objType: {
              serviceTag: "monitorManager",
              objectType: "monitor"
            },
            linkType: "many",
          }
        }
      ]
    }
  }
]

Working documents

Monitor Manager