Expand my Community achievements bar.

Don’t miss the AEM Skill Exchange in SF on Nov 14—hear from industry leaders, learn best practices, and enhance your AEM strategy with practical tips.
SOLVED

Obtaining job-id inside Workbench

Avatar

Former Community Member

Hi,

How do I obtain the invocation job-id in a process inside Workbench? It doens't turn up in the xpath builder.

I would like to use it to identify the job when calling a web service.

1 Accepted Solution

Avatar

Correct answer by
Level 10

You can directly query the database and get the invocation_id using Sql Activity.

Table Name : tb_process_instance

Coloumn : long_lived_invocation_id

Query : SELECT long_lived_invocation_id FROM tb_process_instance WHERE id=11111

Nith

View solution in original post

4 Replies

Avatar

Former Community Member

Bump! It can't be that hard. Beanshell? Anything? Anyone?

Avatar

Correct answer by
Level 10

You can directly query the database and get the invocation_id using Sql Activity.

Table Name : tb_process_instance

Coloumn : long_lived_invocation_id

Query : SELECT long_lived_invocation_id FROM tb_process_instance WHERE id=11111

Nith

Avatar

Former Community Member

Thanks Nith - works like a charm (although a bit odd having to ask the database).

Why separate id and invokation-id?

Avatar

Level 10

I'm not sure why two separate Ids.

I suspect in this way:

An invocation to a long-lived process will be queued and assigned with an unique invocation Id. The uniquie Process Id will be assigned to it only when it comes to a running status.

This invocation id is not applicable to short-lived process invocations.

Nith