Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Lohse, Felix
lab-stream
Commits
91d4d4a3
Commit
91d4d4a3
authored
Mar 03, 2021
by
Nane Kratzke
Browse files
Less clutter on the log
parent
746d763a
Changes
1
Hide whitespace changes
Inline
Side-by-side
messaging/queueing-consumer.py
View file @
91d4d4a3
...
...
@@ -9,6 +9,8 @@ channel = os.environ.get("CHANNEL", "xqueue")
queue
=
MQueue
(
channel
,
redis
.
Redis
(
host
=
host
,
port
=
port
,
db
=
0
))
for
since
,
msg
in
queue
.
listen
():
print
(
f
"
{
since
}
:
{
msg
}
"
)
# We would normally process the messages here.
# However, to not overflow the log we skip this here.
# You can print the message, if you want.
# print(f"{ since }: { msg }")
print
()
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment