Form failure: The context path is either empty or not defined

Hi to all.

I’ve deployed my process in Modeler and I’ve been trying to start a new process instance by making a POST request in a REST client (Postman) according to the steps described here:

My issue is that when I click on my 1st task in Tasklist, it doesn’t load my task form and I 'm always taking this message:

Does anyone know please what does it mean and what can I do for this?

Thanks a lot,
Steve

I tried to redeploy my process and start a new process instance with the previous way described in Docs (via Eclipse) and I managed to load my 1st user task form in Tasklist.
So, does anyone know which is the issue with the new described way (on starting a new process instance) here?
https://docs.camunda.org/get-started/quick-start/deploy/#start-a-process-instance

Thanks,
Steve

@steftriant Are you perhaps using an embedded form via a key such as: embedded:app:forms/form.html ?

Hi @steftriant,

See below docs to get more information about how to create an embedded task form and refer to it.
https://docs.camunda.org/manual/7.9/user-guide/task-forms/#embedded-task-forms

May we know how you deploy and refer to your form?

1 Like

Hi @some-camunda-user.

Yes, I’ve defined this embedded form as embedded:app:forms/FORM_NAME.html at the Form Key in Modeler.

Steve

Hi @hassang.

Thanks for your feedback.
Yes, I 've taken into account of course those information in Docs.
As, I just answered to @some-camunda-user here, I’ve defined this embedded form as embedded:app:forms/FORM_NAME.html at the Form Key in Modeler.

Steve

Hi @steftriant,

But how did you deploy your html form?
Be informed that you can’t deploy embedded task forms through deploy button of Modeler.

You could deploy it as part of a process application as below example

@hassang Is there perhaps an example to deploy your forms as a separate web app, apart from camunda?

@steftriant,

Yes, Below example is a separate war application.

@steftriant, Excellent thanks, having a look at the invoice example. I was under the impression that the forms could just be deployed as a separate web app or static html but I see it should be a Process Application, is that correct?

Hi @steftriant,
You either could

  • Deploy it as part of a war process application where you refer to your form as “embedded:app:forms/FORM_NAME.html”

  • Or you could deploy your bpmn model & html form files through rest api as part of the same deployment where you refer to your form as “embedded:deployment:forms/FORM_NAME.html”

1 Like

Hi @hassang.

I can deploy my embedded html task form only with the previously described way in Camunda Docs (I can’t find those information now there but I still remember the way through Eclipse).
My process deployment was also successful through deploy button of Modeler but for some reason I couldn’t start a new process instance as described here:
https://docs.camunda.org/get-started/quick-start/deploy/
In other words the engine couldn’t load my embedded html task form in Tasklist

Steve

@hassang, I just caught what you mean here, thank you very much :wink:

Steve

Correction:

When you choose the 2nd option,
The deployed form should be referenced as
embedded:deployment:FORM_NAME.html
Not
embedded:deployment:forms/FORM_NAME.html

1 Like

Hi,

If you have a java spring application and you want to use embedded forms, make sure to have the following annotations in your main class:
@SpringBootApplication
@EnableProcessApplication

I had the error message " Form failure: The context path is either empty or not defined" and the @EnableProcessApplication solved my problem.

Kind regards,
Marvin

Does anybody know what I can do if I can’t use @EnableProcessApplication for other reasons?

TIA
Christian

Here’s the discussion:

I forgot in my project to add extends SpringBootProcessApplication to the Spring application, that lead to the problem that I could not remove the @EnableProcessApplication.

So if you just use:
@SpringBootApplication
public class ExampleApplication extends SpringBootProcessApplication {

    public static void main(String[] args){
        SpringApplication.run(ExampleApplication.class);
    }
}

It should work :slight_smile:

1 Like