Skip to content

Releases: DataDog/dd-trace-py

0.8.0

10 Apr 17:19
Compare
Choose a tag to compare

New integrations

  • Add support for Tornado web 4.0+. Currently this integration is ignored by autopatching, but can be enabled via patch_all(tornado=True) (#204, docs -- thanks @ross for reviewing and testing the implementation)

Bugfixes

  • [docs] Minor updates to our documentation (#239, #237, #242, #244 -- thanks @liubin @pahaz)
  • [boto] Boto2 and Botocore integrations have safety check to prevent double patching (#240)
  • [boto] Use frames directly without calling getouterframes(). This is a major improvement that reduces the impact of our tracing calls for Boto2 (#243 -- thanks @wackywendell)
  • [django] make func_name work with any callable and not only with functions (#195, #203 -- thanks @m0n5t3r)

Breaking change

  • [elasticsearch] when importing elasticsearch before executing patch_all(), no traces are created. This patch changed where the PIN object is attached, so you should update your instrumentation as described below (#238)

Migrate from 0.7.x to 0.8.0

  • [elasticsearch] the PIN object was previously attached to the elasticsearch module while now it uses elasticsearch.Transport. If you were using the Pin to override some tracing settings, you must update your code from:
Pin.override(client, service='elasticsearch-traces')

to:

Pin.override(client.transport, service='elasticsearch-traces')

Internals update

  • the Python traces logs and returns error when there is a communication issue with the APM Agent (#173)
  • the wrap() tracer decorator can be extended by Python integrations when the usual approach is not suitable for the given execution context (#221)

Read the full changeset.

0.7.0

29 Mar 18:08
Compare
Choose a tag to compare

New integrations

  • Add support for boto (>=2.29.0) and botocore (>= 1.4.51) #209 . Currently these integrations are ignored by autopatching, but can be enabled via patch_all(boto=True, botocore=True)

New features

Bugfixes

  • [dbapi] Ensure cursors play well with context managers #231
  • [django] Provide a unique datadog_django app label to avoid clashes with existing app configs #235
  • [pyramid] Ensure pyramid spans have method and route metadata consistent with other web frameworks #220 (thanks @johnpkennedy)

0.6.0

09 Mar 13:47
Compare
Choose a tag to compare

New integrations

  • Add support for asynchronous Python. This is a major improvement that adds support for asyncio, aiohttp and gevent (#161, docs: asyncio - aiohttp - gevent)
  • Add Celery integration (#135, #196, docs)

New features

  • Add explicit support for Python 3.5, and 3.6 (#215, see supported versions)
  • print the list of unfinished spans if the debug_logging is activated; useful in synchronous environments to detect unfinished/unreported traces (#210)

Bugfixes

  • [mysql] mysql integration is patched when using patch() or patch_all() (#178)
  • [django] set global tracer tags from Django DATADOG_TRACE setting (#159)
  • [bottle] wrong tracer reference when set_service_info is invoked (#199)

Breaking changes

  • Default port 7777 has been replaced with the new 8126 available from Datadog Agent 5.11.0 and above (#212)
  • Removed the ThreadLocalSpanBuffer. It has been fully replaced by the Context propagation (#211)

Migrate from 0.5.x to 0.6.0

  • Datadog Agent 5.11.0 or above is required.
  • If you're using the ThreadLocalSpanBuffer manually, you need to use the Context class in your logic so that it is compliant with the Context propagation. Check the Advanced usage section.

Advanced usage
This is a list of new features that may be used for manual instrumentation when you're using a library or a framework that is not currently supported:

  • Use Context propagation instead of a global buffer. This plays well with asynchronous programming where a context switching may happen while handling different logical execution flows (#172)
  • tracer.trace() handles automatically the Context propagation and remains the preferable API
  • Add tracer.get_call_context() to retrieve the current Context instance that is holding the entire trace for this logical execution (docs)
  • Add start_span as a way to manually create spans, while handling the Context propagation (docs)

Read the full changeset.

0.5.5

15 Feb 15:29
Compare
Choose a tag to compare

Improvements

  • ElasticSearch integration takes care of the returning status code in case of a TransportError (#175)

Bugfixes

  • Pyramid integration handles properly the Span.error attribute if the response is a server error (#176)

Read the full changeset.

0.5.4

14 Feb 19:50
Compare
Choose a tag to compare

Integrations

  • added the Pyramid web framework

Enhancements

  • tracer.set_tags() will add tags to all spans created by a tracer.
  • span.tracer() will return the tracer that created a given span

Bug Fixes

  • correctly set service types on the Mongo and Falcon integrations.
  • documentation fixes
  • send less data to the agent in the SQL and redis integrations.

Read the full changeset

0.5.3

23 Dec 08:50
Compare
Choose a tag to compare

Bugfixes

  • [ElasticSearch] use ElasticSearch serializer so that the serialization works with dates, decimals and UUIDs #131
  • [Django] use an integer value for AGENT_PORT because Django recast strings as unicode strings, which invalidate the input for getaddrinfo() in Python 2.7 #140
  • [Tracer] downgrade high throughput log messages to debug so that it doesn't flood users logs #143

Compatibility

  • don't check if django.contrib.auth is installed through the django.apps module. This improves the best-effort support for Django < 1.7 #136

Read the full changeset

0.5.2

14 Dec 22:24
Compare
Choose a tag to compare

0.5.2 is a bugfix release.

Bug Fixes

  • include bottle docs

Read the full changeset.

0.5.1

13 Dec 04:21
Compare
Choose a tag to compare

0.5.1 is a bugfix release.

Bug Fixes

  • properly trace pymongo $in queries (See #125)
  • properly normalize bound and batch cassandra statements (see #126)
  • made the legacy cassandra tracing a no-op.

Read the full changeset.

0.5.0

07 Dec 10:40
Compare
Choose a tag to compare

Major changes

  • addedmsgpack-python as a dependency
  • using Trace Agent API v0.3 that supports both JSON and Msgpack formats
  • provided JSONEncoder and MsgpackEncoder that are switched at runtime the API v0.3 is not reachable (404)
  • MsgpackEncoder is the current default encoder
  • MsgpackEncoder will not be used if the pure Python implementation is used

Documentation

Read the full changeset

0.4.0

26 Nov 23:35
Compare
Choose a tag to compare

0.4.0 is a "major" release of the dd-trace-py. Please test thoroughly on staging before rolling out to your production clusters.

Enhancements

  • automatically patch contrib libraries with from ddtrace import monkey; monkey.patch_all(). A few notes:
    • The previous ways of patching still exist, but are deprecated and might be no-ops. They will be removed in a future version.
    • When you add patch_all remove your old instrumentation code.
    • Web frameworks still require middleware.
  • experimental support for (much faster) msgpack serialization. disabled by default. will be enabled in a future release.

Integrations

  • add integration for the [Bottle](web framework) web framework. (see #86)

Bug Fixes

  • correctly trace django without auth middleware (see #116)

Read the full changeset.