camunda-modeler icon indicating copy to clipboard operation
camunda-modeler copied to clipboard

Improve UX for HTTL mandatory for C7

Open toco-cam opened this issue 1 year ago • 19 comments

Problem you would like to solve

The current user experience around ensuring HTTL is set does not suit all user profiles. Users with a HTTL set as a Global Engine Flag are confused about the default values and the error warning.

Proposed solution

  • No default values are displayed in Modeler for HTTL (CMMN, DMN, BPMN)

  • Modeler displays an info with the suggestion to set the HTTL to 180 days as a starting point, with a link to the linting hints (in the docs) which explains why HTTL is necessary and how to set an engine HTTL

  • For Power Users (With engine configuration) the Modeler provides a flag to disable the info for users with HTTL configured on the engine)

Alternatives considered

Yes

Additional context

No response

toco-cam avatar Jan 11 '24 08:01 toco-cam

@toco-cam Thanks for opening this issue.

Let's get the documentation that is supposed to be linked in place. We can then go ahead to implement this fairly swiftly.

nikku avatar Jan 23 '24 09:01 nikku

@nikku can you share the link to the docs page again please.

toco-cam avatar Jan 23 '24 13:01 toco-cam

We feature modeling guidance here.

nikku avatar Jan 23 '24 13:01 nikku

Let me work on it.

prajwolbhandari1 avatar Jan 26 '24 03:01 prajwolbhandari1

@toco-cam @nikku

Did we decide on this solution?

On the proposed solution above:

  1. No default values are displayed in Modeler for HTTL (CMMN, DMN, BPMN) -- no default values.

  2. Modeler displays an info with the suggestion to set the HTTL to 180 days as a starting point, with a link to the linting hints (in the docs) which explains why HTTL is necessary and how to set an engine HTTL -- what exactly does it mean by 180 days as a starting point? Since you suggested no default values in #1. -- docs hints this link -> https://docs.camunda.org/manual/7.20/update/minor/719-to-720/#enforce-history-time-to-live

  3. For Power Users (With engine configuration) the Modeler provides a flag to disable the info for users with HTTL configured on the engine) -- which flag are you referring to? Can u please elaborate on this?

Also, are we going to use flags.json file to set historyTimeToLive value in modeler or just leaving empty with a linting doc link as mentioned above.

Attached: I made historyTimeToLive textfield as an optional. I will add linting hints - a doc link.

https://github.com/camunda/camunda-modeler/assets/147008971/a1aaeb67-53ff-455e-a97a-092594bd50c2

prajwolbhandari1 avatar Feb 01 '24 22:02 prajwolbhandari1

@nikku @toco-cam Once we finalize with a solution. Can you please put my name on the ticket? I can work on this.

prajwolbhandari1 avatar Feb 01 '24 22:02 prajwolbhandari1

Here is the updated history time to live lint that points to the doc on BMPM side. Please clarify on the above questions.

https://github.com/camunda/camunda-modeler/assets/147008971/b9abd523-02b2-4835-9569-eac9b0817992

prajwolbhandari1 avatar Feb 01 '24 23:02 prajwolbhandari1

@toco-cam @nikku any thoughts?

prajwolbhandari1 avatar Feb 05 '24 15:02 prajwolbhandari1

@prajwolbhandari1 Thanks for your work on this. We'll only be able to pick this up starting from next week. If you want to you can already open a PR in the mean time.

Validation for HTTL being missing must be updated via bpmnlint-plugin-camunda-compat. Thanks!

nikku avatar Feb 05 '24 15:02 nikku

@nikku thank you for your reply.

We are able to get rid of the validation updating bpmnlint-plugin-camunda-compat (Opening a PR soon) but we have few questions on the proposed solution that I posted above. Do you mind looking at it (few posts above)?

prajwolbhandari1 avatar Feb 05 '24 16:02 prajwolbhandari1

@nikku @toco-cam can you guys please help me understand the proposed solution? My question is above.

Also, are you sure we don't want https://github.com/camunda/camunda-modeler/issues/3869 as an option? It will help to set default value in modeler. I can see it will solve few use cases.

prajwolbhandari1 avatar Feb 06 '24 06:02 prajwolbhandari1

@prajwolbhandari1 Not sure which question you refer to. The only one I found was this one:

For Power Users (With engine configuration) the Modeler provides a flag to disable the info for users with HTTL configured on the engine)

-- which flag are you referring to? Can u please elaborate on this?

We are going to introduce a flag, controlled via flags.json or command line to opt-out of the HTTL hint. I propose the name of the flag shall be disable-httl-hint. We'll not provide a default value via that flag, as either the user shall explicitly set the HTTL or the engine mandates the HTTL to be used.

nikku avatar Feb 06 '24 07:02 nikku

