How can I get current time in bpmn2.0?


#1

Hello everyone.
I have a question about how to get current time in the bpmn2.0.

Why I want to get the current time because I want to do this.
Here is what I want to do.

So the question is How can I get current time in the dpmn2.0 ?

Thanks you all.


#2

I know some sulution of how to resove this. Such like call a service task that will return the current date something like this. But I want an easily way to do that. Someone know the way ?


#3

Hi @himly,

there is a shortcut available: https://docs.camunda.org/manual/7.10/user-guide/process-engine/expression-language/#internal-context-functions

Hope this helps, Ingo


#4

Hi, @Ingo_Richtsmeier
This saved my day. Thank you so much. Hope you have a good day.


#5

Here is the solution to compare current date with another one in El expression.

${now().getTime() < millionSecondTime}

for example

${now().getTime() < 1548728165057}