carDispatched | passengerPickedUp | passengerDroppedOff | |
---|---|---|---|
Description | event reporting that a limousine has been dispatched for a trip | event reporting passenger pickup | event reporting trip completion (arrival at destination) |
Event part name and identifier | content | Content | content |
Event part type | lmo:dispatchLimousine | lmo:pickUpPassenger | lmo:dropOffPassenger |
Event part path | cbe:CommonBaseEvent/lmo:dispatchLimousine | cbe:CommonBaseEvent/lmo:pickUpPassenger | cbe:CommonBaseEvent/lmo:dropOffPassenger |
Filter conditions | fn:exists( carDispatched/content/lmo:limousineId ) | fn:exists( passengerPickedUp/content/lmo:limousineId ) | fn:exists( dropOffPassenger/content/lmo:limousineId ) |
Correlation expression | carDispatched/content/lmo:tripID=tripKey | passengerPickedUp/content/lmo:limousineId=limousine and tripStatus='picking up passenger' | passengerDroppedOff/content/lmo:limousineId=limousine and tripStatus='passenger on board' |
No instances found | Create new instance | Treat as error | Treat as error |
One instance found | Treat as error | Deliver to the instance | Deliver to the instance |
Multiple instances found | Treat as error | Treat as error | Treat as error |
Name | Description | Type | Default value | Other |
---|---|---|---|---|
tripKey | unique identifier for this trip | xs:string | MC key; length <= 64 | |
dropOffActualTime | the actual passenger drop-off time | xs:dateTime | ||
dropOffScheduledTime | the scheduled passenger drop-off time | xs:dateTime | ||
dropOffAddress | the trip destination address | xs:string | length <= 256 | |
driver | the name of the driver | xs:string | length <= 64 | |
limousine | the limousine number dispatched for this trip | xs:integer | ||
passenger | the name of the passenger | xs:string | length <=64 | |
pickUpAddress | the passenger pick-up address | xs:string | length <= 256 | |
pickUpActualTime | the actual passenger pick-up time | xs:dateTime | ||
pickUpScheduledTime | the scheduled passenger pick-up time | xs:dateTime | ||
pickUpWasLate | indicator that passenger pickup was more than 10 minutes late | xs:boolean | fn:false() | |
timeDispatched | time at which car was dispatched for this trip | xs:dateTime | ||
tripDuration | the duration of the trip | xs:duration | ||
tripStatus | 'picking up passenger'/'passenger on board'/'completed on time'/'completed not on time'/'unknown' | xs:string | 'unknown' | length <= 24 |
Metric | Map |
---|---|
tripKey | carDispatched/content/lmo:tripId |
dropOffActualTime | passengerDroppedOff/content/lmo:timestamp |
dropOffScheduledTime | carDispatched/content/lmo:dropOffTime |
dropOffAddress | fn:concat(carDispatched/content/lmo:dropOffAddress/lmo:street, ', ', carDispatched/content/lmo:dropOffAddress/lmo:city) |
driver | carDispatched/content/lmo:driver |
limousine | carDispatched/content/lmo:limousineId |
passenger | carDispatched/content/lmo:passenger |
pickUpAddress | fn:concat(carDispatched/content/lmo:pickUpAddress/lmo:street, ', ', carDispatched/content/lmo:pickUpAddress/lmo:city) |
pickUpActualTime | passengerPickedUp/content/lmo:timestamp |
pickUpScheduledTime | carDispatched/content/lmo:pickUpTime |
pickUpWasLate | if ( fn:exists( pickUpActualTime ) ) then pickUpActualTime > pickUpScheduledTime+ xs:dayTimeDuration('PT10M') else pickUpWasLate |
timeDispatched | carDispatched/content/lmo:timestamp |
tripDuration | if (fn:exists(dropOffActualTime) and fn:exists(timeDispatched)) then dropOffActualTimel - timeDispatched else tripDuration |
tripStatus | if ( fn:exists( dropOffActualTime ) ) then ( if ( dropOffActualTime <= dropOffScheduledTime ) then 'completed on time' else 'completed not on time' ) else if ( fn:exists( pickUpActualTime ) ) then 'passenger on board' else if ( fn:exists( timeDispatched ) ) then 'picking up passenger' else 'unknown' |
Now you are ready to deploy your monitor model. Lesson 1.4: Deploying the monitor model.