Operations between timestamp of 2 logs


(Nickusor) #1

Hello,

I have next request and I’m looking for help.

My logs contains fields operation_id and step.

Ex : Operation_id : 123, Step : 1, Timestamp1.1
	 Operation_id : 124, Step : 1, Timestamp1.2
	 Operation_id : 124, Step : 2, Timestamp2.2
	 Operation_id : 123, Step : 2, Timestamp2.1

My request is that I need to get Timestamp2.1 - Timestamp1.1 for Operation_id : 123
and Timestamp2.2 - Timestamp1.2 for Operation_id : 124.
Can I do that?
If yes, how? And if not, can I create some fields like $message.timestamp.hourOfDay and
$message.timestamp.dayOfYear as number so I can do that specific operation?
Is there any way to automaticaly group logs by operation_id?

In the end, I want to have a quick values list(table) widget as following :

	Generic : Operation_id - ( Timestamp2.1 - Timestamp1.1 )

	Example : 123 - 2 days 3 hours
			  124 - 4 hours

Is this possible?

Thank you for your time and help!


(Philipp Ruland) #2

Heyo @nickusor,

are these values in one log message or are these seperate log messages? This decides on how easy it will be to implement :smiley:

Greetings,
Philipp


(Nickusor) #3

Hey,

These are separate log messages.

Example :

Log 1 : Operation_id : 123, Step : 1, Timestamp1.1

Log 2 : Operation_id : 124, Step : 1, Timestamp1.2

Log 3 : Operation_id : 124, Step : 2, Timestamp2.2

Log 4 : Operation_id : 123, Step : 2, Timestamp2.1

Thanks,
Nick :grinning:


(system) #4

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.