TIS Change Data Capture

Overview

Both the Connections and Recommendations features of the Revalidation Application rely on Elasticsearch to drive their list views and allow complex filtering and sorting. The Elasticsearch indices are aggregations of data from TIS, GMC and our own Recommendations service.

In order to keep these Elasticsearch indices up to date, we must capture changes in these data sources and propagate them to the various indices.

This page describes the process of capturing data changes from TIS via the TIS-TCS service.

Event Listeners

Changes in TIS data are captured via methods annotated with the Spring @EventListener annotation. The change is captured and sent via the RabbitMq queue: reval.queue.connection.update .

NOTE: reval.queue.connection.update is a legacy name, these updates in fact go to the integration service and are also propagated to the recommendation service

The following event listener methods are currently captured by this process:

  • handleCurriculumMembershipSavedEvent

  • handleCurriculumMembershipCreatedEvent

  • handleCurriculumMembershipDeletedEvent

  • handlePersonSavedEvent

  • handlePersonCreatedEvent

  • handlePersonDeletedEvent

  • handleProgrammeSavedEvent

Data Format

Currently when a change is captured all the information pertinent to the updated doctor is retrieved and sent (e.g. if a doctor’s first name is changed, their other Person, Curriculum and Programme data is also sent along with the name change). This is not particularly efficient and there is room for improvement here.