- The ``pyramid_zodb``, ``pyramid_routesalchemy`` and ``pyramid_alchemy``
paster templates now use a default "commit veto" hook when configuring the
``repoze.tm2`` transaction manager in ``development.ini``. This prevents a
transaction from being committed when the response status code is within
the 400 or 500 ranges. See also
http://docs.repoze.org/tm2/#using-a-commit-veto.
| | |
| | | has been mutated, a cookie will be sent back in the response. Previously |
| | | its default value was ``False``. |
| | | |
| | | Paster Templates |
| | | ---------------- |
| | | |
| | | - The ``pyramid_zodb``, ``pyramid_routesalchemy`` and ``pyramid_alchemy`` |
| | | paster templates now use a default "commit veto" hook when configuring the |
| | | ``repoze.tm2`` transaction manager in ``development.ini``. This prevents a |
| | | transaction from being committed when the response status code is within |
| | | the 400 or 500 ranges. See also |
| | | http://docs.repoze.org/tm2/#using-a-commit-veto. |
| | | |
| | | 1.0a10 (2011-01-18) |
| | | =================== |
| | | |
| | |
| | | |
| | | - Write a "Whats New" (delta from BFG 1.3) |
| | | |
| | | - Use a commit veto when configuring repoze.tm2 in paster templates for |
| | | non-1X, 2X, or 3X responses. |
| | | |
| | | - Figure out how to slim the herd of paster templates. Related: |
| | | https://github.com/Pylons/pyramid/issues#issue/40, |
| | | https://github.com/Pylons/pyramid/issues#issue/42, |
| | |
| | | pipeline. This is a piece of middleware which closes the ZODB connection |
| | | opened by the ``PersistentApplicationFinder`` at the end of the request. |
| | | |
| | | The ``egg:repoze.tm#tm`` middleware is the last piece of middleware in the |
| | | pipeline. This commits a transaction near the end of the request unless |
| | | there's an exception raised. |
| | | The ``tm`` middleware is the last piece of middleware in the pipeline. This |
| | | commits a transaction near the end of the request unless there's an exception |
| | | raised or the HTTP response code is an error code. The ``tm`` refers to the |
| | | ``[filter:tm]`` section beneath the pipeline declaration, which configures |
| | | the transaction manager. |
| | | |
| | | The final line in the ``[pipeline:main]`` section is ``tutorial``, which |
| | | refers to the ``[app:tutorial]`` section above it. The ``[app:tutorial]`` |
| | |
| | | [pipeline:main] |
| | | pipeline = |
| | | egg:WebError#evalerror |
| | | egg:repoze.tm2#tm |
| | | tm |
| | | {{package}} |
| | | |
| | | [filter:tm] |
| | | use = egg:repoze.tm2#tm |
| | | commit_veto = repoze.tm:default_commit_veto |
| | | |
| | | [server:main] |
| | | use = egg:Paste#http |
| | | host = 0.0.0.0 |
| | |
| | | |
| | | requires = [ |
| | | 'pyramid', |
| | | 'repoze.tm2', |
| | | 'repoze.tm2>=1.0b1', # default_commit_veto |
| | | 'sqlalchemy', |
| | | 'zope.sqlalchemy', |
| | | 'WebError', |
| | |
| | | [pipeline:main] |
| | | pipeline = |
| | | egg:WebError#evalerror |
| | | egg:repoze.tm2#tm |
| | | {{project}} |
| | | tm |
| | | {{package}} |
| | | |
| | | [filter:tm] |
| | | use = egg:repoze.tm2#tm |
| | | commit_veto = repoze.tm:default_commit_veto |
| | | |
| | | [server:main] |
| | | use = egg:Paste#http |
| | |
| | | 'pyramid', |
| | | 'SQLAlchemy', |
| | | 'transaction', |
| | | 'repoze.tm2', |
| | | 'repoze.tm2>=1.0b1', # default_commit_veto |
| | | 'zope.sqlalchemy', |
| | | 'WebError', |
| | | ] |
| | |
| | | pipeline = |
| | | egg:WebError#evalerror |
| | | egg:repoze.zodbconn#closer |
| | | egg:repoze.tm#tm |
| | | tm |
| | | {{project}} |
| | | |
| | | [filter:tm] |
| | | use = egg:repoze.tm2#tm |
| | | commit_veto = repoze.tm:default_commit_veto |
| | | |
| | | [server:main] |
| | | use = egg:Paste#http |
| | | host = 0.0.0.0 |
| | |
| | | requires = [ |
| | | 'pyramid', |
| | | 'repoze.zodbconn', |
| | | 'repoze.tm', |
| | | 'repoze.tm2>=1.0b1', # default_commit_veto |
| | | 'ZODB3', |
| | | 'WebError', |
| | | ] |