Skip to content

Clarifying the two kinds of ECS-related language libraries #19

@webmat

Description

@webmat

The two kinds I see are the following (the naming here is up for discussion):

ECS Libraries

These libraries can ultimately be used to create or consume ECS events. Part of their goal is to represent the schema's key names and data types in the target language with fidelity, using the language's idioms (OOP, using the language's type closest to ECS', etc.)

Delivering these requires a lot of work to map ECS & Elasticsearch semantics to the target language. Each ECS release will require a release of this type of library, since it's meant to map all of the ECS field definitions.

In this category:

ECS Logging Formatters

I see these as "drop-in" log formatters. By "drop-in" I mean as a baseline, developers need not care about ECS and all its fields per se. They should be useable by developers who just want to provide a log level, a message and perhaps a few structured keys. In doing so, these log formatters should then populate the correct ECS fields based on no changes to the application (other than changing the log formatter).

I like the Java library's list of fields that can be populated, based on this getting started experience.

These libraries should also eventually allow users that care about ECS and want to fill specific additional ECS fields to do so.

Once we reach a baseline functionality for these libraries, I think they will require less adjustments and changes over time. They will mostly map to a stable subset of ECS fields (see like to Java lib above), so an ECS release won't require a release of the library. When users want to fill more ECS fields, this can be done by using strings and datatypes that fit well enough so that the JSON representation will successfully populate an ECS index. They don't need the full type safety and support of the language, they just need the JSON output to match.

In this category:

I think both of these types of libraries can play together if we want: pass an "ECS object" to a log formatter, and it populates appropriate all ECS fields. But I don't see this as necessary. I still see them as distinct types of libraries.

Next steps

  • Converge on correct naming conventions for each.
  • Perhaps we need a spec for each kind? I see this new spec as a good starting point for the logging formatters.
  • Do we want to deliver one kind before the other?
  • Feel free to bring up any additional thing that needs to be hashed out between the two.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions