WAR deployment Camunda Forms - Form Failure

I am trying to use the Camunda Tomcat instance to deploy a process project. I am using a mix of embedded and Camunda forms. I have placed both the Camunda form and the embedded form into the /webapp/forms project folder. The embedded for work fine but the Camunda form says “Form Failure” when I start an instance. The logs show no errors that I can see.

This is how I setup the Camunda Form:

  1. Create the Form file using Modeler - Basic Text Fields for now - saved in /webapp/forms
  2. Set the ID of the form to “confirmQuoteInformationForm”
  3. The BPMN file lives in the /resources folder
  4. On a user task I set the Form Type to: Camunda Forms
  5. On a user task I set the Form Ref to: “confirmQuoteInformationForm”
  6. On a user task I set the Binding to: “deployment”
  7. I build and copy to Tomcat /webapps
  8. I can verify the BPMN deploy instance in cockpit.

Please help as there is a lot of broken information on the net about this depending on the version, config and deployment of Camunda you are running.

I am using Camunda Version: camunda-bpm-tomcat-7.16.0

Thanks in advance

Hi @SlappyAUS,

I see that you are following the process application approach so your forms whether embedded html forms or Camunda forms are included in the process application itself (not deployed to the database)

Do the same as you did with embedded html forms but use below expression for formKey
camunda-forms:app:forms/[FILE_NAME].form

Thank you for the assistance. However I still get the same error.
This is the extract from my BPMN:

> <bpmn:userTask id="camundaForm" name="Camunda Form" camunda:formRef="camunda-forms:app:forms/sampleForm.form" camunda:formRefBinding="deployment">
>       <bpmn:incoming>Flow_10imeub</bpmn:incoming>
>       <bpmn:outgoing>Flow_11sxzq4</bpmn:outgoing>
>  </bpmn:userTask>

This is the error the task list is producing

The embedded form works no problems

Screen Shot 2021-11-29 at 09.15.23

The form is very basic.

Form JSON

{
  "schemaVersion": 2,
  "components": [
    {
      "text": "# Quote Information",
      "type": "text",
      "id": "Field_16ir98w"
    },
    {
      "label": "Quote Number",
      "type": "textfield",
      "id": "Field_0bodlw0",
      "key": "field_1pzm50k",
      "description": "Quote number from the email",
      "validate": {
        "required": true,
        "minLength": 5,
        "maxLength": 10
      }
    }
  ],
  "type": "default",
  "id": "sampleForm"
}

Project folder structure

SOLVED:
As @hassang said one needs to set the form key as per embedded form, and specifically you need the Form Type property set to “Embedded Form” and NOT “Camunda Form”. Which retrospectively makes total sense. :crazy_face:

Thank you @hassang

2 Likes

I am about to send below snip.

image

Glad to hear that you managed to solve it.