Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
coolamqp
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
public
coolamqp
Commits
fb103cb2
Commit
fb103cb2
authored
5 years ago
by
Piotr Maślanka
Browse files
Options
Downloads
Patches
Plain Diff
pydoc fixes
parent
243a6034
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
coolamqp/attaches/consumer.py
+0
-1
0 additions, 1 deletion
coolamqp/attaches/consumer.py
coolamqp/attaches/publisher.py
+6
-8
6 additions, 8 deletions
coolamqp/attaches/publisher.py
with
6 additions
and
9 deletions
coolamqp/attaches/consumer.py
+
0
−
1
View file @
fb103cb2
...
...
@@ -192,7 +192,6 @@ class Consumer(Channeler):
self
.
method_and_watch
(
BasicCancel
(
self
.
consumer_tag
,
False
),
[
BasicCancelOk
],
self
.
on_close
)
self
.
channel_close_sent
=
True
else
:
if
not
self
.
channel_close_sent
and
self
.
state
==
ST_ONLINE
:
self
.
method
(
ChannelClose
(
0
,
b
'
cancelling
'
,
0
,
0
))
...
...
This diff is collapsed.
Click to expand it.
coolamqp/attaches/publisher.py
+
6
−
8
View file @
fb103cb2
...
...
@@ -65,6 +65,12 @@ class Publisher(Channeler, Synchronized):
Since this may be called by other threads than ListenerThread, this has locking.
_pub and on_fail are synchronized so that _pub doesn
'
t see a partially destroyed class.
:param mode: Publishing mode to use. One of:
MODE_NOACK - use non-ack mode
MODE_CNPUB - use consumer publishing mode. A switch to MODE_TXPUB will be made
if broker does not support these.
:raise ValueError: mode invalid
"""
MODE_NOACK
=
0
# no-ack publishing
MODE_CNPUB
=
1
# RabbitMQ publisher confirms extension
...
...
@@ -76,14 +82,6 @@ class Publisher(Channeler, Synchronized):
"""
This publisher will never work (eg. MODE_CNPUB on a broker not supporting publisher confirms)
"""
def
__init__
(
self
,
mode
):
"""
Create a new publisher
:param mode: Publishing mode to use. One of:
MODE_NOACK - use non-ack mode
MODE_CNPUB - use consumer publishing mode. A switch to MODE_TXPUB will be made
if broker does not support these.
:raise ValueError: mode invalid
"""
Channeler
.
__init__
(
self
)
Synchronized
.
__init__
(
self
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment