Background:
We are in the process of converting a traditional multi-service Windows Service (WS) application into an Azure Service Fabric microservices grid running on a Service Bus messaging layer.
In the WS application, the "data loader" service was a singleton to prevent duplication of effort with regards to loading data into a DB from external sources as part of a job.
In the new grid (and because we're using SQL Server 2016 with it's parallelised bulk data import functionality), we would like to have multiple instances of the "data loader" service but it is still a standard scenario that two or more jobs with dependencies on the same data set may be pushed onto the processing grid at one time.
Question:
Is there a standard pattern for ensuring that the duplication of effort with regards to loading specific sets of data in this type of architecture is avoided?