Reporting

Current time in SimData event attributes

praneshd
Engager

Using SimData to manufacture some artificial events into our Splunk world. However, SimData not allowing or provided any API which allows to set System date ( current date) to any attributes in event.

entity User {
    init {
        id = "bot-id";
    }
    every(spinOffPriquency m) {
        var sessionID = Guid();
        emit LogUserRequest {
                               instanceId: id
                             observationTime: <Current Time>;
        }
    }
}

Above example, I want to set observationTime to current system time. I don't see any method/api DLS (domain specific language) [page][1]

Some extent Template allows to set current time using {{_time}} but, this wont hit to template as an splunk event.

dponcelow_splun
Splunk Employee
Splunk Employee

This is a good point. Seems like we need a time function that takes a format and returns a string representation of the current simulation time. I'll try to get it into the next release.

0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.
Get Updates on the Splunk Community!

Tech Talk Recap | Mastering Threat Hunting

Mastering Threat HuntingDive into the world of threat hunting, exploring the key differences between ...

Observability for AI Applications: Troubleshooting Latency

If you’re working with proprietary company data, you’re probably going to have a locally hosted LLM or many ...

Splunk AI Assistant for SPL vs. ChatGPT: Which One is Better?

In the age of AI, every tool promises to make our lives easier. From summarizing content to writing code, ...