@nikku appreciate it!

Does it make sense to put user hint as 'Set Time to Live as 180. <Link for docs>' ?
<Link for docs> -> https://docs.camunda.org/manual/7.20/update/minor/719-to-720/#enforce-history-time-to-live

prajwolbhandari1 avatar Feb 06 '24 15:02 prajwolbhandari1

I am working on with the team to raise a PR that we worked on so far. Raising the PR soon tomorrow or day after.

prajwolbhandari1 avatar Feb 06 '24 18:02 prajwolbhandari1

@toco-cam We could consider to address this along with https://github.com/camunda/camunda-modeler/issues/4120.

nikku avatar Feb 08 '24 07:02 nikku

@nikku @toco-cam I also see the similar message in cmmn deployments if I try to deploy a CMMN Diagram without filling "History cleanup".

prajwolbhandari1 avatar Feb 08 '24 07:02 prajwolbhandari1

@prajwolbhandari1 Thanks for your support!

No default values are displayed in Modeler for HTTL (CMMN, DMN, BPMN) The target is to handle all HTTL models similarly.

The idea was not to add a link directly to the toolbar - but instead add a "Model guideline" to https://docs.camunda.io/docs/next/components/modeler/reference/modeling-guidance/ and add a link into the linking text.

toco-cam avatar Feb 12 '24 15:02 toco-cam

We have an initial draft for the modeling guidance: https://github.com/camunda/camunda-docs/pull/3324.

nikku avatar Feb 15 '24 11:02 nikku

As a start we want to tackle BPMN. Later DMN and (unlikely but possible) CMMN would follow suite.

nikku avatar Feb 15 '24 11:02 nikku

In process of opening a PR for it. That way it's easier for you guys to see what we worked on and give feedback. Any feedback would be appreciated. We will try to fix accordingly.

prajwolbhandari1 avatar Feb 21 '24 00:02 prajwolbhandari1

@prajwolbhandari1 I think this makes sense.

I'll in the mean time review https://github.com/camunda/camunda-docs/pull/3324 and link it to our lint rule accordingly.

nikku avatar Feb 21 '24 09:02 nikku

Looks like cmmn-js-properties-panel is archived. Can't raise a PR on that repo.

prajwolbhandari1 avatar Feb 22 '24 05:02 prajwolbhandari1

Yes. We'll not invest into CMMN for the moment.

nikku avatar Feb 22 '24 08:02 nikku

Thanks for your PRs @prajwolbhandari1, I'll look into them today. Great work :clap:

nikku avatar Feb 22 '24 09:02 nikku

Proposed hint to C7 users regarding history time to live - https://github.com/bpmn-io/dmn-js-properties-panel/pull/82.

nikku avatar Feb 22 '24 11:02 nikku

Informative message info lint message - https://github.com/camunda/bpmnlint-plugin-camunda-compat/pull/160.

Companion change in @camunda/linting - https://github.com/camunda/linting/pull/100.

nikku avatar Feb 22 '24 14:02 nikku

@toco-cam Two options regarding the power-user flag:

  • :a: Opt out of validation (and assume that engine sets HTTL)
  • :b: Ensure that diagrams have a defined HTTL (in accordance with flag) => https://github.com/camunda/camunda-modeler/pull/4147.

My assessment:

:b: Ensures HTTL is always configured on a diagram in a nice way. :a: Allows users to NOT configure HTTL, and not bothering about it (as the contract is that engine configured it).

What do you think?

nikku avatar Feb 22 '24 14:02 nikku

@prajwolbhandari1 Thanks again. You PRs helped a ton to drive this forward.

We're still in the process of clarifying two things:

  • https://github.com/camunda/camunda-modeler/issues/4062#issuecomment-1959597395
  • Link to documentation page, documenting HTTL and user options => Likely is going to be https://docs.camunda.org/manual/latest/user-guide/process-engine/history/ (to be created page).

Only then we'll be able to move forward.

nikku avatar Feb 22 '24 14:02 nikku

@toco-cam Two options regarding the power-user flag:

My assessment:

🅱️ Ensures HTTL is always configured on a diagram in a nice way. 🅰️ Allows users to NOT configure HTTL, and not bothering about it (as the contract is that engine configured it).

What do you think?

I had created similar issue which was closed with a link to this one(https://github.com/camunda/camunda-modeler/issues/3869) - I personally like the approach of setting it through the flag gives flexibility for both Modeler level configuration and as well as respecting engine level where it is set

HarishMalavade avatar Feb 22 '24 20:02 HarishMalavade

@nikku thank you for the PR reviews.

Is there anything that you want from my side other than clarifying few things from @toco-cam ?

prajwolbhandari1 avatar Feb 22 '24 22:02 prajwolbhandari1