-
-
Notifications
You must be signed in to change notification settings - Fork 91
agent: subscribe all connections #1655
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
This reverts commit 32a1f7f.
| getAllSndQueuesForDelivery db = map toSndQueue <$> DB.query_ db (sndQueueQuery <> " " <> delivery) | ||
| where | ||
| delivery = [sql| | ||
| JOIN (SELECT DISTINCT conn_id, snd_queue_id FROM snd_message_deliveries WHERE failed = 0) d |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wouldn't this skip queue altogether for delivery, even if it has some failed delivery? delivery is work item, I'm not sure it's correct to exclude queue here - though maybe it's fine for the context it's used in - highlighting to double check
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why would it be excluded? it picks distinct conn_id, snd_queue_id fields for rows where failed = 0.
| <$> DB.query_ | ||
| db | ||
| [sql| | ||
| SELECT DISTINCT c.user_id, q.host, q.port, COALESCE(q.server_key_hash, s.key_hash) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
check SELECT DISTINCT in postgres
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
to do what?
No description provided.