diff --git a/adsputils/__init__.py b/adsputils/__init__.py index ddc1701..fdbb20f 100644 --- a/adsputils/__init__.py +++ b/adsputils/__init__.py @@ -453,13 +453,15 @@ def forward_message(self, *args, **kwargs): self.forward_message(message, pipeline=OUTPUT_PIPELINE) """ pipeline = kwargs.get('pipeline', 'default') - + + if not kwargs.get('priority', None): priority = None + if self.forward_message_dict and pipeline: if not self.forward_message_dict[pipeline].get('broker'): raise NotImplementedError('Sorry, your app is not properly configured (no broker).') forwarding_connection = BrokerConnection(self.forward_message_dict[pipeline].get('broker')) self.logger.debug('Forwarding results out to: %s', self.forward_message_dict[pipeline].get('broker')) - return self.forward_message_dict[pipeline]['forward message'].apply_async(args, kwargs, connection=forwarding_connection) + return self.forward_message_dict[pipeline]['forward message'].apply_async(args, kwargs, connection=forwarding_connection, priority=priority) else: raise NotImplementedError('Sorry, your app is not properly configured.')