Restricted two input queues to 1 doc at a time

-Restricted input queue for NLP container to 1 doc at a time
-Restricted input queue for file ingest in enrichment to 1 doc at a time
This commit is contained in:
Will
2024-02-01 14:07:47 -08:00
parent 3f81957c33
commit 73d1771205
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -109,7 +109,7 @@ class Container(containers.DeclarativeContainer):
# Format: inputq_<queueName>_<taskWithNoUnderscores>
#
inputq_alert_slackwebhookalert = providers.Resource(create_consumer, config.rabbitmq_connection_uri, constants.Q_ALERT, pb.Alert, "slackwebhookalert")
inputq_filedata_fileprocessor = providers.Resource(create_consumer, config.rabbitmq_connection_uri, constants.Q_FILE_DATA, pb.FileDataIngestionMessage, "fileprocessor")
inputq_filedata_fileprocessor = providers.Resource(create_consumer, config.rabbitmq_connection_uri, constants.Q_FILE_DATA, pb.FileDataIngestionMessage, "fileprocessor", 1) # limit to 1 file at a time
inputq_filedataenriched_fileprocessor = providers.Resource(create_consumer, config.rabbitmq_connection_uri, constants.Q_FILE_DATA_ENRICHED, pb.FileDataEnrichedMessage, "fileprocessor")
inputq_process_processcategorizer = providers.Resource(create_consumer, config.rabbitmq_connection_uri, constants.Q_PROCESS, pb.ProcessIngestionMessage, "processcategorizer")
inputq_service_servicecategorizer = providers.Resource(create_consumer, config.rabbitmq_connection_uri, constants.Q_SERVICE, pb.ServiceIngestionMessage, "servicecategorizer")
+1 -1
View File
@@ -91,7 +91,7 @@ class App:
async def start_indexing_service(self) -> None:
async with (
await NemesisRabbitMQConsumer.create(
self.cfg.rabbitmq_connection_uri, constants.Q_FILE_DATA_PLAINTEXT, pb.FileDataPlaintextMessage, "indexingservice"
self.cfg.rabbitmq_connection_uri, constants.Q_FILE_DATA_PLAINTEXT, pb.FileDataPlaintextMessage, "indexingservice", 1
) as textQ,
):
service = IndexingService(textQ, self.cfg, self.storage)