• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

timberio / timber-elixir / 785 / 1
65%
master: 42%

Build:
Build:
LAST BUILD BRANCH: mb-348-fix-add_context-spec
DEFAULT BRANCH: master
Ran 29 Jan 2019 01:26AM UTC
Files 45
Run time 4s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

29 Jan 2019 01:18AM UTC coverage: 65.227% (-9.1%) from 74.286%
785.1

Pull #326

travis-ci

web-flow
Remove `event`, `event.custom`, and `context.custom` namespaces to follow new Timber 2.0 schema changes

Timber 2.0 no longer requires a strict schema, this means that events and contexts can be defined freely without the need to be nested under specific `event`, `event.custom`, or `context.custom` keys.

For example, this `http_response` event went from this:

```json
{
  "level": "info",
  "message": "Order abcd1234 placed",
  "event":
    "custom": {
      "order_placed": {
        "id": "abcd1234",
        "total": 100
      }
    }
  }
}
```

To this:

```json
{
  "level": "info",
  "message": "Order abcd1234 placed",
  "order_placed": {
    "id": "abcd1234",
    "total": 100
  }
}
```

Timber 2.0 is a major update in the Timber platform that does away with a strict or opinionated schema. Instead, it provides a generic framework for logging structured data without any assumptions around events types, names, or structure. That is left at the discretion of the user, giving users free reign as it relates to the events they capture as well as the resulting schema. This has a number of benefits that are reflected in this PR:

1. Custom events are no longer required to be placed in the `event.custom.*` keyspace. This removes the resulting schema awkwardness when using custom events in searches and visualizations.
2. Custom contexts are no longer required to be placed in the `context.custom.*` keyspace for the same reasons mentioned above.
3. Official Timber event structs are no longer required since each user of the Timber library can define events in any structured deems appropriate.
4. Exception event structuring from the exception message itself has been removed in favor of using [`:timber_exceptions`](https://github.com/timberio/timber-elixir-exceptions)

== Backwards compatibility ==

This PR should NOT break backwards compatibility. Methods no longer necessary have been marked as deprecated and will be removed in Timber `4.0.0`
Pull Request #326: Remove `event`, `event.custom`, and `context.custom` namespaces

302 of 463 relevant lines covered (65.23%)

6.35 hits per line

Source Files on job 785.1
  • Tree
  • List 0
  • Changed 33
  • Source Changed 26
  • Coverage Changed 32
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 43
  • Travis Job 785.1
  • 2c84d27e on github
  • Prev Job for on remove-namespaces (#780.1)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc