forked from celery/kombu
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Changelog
1480 lines (943 loc) · 40.8 KB
/
Changelog
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
.. _changelog:
================
Change history
================
.. _version-2.2.6:
2.2.6
=====
:release-date: 2012-07-10 17:00 P.M BST
- Adds ``messaging.entry_to_queue`` for compat with previous versions.
.. _version-2.2.5:
2.2.5
=====
:release-date: 2012-07-10 17:00 P.M BST
- Pidbox: Now sets queue expire at 10 seconds for reply queues.
- EventIO: Now ignores ``ValueError`` raised by epoll unregister.
- MongoDB: Fixes Issue #142
Fix by Flavio Percoco Premoli
.. _version-2.2.4:
2.2.4
=====
:release-date: 2012-07-05 16:00 P.M BST
- Support for msgpack-python 0.2.0 (Issue #143)
The latest msgpack version no longer supports Python 2.5, so if you're
still using that you need to depend on an earlier msgpack-python version.
Fix contributed by Sebastian Insua
- :func:`~kombu.common.maybe_declare` no longer caches entities with the
``auto_delete`` flag set.
- New experimental filesystem transport.
Contributed by Bobby Beever.
- Virtual Transports: Now support anonymous queues and exchanges.
.. _version-2.2.3:
2.2.3
=====
:release-date: 2012-06-24 17:00 P.M BST
- ``BrokerConnection`` now renamed to ``Connection``.
The name ``Connection`` has been an alias for a very long time,
but now the rename is official in the documentation as well.
The Connection alias has been available since version 1.1.3,
and ``BrokerConnection`` will still work and is not deprecated.
- ``Connection.clone()`` now works for the sqlalchemy transport.
- :func:`kombu.common.eventloop`, :func:`kombu.utils.uuid`,
and :func:`kombu.utils.url.parse_url` can now be
imported from the :mod:`kombu` module directly.
- Pidbox transport callback ``after_reply_message_received`` now happens
in a finally block.
- Trying to use the ``librabbitmq://`` transport will now show the right
name in the :exc:`ImportError` if :mod:`librabbitmq` is not installed.
The librabbitmq falls back to the older ``pylibrabbitmq`` name for
compatibility reasons and would therefore show ``No module named
pylibrabbitmq`` instead of librabbitmq.
.. _version-2.2.2:
2.2.2
=====
:release-date: 2012-06-22 02:30 P.M BST
- Now depends on :mod:`anyjson` 0.3.3
- Json serializer: Now passes :class:`buffer` objects directly,
since this is supported in the latest :mod:`anyjson` version.
- Fixes blocking epoll call if timeout was set to 0.
Fix contributed by John Watson.
- setup.py now takes requirements from the :file:`requirements/` directory.
- The distribution directory :file:`contrib/` is now renamed to :file:`extra/`
.. _version-2.2.1:
2.2.1
=====
:release-date: 2012-06-21 01:00 P.M BST
- SQS: Default visibility timeout is now 30 minutes.
Since we have ack emulation the visibility timeout is
only in effect if the consumer is abrubtly terminated.
- retry argument to ``Producer.publish`` now works properly,
when the declare argument is specified.
- Json serializer: didn't handle buffer objects (Issue #135).
Fix contributed by Jens Hoffrichter.
- Virtual: Now supports passive argument to ``exchange_declare``.
- Exchange & Queue can now be bound to connections (which will use the default
channel):
>>> exchange = Exchange('name')
>>> bound_exchange = exchange(connection)
>>> bound_exchange.declare()
- ``SimpleQueue`` & ``SimpleBuffer`` can now be bound to connections (which
will use the default channel).
- ``Connection.manager.get_bindings`` now works for librabbitmq and pika.
- Adds new transport info attributes::
- ``Transport.driver_type``
Type of underlying driver, e.g. "amqp", "redis", "sql".
- ``Transport.driver_name``
Name of library used e.g. "amqplib", "redis", "pymongo".
- ``Transport.driver_version()``
Version of underlying library.
.. _version-2.2.0:
2.2.0
=====
:release-date: 2012-06-07 3:10 P.M BST
:by: Ask Solem
.. _v220-important:
Important Notes
---------------
- The canonical source code repository has been moved to
http://github.com/celery/kombu
- Pidbox: Exchanges used by pidbox are no longer auto_delete.
Auto delete has been described as a misfeature,
and therefore we have disabled it.
For RabbitMQ users old exchanges used by pidbox must be removed,
these are named ``mailbox_name.pidbox``,
and ``reply.mailbox_name.pidbox``.
The following command can be used to clean up these exchanges::
VHOST=/ URL=amqp:// python -c'import sys,kombu;[kombu.Connection(
sys.argv[-1]).channel().exchange_delete(x)
for x in sys.argv[1:-1]]' \
$(sudo rabbitmqctl -q list_exchanges -p "$VHOST" \
| grep \.pidbox | awk '{print $1}') "$URL"
The :envvar:`VHOST` variable must be set to the target RabbitMQ virtual host,
and the :envvar:`URL` must be the AMQP URL to the server.
- The ``amqp`` transport alias will now use :mod:`librabbitmq`
if installed.
`py-librabbitmq`_ is a fast AMQP client for Python
using the librabbitmq C library.
It can be installed by::
$ pip install librabbitmq
It will not be used if the process is monkey patched by eventlet/gevent.
.. _`py-librabbitmq`: https://github.com/celery/librabbitmq
.. _v220-news:
News
----
- Redis: Ack emulation improvements.
Reducing the possibility of data loss.
Acks are now implemented by storing a copy of the message when the message
is consumed. The copy is not removed until the consumer acknowledges
or rejects it.
This means that unacknowledged messages will be redelivered either
when the connection is closed, or when the visibility timeout is exceeded.
- Visibility timeout
This is a timeout for acks, so that if the consumer
does not ack the message within this time limit, the message
is redelivered to another consumer.
The timeout is set to one hour by default, but
can be changed by configuring a transport option:
>>> Connection('redis://', transport_options={
... 'visibility_timeout': 1800, # 30 minutes
... })
**NOTE**: Messages that have not been acked will be redelivered
if the visibility timeout is exceeded, for Celery users
this means that ETA/countdown tasks that are scheduled to execute
with a time that exceeds the visibility timeout will be executed
twice (or more). If you plan on using long ETA/countdowns you
should tweak the visibility timeout accordingly::
BROKER_TRANSPORT_OPTIONS = {'visibility_timeout': 18000} # 5 hours
Setting a long timeout means that it will take a long time
for messages to be redelivered in the event of a power failure,
but if so happens you could temporarily set the visibility timeout lower
to flush out messages when you start up the systems again.
- Experimental `Apache ZooKeeper`_ transport
More information is in the module reference:
:mod:`kombu.transport.zookeeper`.
Contributed by Mahendra M.
- Redis: Priority support.
The message's ``priority`` field is now respected by the Redis
transport by having multiple lists for each named queue.
The queues are then consumed by in order of priority.
The priority field is a number in the range of 0 - 9, where
0 is the default and highest priority.
The priority range is collapsed into four steps by default, since it is
unlikely that nine steps will yield more benefit than using four steps.
The number of steps can be configured by setting the ``priority_steps``
transport option, which must be a list of numbers in **sorted order**::
>>> x = Connection('redis://', transport_options={
... 'priority_steps': [0, 2, 4, 6, 8, 9],
... })
Priorities implemented in this way is not as reliable as
priorities on the server side, which is why
nickname the feature "quasi-priorities";
**Using routing is still the suggested way of ensuring
quality of service**, as client implemented priorities
fall short in a number of ways, e.g. if the worker
is busy with long running tasks, has prefetched many messages,
or the queues are congested.
Still, it is possible that using priorities in combination
with routing can be more beneficial than using routing
or priorities alone. Experimentation and monitoring
should be used to prove this.
Contributed by Germán M. Bravo.
- Redis: Now cycles queues so that consuming is fair.
This ensures that a very busy queue won't block messages
from other queues, and ensures that all queues have
an equal chance of being consumed from.
This used to be the case before, but the behavior was
accidentally changed while switching to using blocking pop.
- Redis: Auto delete queues that are bound to fanout exchanges
is now deleted at channel.close.
- amqplib: Refactored the drain_events implementation.
- Pidbox: Now uses ``connection.default_channel``.
- Pickle serialization: Can now decode buffer objects.
- Exchange/Queue declarations can now be cached even if
the entity is non-durable.
This is possible because the list of cached declarations
are now kept with the connection, so that the entities
will be redeclared if the connection is lost.
- Kombu source code now only uses one-level of explicit relative imports.
.. _v220-fixes:
Fixes
-----
- eventio: Now ignores ENOENT raised by ``epoll.register``, and
EEXIST from ``epoll.unregister``.
- eventio: kqueue now ignores :exc:`KeyError` on unregister.
- Redis: ``Message.reject`` now supports the ``requeue`` argument.
- Redis: Remove superfluous pipeline call.
Fix contributed by Thomas Johansson.
- Redis: Now sets redelivered header for redelivered messages.
- Now always makes sure references to :func:`sys.exc_info` is removed.
- Virtual: The compression header is now removed before restoring messages.
- More tests for the SQLAlchemy backend.
Contributed by Franck Cuny.
- Url parsing did not handle MongoDB URLs properly.
Fix contributed by Flavio Percoco Premoli.
- Beanstalk: Ignore default tube when reserving.
Fix contributed by Zhao Xiaohong.
Nonblocking consume support
---------------------------
librabbitmq, amqplib and redis transports can now be used
non-blocking.
The interface is very manual, and only consuming messages
is non-blocking so far.
The API should not be regarded as stable or final
in any way. It is used by Celery which has very limited
needs at this point. Hopefully we can introduce a proper
callback-based API later.
- ``Transport.eventmap``
Is a map of ``fd -> callback(fileno, event)``
to register in an eventloop.
- ``Transport.on_poll_start()``
Is called before every call to poll.
The poller must support ``register(fd, callback)``
and ``unregister(fd)`` methods.
- ``Transport.on_poll_start(poller)``
Called when the hub is initialized.
The poller argument must support the same
interface as :class:`kombu.utils.eventio.poll`.
- ``Connection.ensure_connection`` now takes a callback
argument which is called for every loop while
the connection is down.
- Adds ``connection.drain_nowait``
This is a non-blocking alternative to drain_events,
but only supported by amqplib/librabbitmq.
- drain_events now sets ``connection.more_to_read`` if
there is more data to read.
This is to support eventloops where other things
must be handled between draining events.
.. _version-2.1.8:
2.1.8
=====
:release-date: 2012-05-06 3:06 P.M BST
:by: Ask Solem
* Bound Exchange/Queue's are now pickleable.
* Consumer/Producer can now be instantiated without a channel,
and only later bound using ``.revive(channel)``.
* ProducerPool now takes ``Producer`` argument.
* :func:`~kombu.utils.fxrange` now counts forever if the
stop argument is set to None.
(fxrange is like xrange but for decimals).
* Auto delete support for virtual transports were incomplete
and could lead to problems so it was removed.
* Cached declarations (:func:`~kombu.common.maybe_declare`)
are now bound to the underlying connection, so that
entities are redeclared if the connection is lost.
This also means that previously uncacheable entities
(e.g. non-durable) can now be cached.
* compat ConsumerSet: can now specify channel.
.. _version-2.1.7:
2.1.7
=====
:release-date: 2012-04-27 6:00 P.M BST
* compat consumerset now accepts optional channel argument.
.. _version-2.1.6:
2.1.6
=====
:release-date: 2012-04-23 1:30 P.M BST
* SQLAlchemy transport was not working correctly after URL parser change.
* maybe_declare now stores cached declarations per underlying connection
instead of globally, in the rare case that data disappears from the
broker after connection loss.
* Django: Added South migrations.
Contributed by Joseph Crosland.
.. _version-2.1.5:
2.1.5
=====
:release-date: 2012-04-13 3:30 P.M BST
* The url parser removed more than the first leading slash (Issue #121).
* SQLAlchemy: Can now specify url using + separator
Example::
Connection('sqla+mysql://localhost/db')
* Better support for anonymous queues (Issue #116).
Contributed by Michael Barrett.
* ``Connection.as_uri`` now quotes url parts (Issue #117).
* Beanstalk: Can now set message TTR as a message property.
Contributed by Andrii Kostenko
.. _version-2.1.4:
2.1.4
=====
:release-date: 2012-04-03 4:00 P.M GMT
* MongoDB: URL parsing are now delegated to the pymongo library
(Fixes Issue #103 and Issue #87).
Fix contributed by Flavio Percoco Premoli and James Sullivan
* SQS: A bug caused SimpleDB to be used even if sdb persistence
was not enabled (Issue #108).
Fix contributed by Anand Kumria.
* Django: Transaction was committed in the wrong place, causing
data cleanup to fail (Issue #115).
Fix contributed by Daisuke Fujiwara.
* MongoDB: Now supports replica set URLs.
Contributed by Flavio Percoco Premoli.
* Redis: Now raises a channel error if a queue key that is currently
being consumed from disappears.
Fix contributed by Stephan Jaekel.
* All transport 'channel_errors' lists now includes
:exc:`~kombu.exception.StdChannelError`.
* All kombu exceptions now inherit from a common
:exc:`~kombu.exceptions.KombuError`.
.. _version-2.1.3:
2.1.3
=====
:release-date: 2012-03-20 3:00 P.M GMT
:by: Ask Solem
* Fixes Jython compatibility issues.
* Fixes Python 2.5 compatibility issues.
.. _version-2.1.2:
2.1.2
=====
:release-date: 2012-03-01 01:00 P.M GMT
:by: Ask Solem
* amqplib: Last version broke SSL support.
.. _version-2.1.1:
2.1.1
=====
:release-date: 2012-02-24 02:00 P.M GMT
:by: Ask Solem
* Connection URLs now supports encoded characters.
* Fixed a case where connection pool could not recover from connection loss.
Fix contributed by Florian Munz.
* We now patch amqplib's ``__del__`` method to skip trying to close the socket
if it is not connected, as this resulted in an annoying warning.
* Compression can now be used with binary message payloads.
Fix contributed by Steeve Morin.
.. _version-2.1.0:
2.1.0
=====
:release-date: 2012-02-04 10:38 P.M GMT
:by: Ask Solem
* MongoDB: Now supports fanout (broadcast) (Issue #98).
Contributed by Scott Lyons.
* amqplib: Now detects broken connections by using ``MSG_PEEK``.
* pylibrabbitmq: Now supports ``basic_get`` (Issue #97).
* gevent: Now always uses the ``select`` polling backend.
* pika transport: Now works with pika 0.9.5 and 0.9.6dev.
The old pika transport (supporting 0.5.x) is now available
as alias ``oldpika``.
(Note terribly latency has been experienced with the new pika
versions, so this is still an experimental transport).
* Virtual transports: can now set polling interval via the
transport options (Issue #96).
Example::
>>> Connection('sqs://', transport_options={
... 'polling_interval': 5.0})
The default interval is transport specific, but usually
1.0s (or 5.0s for the Django database transport, which
can also be set using the ``KOMBU_POLLING_INTERVAL`` setting).
* Adds convenience function: :func:`kombu.common.eventloop`.
.. _version-2.0.0:
2.0.0
=====
:release-date: 2012-01-15 18:34 P.M GMT
:by: Ask Solem
.. _v200-important:
Important Notes
---------------
.. _v200-python-compatibility:
Python Compatibility
~~~~~~~~~~~~~~~~~~~~
* No longer supports Python 2.4.
Users of Python 2.4 can still use the 1.x series.
The 1.x series has entered bugfix-only maintenance mode, and will
stay that way as long as there is demand, and a willingness to
maintain it.
.. _v200-new-transports:
New Transports
~~~~~~~~~~~~~~
* ``django-kombu`` is now part of Kombu core.
The Django message transport uses the Django ORM to store messages.
It uses polling, with a default polling interval of 5 seconds.
The polling interval can be increased or decreased by configuring the
``KOMBU_POLLING_INTERVAL`` Django setting, which is the polling
interval in seconds as an int or a float. Note that shorter polling
intervals can cause extreme strain on the database: if responsiveness
is needed you shall consider switching to a non-polling transport.
To use it you must use transport alias ``"django"``,
or as an URL::
django://
and then add ``kombu.transport.django`` to ``INSTALLED_APPS``, and
run ``manage.py syncdb`` to create the necessary database tables.
**Upgrading**
If you have previously used ``django-kombu``, then the entry
in ``INSTALLED_APPS`` must be changed from ``djkombu``
to ``kombu.transport.django``::
INSTALLED_APPS = (…,
'kombu.transport.django')
If you have previously used django-kombu, then there is no need
to recreate the tables, as the old tables will be fully compatible
with the new version.
* ``kombu-sqlalchemy`` is now part of Kombu core.
This change requires no code changes given that the
``sqlalchemy`` transport alias is used.
.. _v200-news:
News
----
* :class:`kombu.mixins.ConsumerMixin` is a mixin class that lets you
easily write consumer programs and threads.
See :ref:`examples` and :ref:`guide-consumers`.
* SQS Transport: Added support for SQS queue prefixes (Issue #84).
The queue prefix can be set using the transport option
``queue_name_prefix``::
BrokerTransport('SQS://', transport_options={
'queue_name_prefix': 'myapp'})
Contributed by Nitzan Miron.
* ``Producer.publish`` now supports automatic retry.
Retry is enabled by the ``reply`` argument, and retry options
set by the ``retry_policy`` argument::
exchange = Exchange('foo')
producer.publish(message, exchange=exchange, retry=True,
declare=[exchange], retry_policy={
'interval_start': 1.0})
See :meth:`~kombu.connection.Connection.ensure`
for a list of supported retry policy options.
* ``Producer.publish`` now supports a ``declare`` keyword argument.
This is a list of entities (:class:`Exchange`, or :class:`Queue`)
that should be declared before the message is published.
.. _v200-fixes:
Fixes
-----
* Redis transport: Timeout was multiplied by 1000 seconds when using
``select`` for event I/O (Issue #86).
.. _version-1.5.1:
1.5.1
=====
:release-date: 2011-11-30 01:00 P.M GMT
:by: Ask Solem
* Fixes issue with ``kombu.compat`` introduced in 1.5.0 (Issue #83).
* Adds the ability to disable content_types in the serializer registry.
Any message with a content type that is disabled will be refused.
One example would be to disable the Pickle serializer:
>>> from kombu.serialization import registry
# by name
>>> registry.disable('pickle')
# or by mime-type.
>>> registry.disable('application/x-python-serialize')
.. _version-1.5.0:
1.5.0
=====
:release-date: 2011-11-27 06:00 P.M GMT
:by: Ask Solem
* kombu.pools: Fixed a bug resulting in resources not being properly released.
This was caused by the use of ``__hash__`` to distinguish them.
* Virtual transports: Dead-letter queue is now disabled by default.
The dead-letter queue was enabled by default to help application
authors, but now that Kombu is stable it should be removed.
There are after all many cases where messages should just be dropped
when there are no queues to buffer them, and keeping them without
supporting automatic cleanup is rather considered a resource leak
than a feature.
If wanted the dead-letter queue can still be enabled, by using
the ``deadletter_queue`` transport option::
>>> x = Connection('redis://',
... transport_options={'deadletter_queue': 'ae.undeliver'})
In addition, an :class:`UndeliverableWarning` is now emitted when
the dead-letter queue is enabled and a message ends up there.
Contributed by Ionel Maries Cristian.
* MongoDB transport now supports Replicasets (Issue #81).
Contributed by Ivan Metzlar.
* The ``Connection.ensure`` methods now accepts a ``max_retries`` value
of 0.
A value of 0 now means *do not retry*, which is distinct from :const:`None`
which means *retry indefinitely*.
Contributed by Dan McGee.
* SQS Transport: Now has a lowercase ``sqs`` alias, so that it can be
used with broker URLs (Issue #82).
Fix contributed by Hong Minhee
* SQS Transport: Fixes KeyError on message acknowledgements (Issue #73).
The SQS transport now uses UUID's for delivery tags, rather than
a counter.
Fix contributed by Brian Bernstein.
* SQS Transport: Unicode related fixes (Issue #82).
Fix contributed by Hong Minhee.
* Redis version check could crash because of improper handling of types
(Issue #63).
* Fixed error with `Resource.force_close_all` when resources
were not yet properly initialized (Issue #78).
.. _version-1.4.3:
1.4.3
=====
:release-date: 2011-10-27 10:00 P.M BST
* Fixes bug in ProducerPool where too many resources would be acquired.
.. _version-1.4.2:
1.4.2
=====
:release-date: 2011-10-26 05:00 P.M BST
:by: Ask Solem
* Eventio: Polling should ignore `errno.EINTR`
* SQS: str.encode did only start accepting kwargs after Py2.7.
* simple_task_queue example didn't run correctly (Issue #72).
Fix contributed by Stefan Eletzhofer.
* Empty messages would not raise an exception not able to be handled
by `on_decode_error` (Issue #72)
Fix contributed by Christophe Chauvet.
* CouchDB: Properly authenticate if user/password set (Issue #70)
Fix contributed by Rafael Duran Castaneda
* Connection.Consumer had the wrong signature.
Fix contributed by Pavel Skvazh
.. _version-1.4.1:
1.4.1
=====
:release-date: 2011-09-26 04:00 P.M BST
:by: Ask Solem
* 1.4.0 broke the producer pool, resulting in new connections being
established for every acquire.
.. _version-1.4.0:
1.4.0
=====
:release-date: 2011-09-22 05:00 P.M BST
:by: Ask Solem
* Adds module :mod:`kombu.mixins`.
This module contains a :class:`~kombu.mixins.ConsumerMixin` class
that can be used to easily implement a message consumer
thread that consumes messages from one or more
:class:`kombu.messaging.Consumer` instances.
* New example: :ref:`task-queue-example`
Using the ``ConsumerMixin``, default channels and
the global connection pool to demonstrate new Kombu features.
* MongoDB transport did not work with MongoDB >= 2.0 (Issue #66)
Fix contributed by James Turk.
* Redis-py version check did not account for beta identifiers
in version string.
Fix contributed by David Ziegler.
* Producer and Consumer now accepts a connection instance as the
first argument.
The connections default channel will then be used.
In addition shortcut methods has been added to Connection::
>>> connection.Producer(exchange)
>>> connection.Consumer(queues=..., callbacks=...)
* Connection has aquired a ``connected`` attribute that
can be used to check if the connection instance has established
a connection.
* ``ConnectionPool.acquire_channel`` now returns the connections
default channel rather than establising a new channel that
must be manually handled.
* Added ``kombu.common.maybe_declare``
``maybe_declare(entity)`` declares an entity if it has
not previously been declared in the same process.
* :func:`kombu.compat.entry_to_queue` has been moved to :mod:`kombu.common`
* New module :mod:`kombu.clocks` now contains an implementation
of Lamports logical clock.
.. _version-1.3.5:
1.3.5
=====
:release-date: 2011-09-16 06:00 P.M BST
:by: Ask Solem
* Python 3: AMQP_PROTOCOL_HEADER must be bytes, not str.
.. _version-1.3.4:
1.3.4
=====
:release-date: 2011-09-16 06:00 P.M BST
:by: Ask Solem
* Fixes syntax error in pools.reset
.. _version-1.3.3:
1.3.3
=====
:release-date: 2011-09-15 02:00 P.M BST
:by: Ask Solem
* pools.reset did not support after forker arguments.
.. _version-1.3.2:
1.3.2
=====
:release-date: 2011-09-10 01:00 P.M BST
:by: Mher Movsisyan
* Broke Python 2.5 compatibility by importing ``parse_qsl`` from ``urlparse``
* Connection.default_channel is now closed when connection is revived
after connection failures.
* Pika: Channel now supports the ``connection.client`` attribute
as required by the simple interface.
* pools.set_limit now raises an exception if the limit is lower
than the previous limit.
* pools.set_limit no longer resets the pools.
.. _version-1.3.1:
1.3.1
=====
:release-date: 2011-10-07 03:00 P.M BST
* Last release broke after fork for pool reinitialization.
* Producer/Consumer now has a ``connection`` attribute,
giving access to the :class:`Connection` of the
instance.
* Pika: Channels now have access to the underlying
:class:`Connection` instance using ``channel.connection.client``.
This was previously required by the ``Simple`` classes and is now
also required by :class:`Consumer` and :class:`Producer`.
* Connection.default_channel is now closed at object revival.
* Adds kombu.clocks.LamportClock.
* compat.entry_to_queue has been moved to new module :mod:`kombu.common`.
.. _version-1.3.0:
1.3.0
=====
:release-date: 2011-10-05 01:00 P.M BST
* Broker connection info can be now be specified using URLs
The broker hostname can now be given as an URL instead, of the format::
transport://user:password@hostname:port/virtual_host
for example the default broker is expressed as::
>>> Connection('amqp://guest:guest@localhost:5672//')
Transport defaults to amqp, and is not required.
user, password, port and virtual_host is also not mandatory and
will default to the corresponding transports default.
.. note::
Note that the path component (virtual_host) always starts with a
forward-slash. This is necessary to distinguish between the virtual
host '' (empty) and '/', which are both acceptable virtual host names.
A virtual host of '/' becomes:
amqp://guest:guest@localhost:5672//
and a virtual host of '' (empty) becomes::
amqp://guest:guest@localhost:5672/
So the leading slash in the path component is **always required**.
* Now comes with default global connection and producer pools.
The acquire a connection using the connection parameters
from a :class:`Connection`::
>>> from kombu import Connection, connections
>>> connection = Connection('amqp://guest:guest@localhost//')
>>> with connections[connection].acquire(block=True):
... # do something with connection