Lowercase userIds before creation (task/{id}/identity-links)

Hi all,
is it possible to lowercase userIds, like assignees, candidates or groups from “outside” a camunda-bpm-platform fork? I played around with customPreBPMNParseListeners as ProcessEnginePlugin but I only have read access while parseTask(…) there and it feels kinda “wrong” :slight_smile: Maybe I can inject a custom mybatis configuration to get my problem solved, but I have no idea how :slight_smile: Does someone has an idea?

We need to lowercase all our ids cause “idA” has to be equal “ida”.

Best Regards
Alex

You can configure Task listeners to do this job.

Thnx for the fast response. Aren’t TaskListener stored kinda unsorted? I have to be sure that the lowercase-step is triggered before any other taskListener. If so, can I define TaskListeners within the ProcessEnginePlugin?

Alex

There’s no order defined for execution of TaskListeners, if required the order of execution you can implement composite design pattern.

Alternatively you can try execution listener at start event, where you can do the desired job.

Can you post your bpmn file, let me tell you best place to configure task listeners , so that to ensure lowercase operation will be executed at first place before other listeners.

Hi,
I cannot provide a bpmn file, because its a general operation which has to be done for each task as a first step. (I am not the only one who creates tasks here, so a best place cannot be set. Users will add TaskListener wherever they want to :slight_smile:)

Ok, I was able to solve it. I just created a TaskListeners (getTaskDefinition().addBuiltInTaskListener(…)) for create and assignement which rewrites the IdentityLinks if I have to lowercase the userId