Errors caused by deployed forms

Hi everyone,
I’m deploying a form using the piece of code attach below (as I read in the documentation).

FormEngine formEngine = FormEngines.getDefaultFormEngine();
FormRepositoryService formRepositoryService = formEngine.getFormRepositoryService();
formRepositoryService.createDeployment()
		    .name("EnoughSubmissions")
		    .addClasspathResource("EnoughSubmissions.form")
		    .deploy();

The form is deployed (it appears in the Form Engine Deployments sections in flowable-admin application). However, something is not working as it should, due to the fact that the process doesn’t found the form (when claiming the task the form is blank). The ERROR that is shown is the following:

07:32:21,374 [http-nio-8080-exec-18] ERROR org.flowable.engine.common.impl.interceptor.CommandContext  - masked exception in command context. for root cause, see below as it will be rethrown later.
org.flowable.engine.common.api.FlowableObjectNotFoundException: Form model for task chekIfEnough cannot be found for form key enoughSubmissions

In addition, I cannot remove the deployed forms in flowable-admin application as I do with the deployed processes. The error shown in the application is: ALERT.FORM-DEPLOYMENT.DELETE-ERROR. So I have to remove it directly from the database
I revised the deployments and the key “enoughSubmissions” is the key of the form that exists and it’s deployed. Any idea of what is could be the problem?

Thanks,
Clara

Hi,

The forms should be deployed together with the process models to make sure the Form definition can be found in the Flowable task application. Is it not easier for you to use the Flowable Modeler to create the app zip file or deploy the app directly from the Flowable Modeler. Then the deployment is done automatically and works out-of-the-box.

Best regards,

Tijs

Hi,
Thanks for the quick response. I created the forms and processes from the Flowable Modeler. When I publish the application, everything works as expected but when I deploy the app zip file from Eclipse I have the same problem (the form with the specified key is not found).
I deployed the .zip like this:

String barFileName = "appFile.zip";
ZipInputStream inputStream = new ZipInputStream(new FileInputStream(barFileName));
Deployment deployment = repositoryService.createDeployment().addZipInputStream(inputStream).deploy();

I want to deploy the application from Eclipse instead of publishing directly from flowable modeler. Any idea of what could be the problem?

Thanks

Hi again,
I have a .zip file which contains a form and a process. When I import this file from flowable-admin both files are deployed successfully but when I deploy it from Eclipse the form is never deployed.
Is this a normal situation? Should I had something to my Eclipse project to achieve this functionality?

Thanks,
Clara