Skip to content
This repository was archived by the owner on Sep 24, 2019. It is now read-only.
This repository was archived by the owner on Sep 24, 2019. It is now read-only.

The input module for extended details not using the checkpoint value #16

Description

@hettervik

Hi. I've had some problems with duplicate events from the extended details inputs, from the script input_module_puppet_enterprise_extended_details.py. After doing some tests we've concluded that the checkpoint value is never being used in the script. That is, the following if statement is always true.

    if ckpt_value == None:
        old = now - datetime.timedelta(minutes=5)
        #format the time
        # This is a timestamp in UTC-based ISO-8601 format (YYYY-MM-DDThh:mm:ssZ) 
        start_time = old.strftime("%Y-%m-%dT%H:%M:%SZ") 
    #if it does exist then checkpoint value is start time
    else:
        start_time=ckpt_value

Does anyone got any idea on why this might be the case?

The tests we did were based on setting the old = now - datetime.timedelta(minutes=5) to higher values. If the ckpt_value would have been sat, it wouldn't matter how big the timedelta was, as it's only used in the initial startup of the TA. However when we set the timedelta to e.g. 10 minutes, any extended details event is indexed 10 times, indicating that the lookback with the timedelta is used for every run.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions