generated from ministryofjustice/template-repository
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Co-authored-by: Anthony Britton <[email protected]>
- Loading branch information
1 parent
ff290e2
commit 75a494e
Showing
3 changed files
with
48 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,17 @@ | ||
# manage-offences-and-delius | ||
# Manage Offences and Delius | ||
|
||
// TODO Describe the service | ||
## Business Need | ||
|
||
Inbound service that responds to events raised by the HMPPS Manage Offences service when there are changes to the set of [CJS Offence Codes](https://www.criminaljusticehub.org.uk/jargon-buster/cjs-offence-code/) managed by that service. Any changes to the set of offence codes is reflected in the Delius database. This ensures that Delius is up-to-date with the common set of offence codes used across HMPPS Digital services. | ||
|
||
## Interfaces | ||
|
||
### Message Formats | ||
|
||
The service responds to an HMPPS Domain Event message via an | ||
[SQS Queue](https://github.com/ministryofjustice/cloud-platform-environments/blob/main/namespaces/live.cloud-platform.service.justice.gov.uk/hmpps-probation-integration-services-prod/resources/manage-offences-and-delius-queue.tf). | ||
The events are raised by the [Manage Offences API](https://github.com/ministryofjustice/hmpps-manage-offences-api) when a CJS offence code is either created or updated. | ||
|
||
| Business Event | Message Class | Message Event Type / Filter | | ||
|----------------------------|--------------------|---------------------------------| | ||
| Change to CJS offence code | HMPPS Domain Event | manage-offences.offence.changed | |
9 changes: 9 additions & 0 deletions
9
projects/manage-offences-and-delius/tech-docs/source/async-api-reference.html.md.erb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
--- | ||
title: AsyncAPI Reference | ||
source_url: 'https://github.com/ministryofjustice/hmpps-probation-integration-services/blob/main/projects/manage-offences-and-delius/tech-docs/source/async-api-reference.html.md.erb' | ||
weight: 30 | ||
--- | ||
|
||
# ASyncAPI Reference | ||
|
||
* [ASyncAPI Spec](https://studio.asyncapi.com/?url=https://raw.githubusercontent.com/ministryofjustice/hmpps-probation-integration-services/main/projects/manage-offences-and-delius/tech-docs/spec/async-api.yaml&readOnly) |
23 changes: 23 additions & 0 deletions
23
projects/manage-offences-and-delius/tech-docs/spec/async-api.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
asyncapi: 2.6.0 | ||
info: | ||
title: Manage Offences and Delius | ||
description: Reflect changes to CJS offence codes in Delius | ||
version: 0.1.0 | ||
|
||
servers: | ||
development: | ||
url: https://sqs.eu-west-2.amazonaws.com/754256621582/probation-integration-dev-manage-offences-and-delius-queue | ||
protocol: sqs | ||
preproduction: | ||
url: https://sqs.eu-west-2.amazonaws.com/754256621582/probation-integration-preprod-manage-offences-and-delius-queue | ||
protocol: sqs | ||
production: | ||
url: https://sqs.eu-west-2.amazonaws.com/754256621582/probation-integration-prod-manage-offences-and-delius-queue | ||
protocol: sqs | ||
|
||
channels: | ||
hmpps-domain-events/manage-offences-and-delius/offence-changed: | ||
subscribe: | ||
operationId: | ||
message: | ||
$ref: https://raw.githubusercontent.com/ministryofjustice/hmpps-domain-events/main/spec/schemas/manage-offences/offence-changed.yml |