Skip to content
This repository was archived by the owner on Jan 5, 2024. It is now read-only.

Commit 251d761

Browse files
committed
changelog and upgrade guide
1 parent 47cd3af commit 251d761

File tree

2 files changed

+36
-8
lines changed

2 files changed

+36
-8
lines changed

CHANGES.rst

+9-6
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,17 @@ Changelog
22
=========
33

44

5-
0.15.3 (unreleased)
5+
0.16.0 (unreleased)
66
-------------------
77

8-
- Remove ``broker.py`` and depreciated arg scheme related code.
9-
- Simplify the TChannel event types. Removed ``operational_error``,
10-
``system_error`` and ``application_error``. Added ``on_error``
11-
- Remove ``CallableRequestHandler`` and ``BaseRequestHandler``.
12-
- **BREAKING** - remove ``retry_delay`` option in the ``send`` method.
8+
- Introduced new server API through methods ``tchannel.TChannel.thrift.register``,
9+
``tchannel.TChannel.json.register``, and ``tchannel.TChannel.raw.register`` - when these
10+
methods are used, endpoints are passed a ``tchannel.Request`` object, and are expected to
11+
return a ``tchannel.Response`` object. The deprecated ``tchannel.tornado.TChannel.register``
12+
continues to function how it did before. Note the breaking change to the top-level TChannel on the next line.
13+
- **BREAKING** - ``tchannel.TChannel.register`` no longer has the same functionality as ``tchannel.tornado.TChannel.register``,
14+
instead it exposes the new server API. See the upgrade guide for details.
15+
- **BREAKING** - remove ``retry_delay`` option in the ``tchannel.tornado.send`` method.
1316

1417

1518
0.15.2 (2015-08-07)

UPGRADE.rst

+27-2
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,37 @@ what broke and how to safely migrate to newer versions.
77
From 0.15 to 0.16
88
-----------------
99

10+
- ``tchannel.TChannel.register`` no longer mimicks ``tchannel.tornado.TChannel.register``,
11+
instead it exposes the new server API like so:
12+
13+
Before:
14+
15+
.. code:: python
16+
17+
from tchannel import TChannel
18+
19+
@tchannel.register('endpoint', 'json')
20+
def endpoint(request, response, proxy):
21+
response.write({'resp': 'body'})
22+
23+
24+
After:
25+
26+
.. code:: python
27+
28+
from tchannel import TChannel, Response
29+
30+
@tchannel.json.register
31+
def endpoint(request):
32+
return Response({'resp': 'body'})
33+
34+
1035
- Remove ``retry_delay`` option from ``tchannel.tornado.peer.PeerClientOperation.send``
1136
method.
1237

13-
Before: ``tchannel.request.send(retry_delay=300)``
38+
Before: ``tchannel.tornado.TChannel.request.send(retry_delay=300)``
1439

15-
After: no more ``retry_delay`` in ``tchannel.request.send()``
40+
After: no more ``retry_delay`` in ``tchannel.tornado.TChannel.request.send()``
1641

1742
From 0.14 to 0.15
1843
-----------------

0 commit comments

Comments
 (0)