Technical onboarding

Existing Reference Architecture

Repos

WorkLoadManagementService:

https://dev.azure.com/transport-canada/MAACE-Solution%20and%20Data%20Architecture%20Services/_git/WorkLoadManagementService

WLMDemoPortal:

https://dev.azure.com/transport-canada/MAACE-Solution%20and%20Data%20Architecture%20Services/_git/WLMDemoPortal

MTOA API SERVICE(Wrapper around MTOA, SIAPI, SPAPI AND TMAPI):

https://dev.azure.com/transport-canada/MAACE-Solution%20and%20Data%20Architecture%20Services/_git/MtoaApiService

TimeTrackingService:

https://dev.azure.com/transport-canada/MAACE-Solution and Data Architecture Services/_git/TimeTrackingService

Accessing SCED enviornment:

We have been move our DEV enviornment from NON-SCED to SCED in Azure and the following URL’s have been used to access the application services under SCED.

WLMDemoPortal:

https://ncdworkloadmanagementdemoportalapp01.azurewebsites.net/

MTOAApiService:

https://ncdmtoaapiserviceapp01.azurewebsites.net/swagger/index.html

WorkLoadManagementService:

https://ncdworkloadmanagementapp01.azurewebsites.net/swagger/index.html

TimeTrackingService:

https://ncdtimetrackingserviceapp01.azurewebsites.net/swagger/index.html

Creating new request flow in WLM

The following diagrams show the data flow between, the WLMWorkloadManagementService , MTOA API and MT API for new request:

 

 

diag1.png

 

 

Topics

workload-servicerequest-topic: The WorkloadManagmentService will push new work item request to this topic:

Payload structure:

public class WorkItemCreatedEvent : EventModel

    {

        public int UserId { get; set; }
        public string RequestTypeId { get; set; }
        public int? OrganizationId { get; set; }
        public string RequestStatus { get; set; }
        public string EnglishDisplayName { get; set; }
        public string FrenchDisplayName { get; set; }
        public int? MetadataStructureId { get; set; }
        public List<KeyValuePair<string, string>> Metadata { get; set; }

    }

workload-serviceresponse-topic: this topic would be used to send service order creation response back to WorkloadManagement Service.

Below is the payload:

public class MtoaServiceRequestResponse

    {

        public int ServiceRequestId { get; set; }
        public string WorkLoadItemId { get; set; }

    }

Subscribers

workload-servicerequest-sub:  subscribes workload-servicerequest-topic. Listener is setup in MTOAAPIService.api.

workload-serviceresponse-sub: Subscribes in WorkloadManagement to update the external reference number in Database.

Observations:

  1. Few values are hardcoded while service request is created in MTOAApiService.api. below is the screenshot (considering these values to be received from CRSM Test Service)

Updating service request flow

Current Status Mapping:

WLM Status ID

WLM Status name

MTOA Status ID

MTOA Status name

001

 

2

Submitted

002

 

1

In Progress

003

 

6

Information Required

004

 

22

Document Issued

005

 

12

Rejected

006

 

9

Cancelled

007

 

10

Initiated

011

 

20

On Hold

 

 

4

Completed

The following diagram shows the data flow between, the WLM Demo Portal, WLMWorkloadManagementService and MTOA when the status is changed in WLM Demo Portal:

Topic

workload-servicestatus-topic: WLMPortal pushes the payload to this topic whenever status of work item is changed by used. Below is the payload.

public class WorkItemStatusChangedEvent : EventModel

    {

        public int WorkItemId { get; set; }
        public string ExternalServiceRequestId { get; set; }
        public string PreviousWorkItemStatusCode { get; set; }
        public string CurrentWorkItemStatusCode { get; set; }

    }

Subscribers

workload-servicestatus-sub: Subscribed by MTOAPIService and updates the status to MTOAOn- PremService.