Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add option to set event.created in integration/agent #11578

Open
Oddly opened this issue Oct 29, 2024 · 0 comments
Open

Add option to set event.created in integration/agent #11578

Oddly opened this issue Oct 29, 2024 · 0 comments

Comments

@Oddly
Copy link

Oddly commented Oct 29, 2024

I would like to see a possibility to add an option in the Elastic Agent to add a field event.created with the timestamp of ingestion of the event. That is, a timestamp before the other processors will be run.
That way we can see how long an event took to travel from the source to the agent (in case of a TCP input) and, when we add a field with a timestamp as last processor, we can actually see how long (all) the processors of a agent took to run.

I would be even nicer to be able to set it (optionally) in the input options of an integration.

A diagram of the idea:

flowchart LR
    DataSource[Data Source] --> ElasticAgent
    subgraph ElasticAgent [Elastic Agent]
        SetEventCreated[Set event.created] --> BuiltInProcessors[Built-in Processors]
        BuiltInProcessors --> UserProcessors[User Processors]
        UserProcessors --> SetEventAgentOut[Set event.agent_out]
    end
    ElasticAgent --> Output[Output]

    classDef plain fill:#fff,stroke:#333,stroke-width:2px, border-radius: 5px;
    classDef fancy fill:#f9f7f7,stroke:#333,stroke-width:2px, border-radius: 5px;
    classDef agentBox fill:#83a4d4,fill-opacity:0.7,stroke:#333,stroke-width:2px, border-radius: 5px,stroke-dasharray: 5 5;
    classDef operation fill:#f7d1ba,stroke:#333,stroke-width:2px, border-radius: 5px;

    class DataSource,Output plain;
    class ElasticAgent agentBox;
    class SetEventCreated,BuiltInProcessors,UserProcessors,SetEventAgentOut operation;
Loading

Edit: Clarified

@Oddly Oddly changed the title Add option to enable event.created to be set Add option to set event.created in integration/agent Oct 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant