recalculation.parked
The attendance engine parked something it could not work out, saying why (reason): it is not tried again by the clock, only when something it is worked out from changes, or when a worker of another build takes it. unsettled: the records of one worker read each other’s time (ctx:other_records), and their policies kept changing each other: a change of one works the others out again, which changed it again, until a pass left a record’s time as it was after an earlier pass of the chain (relayed passes before it); a change of the person’s time is passed on to the worker’s other records no further, until something is recorded for one of them. Each record is kept as it was last worked out. failed: a person’s ledgers could not be worked out (a policy step that fails, data the policy cannot take, a step that ran out of work or memory); they stay as they were, with the error kept in their pending work (GET …/pending), until anything is recorded for them or their policy changes, or a worker of another build takes them; told once for the mark that failed. When what fails is common to a whole batch of the tenant’s people (a package that does not load), the tenant is told once, with persons, for as long as its batches keep failing, not each person. Kept in Time and Attendance’s own event log (apart from Connect’s) and delivered to its sinks: the tenant’s (/api/attendance/tenants/{tenant}/sinks) and the install’s (/api/attendance/sinks). The envelope’s endpoint is “attendance”, its package “houradvantage-attend”, and its device the person’s id.
Schema id: urn:houradvantage:events:3:recalculation.parked
Fields
| Field | Type | Required | Description |
|---|---|---|---|
tenant | string | yes | The tenant it is about. |
reason | "unsettled" \ | "failed" | yes |
person | string | unsettled: the record whose change is passed on no further; failed: the person whose ledgers could not be worked out (absent when a whole batch failed). | |
persons | integer | failed, for a whole batch: how many of the tenant’s people it was. at least 1 | |
worker | string | unsettled: the worker whose records they are. | |
records | array of string | unsettled: the worker’s other records, which the change is not passed on to. | |
relayed | integer | unsettled: how many times in a row a change had been passed on between the records before a pass came back to a state of the person’s time it had been through. at least 0 | |
why | string | yes | Why, in words. |
Examples
{ "tenant": "acme", "reason": "unsettled", "person": "104552", "worker": "w-17", "records": [ "us-4471" ], "relayed": 8, "why": "104552's time and that of the other records of worker w-17 (us-4471) kept changing each other: passed on 8 times in a row, a change is passed on no further until something is recorded for them"}{ "tenant": "acme", "reason": "failed", "person": "104552", "why": "step rate (mine/rate): runtime error: no rate for this"}{ "tenant": "acme", "reason": "failed", "persons": 256, "why": "package broken: syntax error near <eof>"}JSON Schema
recalculation.parked.json
{ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "urn:houradvantage:events:3:recalculation.parked", "title": "recalculation.parked: data", "description": "The attendance engine parked something it could not work out, saying why (reason): it is not tried again by the clock, only when something it is worked out from changes, or when a worker of another build takes it. unsettled: the records of one worker read each other's time (ctx:other_records), and their policies kept changing each other: a change of one works the others out again, which changed it again, until a pass left a record's time as it was after an earlier pass of the chain (relayed passes before it); a change of the person's time is passed on to the worker's other records no further, until something is recorded for one of them. Each record is kept as it was last worked out. failed: a person's ledgers could not be worked out (a policy step that fails, data the policy cannot take, a step that ran out of work or memory); they stay as they were, with the error kept in their pending work (GET .../pending), until anything is recorded for them or their policy changes, or a worker of another build takes them; told once for the mark that failed. When what fails is common to a whole batch of the tenant's people (a package that does not load), the tenant is told once, with persons, for as long as its batches keep failing, not each person. Kept in Time and Attendance's own event log (apart from Connect's) and delivered to its sinks: the tenant's (/api/attendance/tenants/{tenant}/sinks) and the install's (/api/attendance/sinks). The envelope's endpoint is \"attendance\", its package \"houradvantage-attend\", and its device the person's id.", "type": "object", "properties": { "tenant": { "type": "string", "description": "The tenant it is about." }, "reason": { "type": "string", "enum": [ "unsettled", "failed" ], "description": "Why: a worker's records kept changing each other, or a person's ledgers could not be worked out." }, "person": { "type": "string", "description": "unsettled: the record whose change is passed on no further; failed: the person whose ledgers could not be worked out (absent when a whole batch failed)." }, "persons": { "type": "integer", "minimum": 1, "description": "failed, for a whole batch: how many of the tenant's people it was." }, "worker": { "type": "string", "description": "unsettled: the worker whose records they are." }, "records": { "type": "array", "items": { "type": "string" }, "description": "unsettled: the worker's other records, which the change is not passed on to." }, "relayed": { "type": "integer", "minimum": 0, "description": "unsettled: how many times in a row a change had been passed on between the records before a pass came back to a state of the person's time it had been through." }, "why": { "type": "string", "description": "Why, in words." } }, "required": [ "tenant", "reason", "why" ], "examples": [ { "tenant": "acme", "reason": "unsettled", "person": "104552", "worker": "w-17", "records": [ "us-4471" ], "relayed": 8, "why": "104552's time and that of the other records of worker w-17 (us-4471) kept changing each other: passed on 8 times in a row, a change is passed on no further until something is recorded for them" }, { "tenant": "acme", "reason": "failed", "person": "104552", "why": "step rate (mine/rate): runtime error: no rate for this" }, { "tenant": "acme", "reason": "failed", "persons": 256, "why": "package broken: syntax error near <eof>" } ]}