30 | );
31 | }
32 |
33 | Table.Head = function Head({ children }) {
34 | return
{children}
;
35 | };
36 |
37 | Table.Row = function Row({ children }) {
38 | return
{children}
;
39 | };
40 |
41 | Table.Cell = function Cell({ children }) {
42 | return
{children}
;
43 | };
44 |
--------------------------------------------------------------------------------
/cockpit/cockpit-fullstack-count-processes/frontend/src/Table/Table.scss:
--------------------------------------------------------------------------------
1 | .Table {
2 | width: 100%;
3 | max-width: 100%;
4 |
5 | .TableRow {
6 | &:nth-of-type(odd) {
7 | background-color: #f9f9f9;
8 | }
9 | &:hover {
10 | background-color: #eaf0f8;
11 | }
12 | }
13 |
14 | .TableHead {
15 | padding: 5px;
16 | border-bottom: 2px solid #ddd;
17 | }
18 |
19 | .TableCell {
20 | padding: 5px;
21 | line-height: 1.5;
22 | vertical-align: top;
23 | border-top: 1px solid #ddd;
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/cockpit/cockpit-fullstack-count-processes/frontend/src/Table/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | export { default as Table } from "./Table";
19 |
--------------------------------------------------------------------------------
/cockpit/cockpit-fullstack-count-processes/frontend/src/plugin.js:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | import React from "react";
19 | import ReactDOM from "react-dom";
20 |
21 | import ProcessInstanceCount from "./ProcessInstanceCount";
22 |
23 | let container = null;
24 |
25 | export default {
26 | id: "process-instance-count",
27 | pluginPoint: "cockpit.dashboard",
28 | render: (node, { api }) => {
29 | container = node;
30 | ReactDOM.render(
31 | ,
32 | container
33 | );
34 | },
35 | unmount: () => {
36 | ReactDOM.unmountComponentAtNode(container);
37 | },
38 |
39 | // make sure we have a higher priority than the default plugin
40 | priority: 12,
41 | };
42 |
--------------------------------------------------------------------------------
/cockpit/cockpit-fullstack-count-processes/screenshot.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/cockpit/cockpit-fullstack-count-processes/screenshot.png
--------------------------------------------------------------------------------
/cockpit/cockpit-fullstack-count-processes/src/main/java/org/camunda/bpm/cockpit/plugin/sample/db/ProcessInstanceCountDto.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.cockpit.plugin.sample.db;
18 |
19 | /**
20 | *
21 | * @author nico.rehwaldt
22 | */
23 | public class ProcessInstanceCountDto {
24 |
25 | private String key;
26 |
27 | private int instanceCount;
28 |
29 | public String getKey() {
30 | return key;
31 | }
32 |
33 | public void setKey(String key) {
34 | this.key = key;
35 | }
36 |
37 | public int getInstanceCount() {
38 | return instanceCount;
39 | }
40 |
41 | public void setInstanceCount(int instanceCount) {
42 | this.instanceCount = instanceCount;
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/cockpit/cockpit-fullstack-count-processes/src/main/resources/META-INF/services/org.camunda.bpm.cockpit.plugin.spi.CockpitPlugin:
--------------------------------------------------------------------------------
1 | org.camunda.bpm.cockpit.plugin.sample.SamplePlugin
--------------------------------------------------------------------------------
/cockpit/cockpit-fullstack-count-processes/src/main/resources/org/camunda/bpm/cockpit/plugin/sample/queries/sample.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
17 |
18 |
--------------------------------------------------------------------------------
/cockpit/cockpit-fullstack-count-processes/src/main/resources/plugin-webapp/sample-plugin/info.txt:
--------------------------------------------------------------------------------
1 | # Client side assets of the cockpit-plugin-sample
--------------------------------------------------------------------------------
/cockpit/cockpit-fullstack-count-processes/src/test/resources/META-INF/services/org.camunda.bpm.engine.rest.spi.ProcessEngineProvider:
--------------------------------------------------------------------------------
1 | org.camunda.bpm.cockpit.plugin.test.application.TestProcessEngineProvider
--------------------------------------------------------------------------------
/cockpit/cockpit-fullstack-count-processes/src/test/resources/camunda.cfg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/cockpit/cockpit-greetings-plugin/README.md:
--------------------------------------------------------------------------------
1 | Cockpit Greetings Plugin
2 | ========================
3 |
4 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/cockpit/cockpit-greetings-plugin).
5 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
6 | might need to adjust them to make them work.
--------------------------------------------------------------------------------
/cockpit/cockpit-open-incidents/README.md:
--------------------------------------------------------------------------------
1 | "Open Incidents" Cockpit Plugin
2 | ===============================
3 |
4 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/cockpit/cockpit-open-incidents).
5 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
6 | might need to adjust them to make them work.
--------------------------------------------------------------------------------
/cockpit/cockpit-react-involved-users/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "presets": ["@babel/preset-env", "@babel/preset-react"],
3 | "exclude": "node_modules/**",
4 | "plugins": ["@babel/plugin-transform-runtime"]
5 | }
--------------------------------------------------------------------------------
/cockpit/cockpit-react-involved-users/.gitignore:
--------------------------------------------------------------------------------
1 | node_modules
2 | dist
--------------------------------------------------------------------------------
/cockpit/cockpit-react-involved-users/README.md:
--------------------------------------------------------------------------------
1 | ReactJS "Involved Users" Cockpit Plugin
2 | =======================================
3 |
4 | This example shows you how to build and bundle a plugin using react. When building your plugin using libraries, you have to make sure all your components are bundled into a single bundle. In this example, we use rollup to create the bundle.
5 |
6 |
7 | 
8 |
9 |
10 | Building the Project
11 | --------------------
12 |
13 | Install the project with `npm i` and build the plugin with `npm run build`. Your plugin will be created in `dist/plugin.js`.
14 |
15 | Integrate into Camunda Webapp
16 | -----------------------------
17 |
18 | Copy the `plugin.js` file into the `app/cockpit/scripts/` folder in your Camunda webapp distribution.
19 | For the Tomcat distribution, this would be `server/apache-tomcat-X.X.XX/webapps/camunda/app/cockpit/scripts/`.
20 |
21 | Add the following content to the `app/cockpit/scripts/config.js` file:
22 |
23 | ```
24 | // …
25 | customScripts: [
26 | 'scripts/plugin.js'
27 | ]
28 | // …
29 | ```
30 |
31 | You can add custom CSS by adding it to the `app/cockpit/styles/user-styles.css`
32 |
33 | After that start the server, login to Cockpit and navigate to the process definition view to check the result.
34 |
35 | License
36 | -------
37 |
38 | Use under terms of the [Apache License, Version 2.0](http://www.apache.org/licenses/LICENSE-2.0)
39 |
--------------------------------------------------------------------------------
/cockpit/cockpit-react-involved-users/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "reactjs",
3 | "version": "1.0.0",
4 | "description": "",
5 | "main": "plugin.js",
6 | "scripts": {
7 | "build": "rollup -c"
8 | },
9 | "type": "module",
10 | "author": "",
11 | "license": "ISC",
12 | "dependencies": {
13 | "react": "~19.0.0",
14 | "react-dom": "~19.0.0"
15 | },
16 | "devDependencies": {
17 | "@babel/core": "~7.26.10",
18 | "@babel/plugin-transform-runtime": "~7.26.10",
19 | "@babel/preset-env": "~7.26.9",
20 | "@babel/preset-react": "~7.26.3",
21 | "@rollup/plugin-babel": "~6.0.4",
22 | "@rollup/plugin-commonjs": "~28.0.3",
23 | "@rollup/plugin-node-resolve": "~16.0.1",
24 | "@rollup/plugin-replace": "~6.0.2",
25 | "rollup": "~4.37.0",
26 | "rollup-plugin-scss": "~4.0.1",
27 | "sass": "^1.86.0"
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/cockpit/cockpit-react-involved-users/rollup.config.js:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | import babel from "@rollup/plugin-babel";
19 | import resolve from "@rollup/plugin-node-resolve";
20 | import commonjs from "@rollup/plugin-commonjs";
21 | import replace from "@rollup/plugin-replace";
22 | import scss from "rollup-plugin-scss";
23 |
24 | export default {
25 | input: "src/plugin.js",
26 | output: {
27 | file: "dist/plugin.js"
28 | },
29 | plugins: [
30 | resolve(),
31 | babel({
32 | babelHelpers: "runtime",
33 | skipPreflightCheck: true,
34 | compact: true
35 | }),
36 | commonjs({
37 | include: "node_modules/**"
38 | }),
39 | replace({
40 | "process.env.NODE_ENV": JSON.stringify("production"),
41 | preventAssignment: true
42 | }),
43 | scss({fileName: 'plugin.css'})
44 | ]
45 | };
--------------------------------------------------------------------------------
/cockpit/cockpit-react-involved-users/screenshot.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/cockpit/cockpit-react-involved-users/screenshot.png
--------------------------------------------------------------------------------
/cockpit/cockpit-react-involved-users/src/Table/Table.js:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | import React from "react";
19 |
20 | import "./Table.scss";
21 |
22 | export default function Table({ head, children }) {
23 | return (
24 |
25 |
26 |
{head}
27 |
28 | {children}
29 |
30 | );
31 | }
32 |
33 | Table.Head = function Head({ children }) {
34 | return
{children}
;
35 | };
36 |
37 | Table.Row = function Row({ children }) {
38 | return
{children}
;
39 | };
40 |
41 | Table.Cell = function Cell({ children }) {
42 | return
{children}
;
43 | };
44 |
--------------------------------------------------------------------------------
/cockpit/cockpit-react-involved-users/src/Table/Table.scss:
--------------------------------------------------------------------------------
1 | .Table {
2 | width: 100%;
3 | max-width: 100%;
4 |
5 | .TableRow {
6 | &:nth-of-type(odd) {
7 | background-color: #f9f9f9;
8 | }
9 | &:hover {
10 | background-color: #eaf0f8;
11 | }
12 | }
13 |
14 | .TableHead {
15 | padding: 5px;
16 | border-bottom: 2px solid #ddd;
17 | }
18 |
19 | .TableCell {
20 | padding: 5px;
21 | line-height: 1.5;
22 | vertical-align: top;
23 | border-top: 1px solid #ddd;
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/cockpit/cockpit-react-involved-users/src/Table/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | export { default as Table } from "./Table";
19 |
--------------------------------------------------------------------------------
/cockpit/cockpit-react-involved-users/src/plugin.js:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | import React from "react";
19 | import { createRoot } from 'react-dom/client';
20 |
21 | import UserOperationCount from "./UserOperationCount";
22 |
23 | let container;
24 |
25 | export default {
26 | id: "involvedUsers",
27 | pluginPoint: "cockpit.processDefinition.runtime.tab",
28 | priority: 9,
29 | render: (node, { processDefinitionId, api }) => {
30 | container = createRoot(node);
31 | container.render(
32 |
36 | );
37 | },
38 | unmount: () => {
39 | if (container) {
40 | container.unmount();
41 | }
42 | },
43 | properties: {
44 | label: "Involved Users"
45 | }
46 | };
47 |
--------------------------------------------------------------------------------
/cockpit/cockpit-request-interceptor/README.md:
--------------------------------------------------------------------------------
1 | "Request Interceptor" Cockpit Script
2 | ====================================
3 |
4 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/cockpit/cockpit-request-interceptor).
5 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
6 | might need to adjust them to make them work.
--------------------------------------------------------------------------------
/deployment/ejb-pa-jakarta/README.md:
--------------------------------------------------------------------------------
1 | # Jakarta EJB Process Application Example
2 |
3 | This example demonstrates how to deploy a Jakarta EJB process application.
4 |
5 | ## How to use it
6 |
7 | 1. Build it with Maven.
8 | 2. Deploy it to a `camunda-bpm-platform` distro of your own choice that supports Jakarta EE 9+ EJBs (e.g. WildFly).
9 | 3. Wait a minute.
10 | 4. Watch out for this console log:
11 |
12 | ```bash
13 | This is a @Stateless Ejb component invoked from a BPMN 2.0 process.
14 | ```
15 |
--------------------------------------------------------------------------------
/deployment/ejb-pa-jakarta/src/main/java/org/camunda/bpm/quickstart/ejb/EjbJavaDelegate.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.quickstart.ejb;
18 |
19 | import java.util.logging.Logger;
20 |
21 | import jakarta.ejb.Stateless;
22 | import jakarta.inject.Named;
23 |
24 | import org.camunda.bpm.engine.delegate.DelegateExecution;
25 | import org.camunda.bpm.engine.delegate.JavaDelegate;
26 |
27 | /**
28 | * This is an Ejb which is invoked form a Service task
29 | *
30 | */
31 | @Named("exampleBean")
32 | @Stateless
33 | public class EjbJavaDelegate implements JavaDelegate {
34 |
35 | private final static Logger LOGGER = Logger.getLogger(EjbJavaDelegate.class.getName());
36 |
37 | public void execute(DelegateExecution execution) {
38 |
39 | LOGGER.info("\n\n\n This is a @Stateless Ejb component invoked from a BPMN 2.0 process \n\n\n");
40 |
41 | }
42 |
43 | }
44 |
--------------------------------------------------------------------------------
/deployment/ejb-pa-jakarta/src/main/java/org/camunda/bpm/quickstart/ejb/EjbProcessStarter.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.quickstart.ejb;
18 |
19 | import jakarta.ejb.DependsOn;
20 | import jakarta.ejb.Schedule;
21 | import jakarta.ejb.Singleton;
22 | import jakarta.ejb.Startup;
23 | import jakarta.inject.Inject;
24 |
25 | import org.camunda.bpm.engine.RuntimeService;
26 |
27 | /**
28 | * Ejb which is automatically started when the application is deployed and creates a new process instance
29 | *
30 | */
31 | @Startup
32 | @Singleton
33 | @DependsOn("DefaultEjbProcessApplication")
34 | public class EjbProcessStarter {
35 |
36 | @Inject
37 | private RuntimeService runtimeService;
38 |
39 | @Schedule(hour="*", minute="*")
40 | public void startProcessInstance() {
41 |
42 | runtimeService.startProcessInstanceByKey("testResolveBean");
43 |
44 | }
45 |
46 | }
47 |
--------------------------------------------------------------------------------
/deployment/ejb-pa-jakarta/src/main/resources/META-INF/processes.xml:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/deployment/ejb-pa-jakarta/src/main/resources/META-INF/processes.xml
--------------------------------------------------------------------------------
/deployment/ejb-pa-jakarta/src/main/webapp/WEB-INF/beans.xml:
--------------------------------------------------------------------------------
1 |
5 |
--------------------------------------------------------------------------------
/deployment/ejb-pa/README.md:
--------------------------------------------------------------------------------
1 | # EJB Process Application Example
2 |
3 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.22](https://github.com/camunda/camunda-bpm-examples/tree/7.22/deployment/ejb-pa).
4 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you might need to adjust them to make them work.
5 |
6 | Or have a look at Jakarta EJB process application example: [deployment/ejb-pa-jakarta](/deployment/ejb-pa-jakarta).
--------------------------------------------------------------------------------
/deployment/embedded-spring-rest/src/main/java/org/camunda/bpm/example/loanapproval/CalculateInterestService.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.loanapproval;
18 |
19 | import org.camunda.bpm.engine.delegate.DelegateExecution;
20 | import org.camunda.bpm.engine.delegate.JavaDelegate;
21 |
22 | import java.util.logging.Logger;
23 |
24 | public class CalculateInterestService implements JavaDelegate {
25 |
26 | protected static final Logger LOG = Logger.getLogger(CalculateInterestService.class.getName());
27 |
28 | public void execute(DelegateExecution delegate) {
29 |
30 | LOG.info("Spring Bean invoked.");
31 |
32 | }
33 |
34 | }
35 |
--------------------------------------------------------------------------------
/deployment/embedded-spring-rest/src/main/java/org/camunda/bpm/example/loanapproval/Starter.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.loanapproval;
18 |
19 | import org.camunda.bpm.engine.RuntimeService;
20 | import org.springframework.beans.factory.InitializingBean;
21 | import org.springframework.beans.factory.annotation.Autowired;
22 |
23 | public class Starter implements InitializingBean {
24 |
25 | @Autowired
26 | private RuntimeService runtimeService;
27 |
28 | public void afterPropertiesSet() {
29 | runtimeService.startProcessInstanceByKey("loanApproval");
30 | }
31 |
32 | }
33 |
--------------------------------------------------------------------------------
/deployment/embedded-spring-rest/src/main/java/org/camunda/bpm/example/loanapproval/rest/RestProcessEngineDeployment.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.loanapproval.rest;
18 |
19 | import java.util.HashSet;
20 | import java.util.Set;
21 |
22 | import jakarta.ws.rs.core.Application;
23 |
24 | import org.camunda.bpm.engine.rest.impl.CamundaRestResources;
25 |
26 | public class RestProcessEngineDeployment extends Application {
27 |
28 | @Override
29 | public Set> getClasses() {
30 | Set> classes = new HashSet<>();
31 |
32 | classes.addAll(CamundaRestResources.getResourceClasses());
33 | classes.addAll(CamundaRestResources.getConfigurationClasses());
34 |
35 | return classes;
36 | }
37 |
38 | }
--------------------------------------------------------------------------------
/deployment/embedded-spring-rest/src/main/java/org/camunda/bpm/example/loanapproval/rest/RestProcessEngineProvider.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.loanapproval.rest;
18 |
19 | import java.util.Set;
20 |
21 | import org.camunda.bpm.engine.ProcessEngine;
22 | import org.camunda.bpm.engine.ProcessEngines;
23 | import org.camunda.bpm.engine.rest.spi.ProcessEngineProvider;
24 |
25 | public class RestProcessEngineProvider implements ProcessEngineProvider {
26 |
27 | public ProcessEngine getDefaultProcessEngine() {
28 | return ProcessEngines.getDefaultProcessEngine();
29 | }
30 |
31 | public ProcessEngine getProcessEngine(String name) {
32 | return ProcessEngines.getProcessEngine(name);
33 | }
34 |
35 | public Set getProcessEngineNames() {
36 | return ProcessEngines.getProcessEngines().keySet();
37 | }
38 |
39 | }
40 |
--------------------------------------------------------------------------------
/deployment/embedded-spring-rest/src/main/resources/META-INF/services/org.camunda.bpm.engine.rest.spi.ProcessEngineProvider:
--------------------------------------------------------------------------------
1 | org.camunda.bpm.example.loanapproval.rest.RestProcessEngineProvider
--------------------------------------------------------------------------------
/deployment/servlet-pa/README.md:
--------------------------------------------------------------------------------
1 | # Simple Jakarta Servlet Process Application Example
2 |
3 | This example demonstrates how to deploy a simple servlet process application.
4 |
5 | ## How to use it
6 |
7 | 1. Build it with Maven.
8 | 2. Deploy it to a `camunda-bpm-platform` distro of your choice (Tomcat 10/WildFly 35+).
9 | 3. Watch out for this console log:
10 |
11 | ```bash
12 | Service Task Example ServiceTask is invoked!
13 | ```
14 |
15 | ## Java EE API
16 |
17 | If you would like to deploy this on a Java EE server like Tomcat 9, you can refer to the [example with fixed version of Camunda 7.22][1].
18 |
19 | [1]: [https://github.com/camunda/camunda-bpm-examples/tree/7.22/deployment/servlet-pa]
20 |
21 |
--------------------------------------------------------------------------------
/deployment/servlet-pa/src/main/resources/META-INF/processes.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 | default
9 |
10 | false
11 | true
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/deployment/spring-boot/README.md:
--------------------------------------------------------------------------------
1 | # Camunda Process Engine and Spring Boot
2 |
3 |
4 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/deployment/spring-boot).
5 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
6 | might need to adjust them to make them work.
7 |
8 | Or have a look at Camunda's implementation of the Spring Boot Starter: [spring-boot-starter/example-simple](/spring-boot-starter/example-simple).
--------------------------------------------------------------------------------
/deployment/spring-servlet-pa-tomcat/src/main/java/org/camunda/bpm/example/spring/servlet/pa/ExampleDelegateBean.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.spring.servlet.pa;
18 |
19 | import org.camunda.bpm.engine.delegate.DelegateExecution;
20 | import org.camunda.bpm.engine.delegate.JavaDelegate;
21 |
22 | import java.util.logging.Level;
23 | import java.util.logging.Logger;
24 |
25 | public class ExampleDelegateBean implements JavaDelegate {
26 |
27 | public static final Logger LOG = Logger.getLogger(ExampleDelegateBean.class.getName());
28 |
29 | public void execute(DelegateExecution delegateExecution) {
30 | LOG.log(Level.INFO, "{0} is currently invoked.", getClass().getName());
31 | }
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/deployment/spring-servlet-pa-tomcat/src/main/resources/META-INF/processes.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
8 |
9 | true
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/deployment/spring-servlet-pa-tomcat/src/main/webapp/WEB-INF/web.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 | contextConfigLocation
7 | /WEB-INF/applicationContext.xml
8 |
9 |
10 |
11 | org.springframework.web.context.ContextLoaderListener
12 |
13 |
14 |
--------------------------------------------------------------------------------
/deployment/spring-servlet-pa-wildfly/.gitignore:
--------------------------------------------------------------------------------
1 | camunda-h2-dbs
--------------------------------------------------------------------------------
/deployment/spring-servlet-pa-wildfly/src/main/java/org/camunda/bpm/example/spring/servlet/pa/ExampleDelegateBean.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.spring.servlet.pa;
18 |
19 | import org.camunda.bpm.engine.delegate.DelegateExecution;
20 | import org.camunda.bpm.engine.delegate.JavaDelegate;
21 |
22 | import java.util.logging.Level;
23 | import java.util.logging.Logger;
24 |
25 | public class ExampleDelegateBean implements JavaDelegate {
26 |
27 | public static final Logger LOG = Logger.getLogger(ExampleDelegateBean.class.getName());
28 |
29 | public void execute(DelegateExecution delegateExecution) {
30 | LOG.log(Level.INFO, "{0} is currently invoked.", getClass().getName());
31 | }
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/deployment/spring-servlet-pa-wildfly/src/main/resources/META-INF/processes.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
8 |
9 | true
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/deployment/spring-servlet-pa-wildfly/src/main/webapp/WEB-INF/applicationContext.xml:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/deployment/spring-servlet-pa-wildfly/src/main/webapp/WEB-INF/web.xml:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 | contextConfigLocation
8 | /WEB-INF/applicationContext.xml
9 |
10 |
11 |
12 | org.springframework.web.context.ContextLoaderListener
13 |
14 |
15 |
--------------------------------------------------------------------------------
/deployment/spring-servlet-pa-wildfly/src/test/resources/arquillian.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
7 |
8 | target/deployments
9 |
10 |
11 |
12 |
13 | target/wildfly/server/wildfly-${version.wildfly}
14 | -Xmx1024m
15 | 300
16 |
17 |
18 |
19 |
--------------------------------------------------------------------------------
/deployment/spring-wildfly-non-pa/src/main/webapp/WEB-INF/applicationContext.xml:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
--------------------------------------------------------------------------------
/deployment/spring-wildfly-non-pa/src/main/webapp/WEB-INF/web.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 | contextConfigLocation
7 | /WEB-INF/applicationContext.xml
8 |
9 |
10 |
11 | org.springframework.web.context.ContextLoaderListener
12 |
13 |
14 |
15 | processEngine/default
16 | org.camunda.bpm.engine.ProcessEngine
17 | java:global/camunda-bpm-platform/process-engine/default
18 |
19 |
20 |
--------------------------------------------------------------------------------
/dmn-engine/dmn-engine-drg/src/main/resources/org/camunda/bpm/example/drg/beverages.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/dmn-engine/dmn-engine-drg/src/main/resources/org/camunda/bpm/example/drg/beverages.png
--------------------------------------------------------------------------------
/dmn-engine/dmn-engine-drg/src/main/resources/org/camunda/bpm/example/drg/dinnerDecisions.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/dmn-engine/dmn-engine-drg/src/main/resources/org/camunda/bpm/example/drg/dinnerDecisions.png
--------------------------------------------------------------------------------
/dmn-engine/dmn-engine-drg/src/main/resources/org/camunda/bpm/example/drg/dish.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/dmn-engine/dmn-engine-drg/src/main/resources/org/camunda/bpm/example/drg/dish.png
--------------------------------------------------------------------------------
/dmn-engine/dmn-engine-java-main-method/src/main/resources/org/camunda/bpm/example/dish-decision.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/dmn-engine/dmn-engine-java-main-method/src/main/resources/org/camunda/bpm/example/dish-decision.png
--------------------------------------------------------------------------------
/migration/migrate-on-deployment/src/main/resources/META-INF/processes.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 | default
9 |
10 | false
11 | true
12 |
13 |
14 |
--------------------------------------------------------------------------------
/multi-tenancy/schema-isolation/src/main/java/org/camunda/bpm/tutorial/multitenancy/MultiTenancyJaxRsApplication.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.tutorial.multitenancy;
18 |
19 | import jakarta.ws.rs.ApplicationPath;
20 | import jakarta.ws.rs.core.Application;
21 |
22 | /**
23 | * @author Thorben Lindhauer
24 | *
25 | */
26 | @ApplicationPath("/")
27 | public class MultiTenancyJaxRsApplication extends Application {
28 |
29 | }
30 |
--------------------------------------------------------------------------------
/multi-tenancy/schema-isolation/src/main/java/org/camunda/bpm/tutorial/multitenancy/SimpleServiceTask.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.tutorial.multitenancy;
18 |
19 | import jakarta.inject.Inject;
20 | import jakarta.inject.Named;
21 |
22 | import org.camunda.bpm.engine.RuntimeService;
23 | import org.camunda.bpm.engine.delegate.DelegateExecution;
24 | import org.camunda.bpm.engine.delegate.JavaDelegate;
25 |
26 | @Named
27 | public class SimpleServiceTask implements JavaDelegate {
28 |
29 | @Inject
30 | private RuntimeService runtimeService;
31 |
32 | @Override
33 | public void execute(DelegateExecution execution) throws Exception {
34 | // do the stuff
35 |
36 | runtimeService.setVariable(execution.getId(), "invoked", true);
37 | }
38 |
39 | }
40 |
--------------------------------------------------------------------------------
/multi-tenancy/schema-isolation/src/main/java/org/camunda/bpm/tutorial/multitenancy/Tenant.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.tutorial.multitenancy;
18 |
19 | import jakarta.enterprise.context.RequestScoped;
20 |
21 | /**
22 | * @author Thorben Lindhauer
23 | *
24 | */
25 | @RequestScoped
26 | public class Tenant {
27 |
28 | protected String id;
29 |
30 | public String getId() {
31 | return id;
32 | }
33 |
34 | public void setId(String id) {
35 | this.id = id;
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/multi-tenancy/schema-isolation/src/main/resources/META-INF/processes.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 | tenant1
7 |
8 | classpath:processes/tenant1/
9 |
10 | false
11 | true
12 |
13 |
14 |
15 |
16 | tenant2
17 |
18 | classpath:processes/tenant2/
19 |
20 | false
21 | true
22 |
23 |
24 |
25 |
--------------------------------------------------------------------------------
/multi-tenancy/schema-isolation/src/main/resources/processes/tenant1/tenant1_process.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/multi-tenancy/schema-isolation/src/main/resources/processes/tenant1/tenant1_process.png
--------------------------------------------------------------------------------
/multi-tenancy/schema-isolation/src/main/resources/processes/tenant2/tenant2_process.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/multi-tenancy/schema-isolation/src/main/resources/processes/tenant2/tenant2_process.png
--------------------------------------------------------------------------------
/multi-tenancy/schema-isolation/src/main/webapp/WEB-INF/beans.xml:
--------------------------------------------------------------------------------
1 |
5 |
6 |
--------------------------------------------------------------------------------
/multi-tenancy/schema-isolation/src/main/webapp/WEB-INF/jboss-web.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 | /multi-tenancy-tutorial
7 |
8 |
--------------------------------------------------------------------------------
/multi-tenancy/schema-isolation/src/main/webapp/WEB-INF/web.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
--------------------------------------------------------------------------------
/multi-tenancy/schema-isolation/src/test/resources/META-INF/processes.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
7 | tenant1
8 |
9 | classpath:processes/tenant1/
10 |
11 | true
12 | true
13 |
14 |
15 |
16 |
17 | tenant2
18 |
19 | classpath:processes/tenant2/
20 |
21 | true
22 | true
23 |
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/multi-tenancy/schema-isolation/src/test/resources/arquillian.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
8 |
9 |
10 |
11 |
12 | target/deploymentExport
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 | -Xmx1024m
21 | 300
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
--------------------------------------------------------------------------------
/multi-tenancy/schema-isolation/src/test/resources/logging.properties:
--------------------------------------------------------------------------------
1 | #register SLF4JBridgeHandler as handler for the j.u.l. root logger
2 | handlers = org.slf4j.bridge.SLF4JBridgeHandler
3 |
--------------------------------------------------------------------------------
/multi-tenancy/tenant-identifier-embedded/docs/process.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/multi-tenancy/tenant-identifier-embedded/docs/process.png
--------------------------------------------------------------------------------
/multi-tenancy/tenant-identifier-embedded/src/main/java/org/camunda/bpm/tutorial/multitenancy/Service.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.tutorial.multitenancy;
18 |
19 | /**
20 | * Sample service which can be invoked with a tenant-id.
21 | */
22 | public interface Service {
23 |
24 | void invoke(String tenantId);
25 |
26 | }
27 |
--------------------------------------------------------------------------------
/multi-tenancy/tenant-identifier-embedded/src/test/resources/camunda.cfg.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/multi-tenancy/tenant-identifier-shared-definitions/docs/defaultSubProcess.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/multi-tenancy/tenant-identifier-shared-definitions/docs/defaultSubProcess.png
--------------------------------------------------------------------------------
/multi-tenancy/tenant-identifier-shared-definitions/docs/mainProcess.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/multi-tenancy/tenant-identifier-shared-definitions/docs/mainProcess.png
--------------------------------------------------------------------------------
/multi-tenancy/tenant-identifier-shared-definitions/docs/tenantSpecificSubProcess.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/multi-tenancy/tenant-identifier-shared-definitions/docs/tenantSpecificSubProcess.png
--------------------------------------------------------------------------------
/multi-tenancy/tenant-identifier-shared-definitions/src/test/resources/camunda.cfg.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/multi-tenancy/tenant-identifier-shared/docs/process.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/multi-tenancy/tenant-identifier-shared/docs/process.png
--------------------------------------------------------------------------------
/multi-tenancy/tenant-identifier-shared/src/main/java/org/camunda/bpm/tutorial/multitenancy/TenantAwareServiceTask.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.tutorial.multitenancy;
18 |
19 | import java.util.logging.Logger;
20 |
21 | import org.camunda.bpm.engine.delegate.DelegateExecution;
22 | import org.camunda.bpm.engine.delegate.JavaDelegate;
23 |
24 | /**
25 | * Sample service task which logs the tenant-id of the execution.
26 | */
27 | public class TenantAwareServiceTask implements JavaDelegate {
28 |
29 | public final static Logger LOGGER = Logger.getLogger(TenantAwareServiceTask.class.getName());
30 |
31 | @Override
32 | public void execute(DelegateExecution execution) throws Exception {
33 |
34 | String tenantId = execution.getTenantId();
35 |
36 | LOGGER.info("invoked for tenant with id: " + tenantId);
37 | }
38 |
39 | }
40 |
--------------------------------------------------------------------------------
/multi-tenancy/tenant-identifier-shared/src/main/resources/META-INF/processes.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 | default
7 |
8 | classpath:processes/tenant1/
9 |
10 | false
11 | true
12 |
13 |
14 |
15 |
16 | default
17 |
18 | classpath:processes/tenant2/
19 |
20 | false
21 | true
22 |
23 |
24 |
25 |
--------------------------------------------------------------------------------
/process-engine-plugin/bpmn-parse-listener-on-user-task/README.md:
--------------------------------------------------------------------------------
1 | # BPMN Parse Listener - adding task listener on user task
2 |
3 | This example has been moved to [process-engine-plugin/bpmn-parse-listener](/process-engine-plugin/bpmn-parse-listener/README.md#task-listener).
4 |
--------------------------------------------------------------------------------
/process-engine-plugin/bpmn-parse-listener/docs/bpmnParseListener.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/process-engine-plugin/bpmn-parse-listener/docs/bpmnParseListener.png
--------------------------------------------------------------------------------
/process-engine-plugin/bpmn-parse-listener/docs/bpmnParseListenerOnUserTask.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/process-engine-plugin/bpmn-parse-listener/docs/bpmnParseListenerOnUserTask.png
--------------------------------------------------------------------------------
/process-engine-plugin/bpmn-parse-listener/docs/service-camunda-modeler.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/process-engine-plugin/bpmn-parse-listener/docs/service-camunda-modeler.png
--------------------------------------------------------------------------------
/process-engine-plugin/bpmn-parse-listener/src/main/java/org/camunda/bpm/example/delegate/ServiceTaskOneDelegate.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.delegate;
18 |
19 | import org.camunda.bpm.engine.delegate.DelegateExecution;
20 | import org.camunda.bpm.engine.delegate.JavaDelegate;
21 |
22 | public class ServiceTaskOneDelegate implements JavaDelegate {
23 |
24 | public static boolean wasExecuted = false;
25 |
26 | public void execute(DelegateExecution execution) throws Exception {
27 | wasExecuted = true;
28 | }
29 |
30 | }
31 |
--------------------------------------------------------------------------------
/process-engine-plugin/bpmn-parse-listener/src/main/java/org/camunda/bpm/example/delegate/ServiceTaskTwoDelegate.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.delegate;
18 |
19 | import org.camunda.bpm.engine.delegate.DelegateExecution;
20 | import org.camunda.bpm.engine.delegate.JavaDelegate;
21 |
22 | public class ServiceTaskTwoDelegate implements JavaDelegate {
23 |
24 | public static boolean wasExecuted = false;
25 |
26 | public void execute(DelegateExecution execution) throws Exception {
27 | wasExecuted = true;
28 | }
29 |
30 | }
31 |
--------------------------------------------------------------------------------
/process-engine-plugin/bpmn-parse-listener/src/main/resources/bpmnParseListener.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/process-engine-plugin/bpmn-parse-listener/src/main/resources/bpmnParseListener.png
--------------------------------------------------------------------------------
/process-engine-plugin/bpmn-parse-listener/src/test/resources/camunda.cfg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/process-engine-plugin/command-interceptor-blocking/src/main/java/org/camunda/bpm/example/engine/BlockedCommandException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.engine;
18 |
19 | import org.camunda.bpm.engine.ProcessEngineException;
20 |
21 | /**
22 | * @author Daniel Meyer
23 | *
24 | */
25 | public class BlockedCommandException extends ProcessEngineException {
26 |
27 | private static final long serialVersionUID = 1L;
28 |
29 | public BlockedCommandException() {
30 | super();
31 | }
32 |
33 | public BlockedCommandException(String message, Throwable cause) {
34 | super(message, cause);
35 | }
36 |
37 | public BlockedCommandException(String message) {
38 | super(message);
39 | }
40 |
41 | public BlockedCommandException(Throwable cause) {
42 | super(cause);
43 | }
44 |
45 | }
46 |
--------------------------------------------------------------------------------
/process-engine-plugin/command-interceptor-blocking/src/main/java/org/camunda/bpm/example/engine/cmd/EndBlockingCmd.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.engine.cmd;
18 |
19 | import org.camunda.bpm.engine.impl.interceptor.Command;
20 | import org.camunda.bpm.engine.impl.interceptor.CommandContext;
21 |
22 | /**
23 | * If this command is executed, the interceptor ends blocking.
24 | *
25 | * @author Daniel Meyer
26 | *
27 | */
28 | public class EndBlockingCmd implements Command {
29 |
30 | public Void execute(CommandContext commandContext) {
31 | return null;
32 | }
33 |
34 | }
35 |
--------------------------------------------------------------------------------
/process-engine-plugin/command-interceptor-blocking/src/main/java/org/camunda/bpm/example/engine/cmd/StartBlockingCmd.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.engine.cmd;
18 |
19 | import org.camunda.bpm.engine.impl.interceptor.Command;
20 | import org.camunda.bpm.engine.impl.interceptor.CommandContext;
21 |
22 | /**
23 | * If this command is executed, the interceptor starts blocking.
24 | *
25 | * @author Daniel Meyer
26 | *
27 | */
28 | public class StartBlockingCmd implements Command {
29 |
30 | public Void execute(CommandContext commandContext) {
31 | return null;
32 | }
33 |
34 | }
35 |
--------------------------------------------------------------------------------
/process-engine-plugin/command-interceptor-blocking/src/main/java/org/camunda/bpm/example/engine/cmd/UnblockedCommand.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.engine.cmd;
18 |
19 | import org.camunda.bpm.engine.impl.interceptor.Command;
20 |
21 | /**
22 | * Commands implementing this interface can always be executed even if the engine is in blocking mode.
23 | *
24 | * @author Daniel Meyer
25 | *
26 | */
27 | public interface UnblockedCommand extends Command {
28 |
29 | }
30 |
--------------------------------------------------------------------------------
/process-engine-plugin/custom-history-level/src/main/java/org/camunda/bpm/example/CreateVariablesDelegate.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example;
18 |
19 | import org.camunda.bpm.engine.delegate.DelegateExecution;
20 | import org.camunda.bpm.engine.delegate.JavaDelegate;
21 |
22 | public class CreateVariablesDelegate implements JavaDelegate {
23 |
24 | public void execute(DelegateExecution execution) throws Exception {
25 | execution.setVariable("foo", "bar");
26 | execution.setVariable("hello", "world");
27 | execution.setVariable("action-id-hist", "important");
28 | execution.setVariable("camunda-hist", "rocks");
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/process-engine-plugin/custom-history-level/src/main/resources/process.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/process-engine-plugin/custom-history-level/src/main/resources/process.png
--------------------------------------------------------------------------------
/process-engine-plugin/custom-history-level/src/main/resources/properties.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/process-engine-plugin/custom-history-level/src/main/resources/properties.png
--------------------------------------------------------------------------------
/process-engine-plugin/custom-history-level/src/test/resources/camunda-custom-variable.cfg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/process-engine-plugin/custom-history-level/src/test/resources/camunda-per-process.cfg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/process-engine-plugin/failed-job-retry-profile/docs/extension-property.JPG:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/process-engine-plugin/failed-job-retry-profile/docs/extension-property.JPG
--------------------------------------------------------------------------------
/process-engine-plugin/failed-job-retry-profile/docs/retry-example.JPG:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/process-engine-plugin/failed-job-retry-profile/docs/retry-example.JPG
--------------------------------------------------------------------------------
/process-engine-plugin/failed-job-retry-profile/src/main/java/org/camunda/bpm/example/delegate/ServiceTaskOneDelegate.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.delegate;
18 |
19 | import org.camunda.bpm.engine.delegate.BpmnError;
20 | import org.camunda.bpm.engine.delegate.DelegateExecution;
21 | import org.camunda.bpm.engine.delegate.JavaDelegate;
22 |
23 | public class ServiceTaskOneDelegate implements JavaDelegate {
24 |
25 | public static boolean firstAttempt = true;
26 |
27 | public void execute(DelegateExecution execution) {
28 | if (firstAttempt) {
29 | throw new BpmnError("Error-001", "It is supposed to fail.");
30 | }
31 | }
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/process-engine-plugin/failed-job-retry-profile/src/main/java/org/camunda/bpm/example/delegate/ServiceTaskTwoDelegate.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.delegate;
18 |
19 | import org.camunda.bpm.engine.delegate.BpmnError;
20 | import org.camunda.bpm.engine.delegate.DelegateExecution;
21 | import org.camunda.bpm.engine.delegate.JavaDelegate;
22 |
23 | public class ServiceTaskTwoDelegate implements JavaDelegate {
24 |
25 | public static boolean firstAttempt = true;
26 |
27 | public void execute(DelegateExecution execution) {
28 | if (firstAttempt) {
29 | throw new BpmnError("It is supposed to fail.");
30 | }
31 | }
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/process-engine-plugin/failed-job-retry-profile/src/test/resources/camunda.cfg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
7 |
8 |
10 |
11 |
12 |
13 |
14 |
15 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/process-engine-plugin/handling-jpa-variables/src/main/java/org/camunda/bpm/example/jpa/entities/Customer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.jpa.entities;
18 |
19 | import javax.persistence.Column;
20 | import javax.persistence.Entity;
21 | import javax.persistence.Id;
22 |
23 | @Entity
24 | public class Customer {
25 |
26 | @Id
27 | @Column(name = "ID_")
28 | private Long id;
29 | private String firstName;
30 |
31 | protected Customer() {}
32 |
33 | public Customer(Long id, String firstName) {
34 | this.id = id;
35 | this.firstName = firstName;
36 | }
37 |
38 | @Override
39 | public String toString() {
40 | return String.format(
41 | "Customer[id=%d, firstName='%s']",
42 | id, firstName);
43 | }
44 |
45 | public Long getId() {
46 | return id;
47 | }
48 |
49 | public String getFirstName() {
50 | return firstName;
51 | }
52 |
53 | }
54 |
--------------------------------------------------------------------------------
/process-engine-plugin/handling-jpa-variables/src/main/java/org/camunda/bpm/example/jpa/variables/serializer/EntityManagerSession.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.jpa.variables.serializer;
18 |
19 | import javax.persistence.EntityManager;
20 | import javax.persistence.EntityManagerFactory;
21 | import org.camunda.bpm.engine.ProcessEngineException;
22 | import org.camunda.bpm.engine.impl.interceptor.Session;
23 |
24 | /**
25 | * @author Frederik Heremans
26 | */
27 | public interface EntityManagerSession extends Session {
28 | /**
29 | * Get an {@link EntityManager} instance associated with this session.
30 | * @throws ProcessEngineException when no {@link EntityManagerFactory} instance
31 | * is configured for the process engine.
32 | */
33 | EntityManager getEntityManager();
34 | }
--------------------------------------------------------------------------------
/process-engine-plugin/handling-jpa-variables/src/test/resources/META-INF/persistence.xml:
--------------------------------------------------------------------------------
1 |
6 |
7 | org.apache.openjpa.persistence.PersistenceProviderImpl
8 |
9 | org.camunda.bpm.example.jpa.entities.Customer
10 |
11 | true
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/process-engine-plugin/handling-jpa-variables/src/test/resources/camunda.cfg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
7 |
8 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/quarkus-extension/datasource-example/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | quarkus.camunda.datasource=custom-datasource
2 |
3 | quarkus.datasource.custom-datasource.username=sa
4 | quarkus.datasource.custom-datasource.password=sa
5 |
6 | # H2
7 | quarkus.datasource.custom-datasource.db-kind=h2
8 | quarkus.datasource.custom-datasource.jdbc.url=jdbc:h2:mem:secondary;TRACE_LEVEL_FILE=0;DB_CLOSE_ON_EXIT=FALSE
9 |
10 | # Additional datasource configurations
11 | # PostgreSQL
12 | #quarkus.datasource.custom-datasource.db-kind=postgresql
13 | #quarkus.datasource.custom-datasource.jdbc.url=jdbc:postgresql://localhost:5432/process-engine
14 | # CockroachDB
15 | #quarkus.datasource.custom-datasource.db-kind=postgresql
16 | #quarkus.datasource.custom-datasource.jdbc.url=jdbc:postgresql://localhost:26257/process-engine
17 | # MySQL
18 | #quarkus.datasource.custom-datasource.db-kind=mysql
19 | #quarkus.datasource.custom-datasource.jdbc.url=jdbc:mysql://localhost:3306/process-engine
20 | # MariaDB
21 | #quarkus.datasource.custom-datasource.db-kind=mariadb
22 | #quarkus.datasource.custom-datasource.jdbc.url=jdbc:mariadb://localhost:3306/process-engine
23 | # Oracle
24 | #quarkus.datasource.custom-datasource.db-kind=oracle
25 | #quarkus.datasource.custom-datasource.jdbc.url=jdbc:oracle:thin:@localhost:1521:orcl
26 | # DB2
27 | #quarkus.datasource.custom-datasource.db-kind=db2
28 | #quarkus.datasource.custom-datasource.jdbc.url=jdbc:db2://localhost:50000/engine
29 | # SQL Server & Azure SQL DB
30 | #quarkus.datasource.custom-datasource.db-kind=mssql
31 | #quarkus.datasource.custom-datasource.jdbc.url=jdbc:sqlserver://localhost:1433;databaseName=processEngine
32 |
--------------------------------------------------------------------------------
/quarkus-extension/simple-rest-example/README.md:
--------------------------------------------------------------------------------
1 | # Camunda Platform Runtime Quarkus Example
2 |
3 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/quarkus-extension/simple-rest-example).
4 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
5 | might need to adjust them to make them work.
--------------------------------------------------------------------------------
/quarkus-extension/spin-plugin-example/src/main/java/org/camunda/bpm/quarkus/example/EngineConfiguration.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.quarkus.example;
18 |
19 | import org.camunda.bpm.engine.impl.cfg.ProcessEnginePlugin;
20 | import org.camunda.bpm.quarkus.engine.extension.QuarkusProcessEngineConfiguration;
21 | import org.camunda.spin.plugin.impl.SpinProcessEnginePlugin;
22 |
23 | import jakarta.enterprise.context.ApplicationScoped;
24 | import java.util.ArrayList;
25 | import java.util.List;
26 |
27 | @ApplicationScoped
28 | public class EngineConfiguration extends QuarkusProcessEngineConfiguration {
29 |
30 | public EngineConfiguration() {
31 | List plugins = new ArrayList<>();
32 | plugins.add(new SpinProcessEnginePlugin());
33 | setProcessEnginePlugins(plugins);
34 | }
35 |
36 | }
37 |
--------------------------------------------------------------------------------
/quarkus-extension/spin-plugin-example/src/main/java/org/camunda/bpm/quarkus/example/dto/OrderItem.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.quarkus.example.dto;
18 |
19 | public class OrderItem {
20 |
21 | protected String name;
22 | protected double price;
23 |
24 | public String getName() {
25 | return name;
26 | }
27 |
28 | public void setName(String name) {
29 | this.name = name;
30 | }
31 |
32 | public double getPrice() {
33 | return price;
34 | }
35 |
36 | public void setPrice(double price) {
37 | this.price = price;
38 | }
39 |
40 | }
41 |
--------------------------------------------------------------------------------
/quarkus-extension/spin-plugin-example/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | # Add configuration here
2 | quarkus.datasource.jdbc.url=jdbc:h2:mem:camunda;TRACE_LEVEL_FILE=0;DB_CLOSE_ON_EXIT=FALSE
--------------------------------------------------------------------------------
/scripttask/xquery-scripttask/README.md:
--------------------------------------------------------------------------------
1 | # Script Task which uses XQuery
2 |
3 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/scripttask/xquery-scripttask).
4 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
5 | might need to adjust them to make them work.
--------------------------------------------------------------------------------
/scripttask/xslt-scripttask/src/main/resources/org/camunda/bpm/example/xsltexample/example.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Fozzie
5 | Bear
6 | 05.09.1976
7 |
8 |
9 | Kermit
10 | Frog
11 | in 1955
12 |
13 |
--------------------------------------------------------------------------------
/scripttask/xslt-scripttask/src/main/resources/org/camunda/bpm/example/xsltexample/example.xsl:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
--------------------------------------------------------------------------------
/scripttask/xslt-scripttask/src/main/resources/org/camunda/bpm/example/xsltexample/printResult.groovy:
--------------------------------------------------------------------------------
1 | package org.camunda.bpm.example.xsltexample
2 |
3 | println '\nTransformed XML:'
4 | println execution.getVariable('xmlOutput')
5 |
--------------------------------------------------------------------------------
/scripttask/xslt-scripttask/src/main/resources/org/camunda/bpm/example/xsltexample/readXmlFile.groovy:
--------------------------------------------------------------------------------
1 | package org.camunda.bpm.example.xsltexample
2 |
3 | import org.camunda.commons.utils.IoUtil
4 |
5 | xmlData = IoUtil.fileAsString('org/camunda/bpm/example/xsltexample/example.xml')
6 | execution.setVariable('customers', xmlData)
7 |
8 | println 'Input XML:'
9 | println xmlData
10 |
--------------------------------------------------------------------------------
/scripttask/xslt-scripttask/src/main/resources/xslt-example.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/scripttask/xslt-scripttask/src/main/resources/xslt-example.png
--------------------------------------------------------------------------------
/scripttask/xslt-scripttask/src/test/resources/camunda.cfg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/scripttask/xslt-scripttask/src/test/resources/expected_result.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Fozzie
5 | Bear
6 | 05.09.1976
7 |
8 |
9 | Kermit
10 | Frog
11 | in 1955
12 |
13 |
14 |
--------------------------------------------------------------------------------
/sdk-js/browser-forms/README.md:
--------------------------------------------------------------------------------
1 | # Standalone usage of JS SDK
2 |
3 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/sdk-js/browser-forms).
4 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
5 | might need to adjust them to make them work.
--------------------------------------------------------------------------------
/servicetask/rest-service/src/main/resources/invokeRestService.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/servicetask/rest-service/src/main/resources/invokeRestService.png
--------------------------------------------------------------------------------
/servicetask/rest-service/src/main/resources/parseHoliday.js:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | // fetch execution variables
19 | const response = connector.getVariable("response");
20 | const date = connector.getVariable("date");
21 |
22 | // parse response variable with camunda-spin
23 | const holidays = S(response);
24 |
25 | const query = `$..[?(@.datum=='${date}')]`;
26 |
27 | // use camunda-spin jsonPath to test if date is a holiday
28 | !holidays.jsonPath(query).elementList().isEmpty();
29 |
--------------------------------------------------------------------------------
/servicetask/rest-service/src/test/resources/camunda.cfg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
--------------------------------------------------------------------------------
/servicetask/service-invocation-asynchronous/docs/asynchronous-service-invocation-sequence.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/servicetask/service-invocation-asynchronous/docs/asynchronous-service-invocation-sequence.png
--------------------------------------------------------------------------------
/servicetask/service-invocation-asynchronous/docs/process-model.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/servicetask/service-invocation-asynchronous/docs/process-model.png
--------------------------------------------------------------------------------
/servicetask/service-invocation-asynchronous/docs/service-camunda-modeler.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/servicetask/service-invocation-asynchronous/docs/service-camunda-modeler.png
--------------------------------------------------------------------------------
/servicetask/service-invocation-asynchronous/src/main/resources/asynchronousServiceInvocation.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/servicetask/service-invocation-asynchronous/src/main/resources/asynchronousServiceInvocation.png
--------------------------------------------------------------------------------
/servicetask/service-invocation-asynchronous/src/test/resources/camunda.cfg.xml:
--------------------------------------------------------------------------------
1 |
5 |
6 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/servicetask/service-invocation-synchronous/docs/process-model.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/servicetask/service-invocation-synchronous/docs/process-model.png
--------------------------------------------------------------------------------
/servicetask/service-invocation-synchronous/docs/service-camunda-modeler.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/servicetask/service-invocation-synchronous/docs/service-camunda-modeler.png
--------------------------------------------------------------------------------
/servicetask/service-invocation-synchronous/docs/synchronous-service-invocation-sequence.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/servicetask/service-invocation-synchronous/docs/synchronous-service-invocation-sequence.png
--------------------------------------------------------------------------------
/servicetask/service-invocation-synchronous/src/main/resources/synchronousServiceInvocation.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/servicetask/service-invocation-synchronous/src/main/resources/synchronousServiceInvocation.png
--------------------------------------------------------------------------------
/servicetask/service-invocation-synchronous/src/test/resources/camunda.cfg.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/servicetask/soap-cxf-service/README.md:
--------------------------------------------------------------------------------
1 | SOAP CXF example
2 | ===============================================================
3 |
4 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/servicetask/soap-cxf-service).
5 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
6 | might need to adjust them to make them work.
--------------------------------------------------------------------------------
/servicetask/soap-service/README.md:
--------------------------------------------------------------------------------
1 | # SOAP Service Task
2 |
3 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/servicetask/soap-service).
4 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
5 | might need to adjust them to make them work.
--------------------------------------------------------------------------------
/spin/dataformat-configuration-global/src/main/java/org/camunda/bpm/example/spin/dataformat/configuration/Car.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.spin.dataformat.configuration;
18 |
19 | /**
20 | * We want objects of this class to serialize like
21 | *
22 | * {"price" : 1000}
23 | *
24 | * However, default Jackson serialization makes
25 | *
26 | * {"price" : {"amount" : 1000}}
27 | *
28 | * out of it.
29 | * That's why we register a Jackson module to change the (de-)serialization of {@link Money} objects.
30 | *
31 | * @author Thorben Lindhauer
32 | */
33 | public class Car {
34 |
35 | protected Money price;
36 |
37 | public Money getPrice() {
38 | return price;
39 | }
40 |
41 | public void setPrice(Money price) {
42 | this.price = price;
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/spin/dataformat-configuration-global/src/main/java/org/camunda/bpm/example/spin/dataformat/configuration/Money.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.spin.dataformat.configuration;
18 |
19 | /**
20 | * @author Thorben Lindhauer
21 | *
22 | */
23 | public class Money {
24 |
25 | protected int amount;
26 |
27 | public Money(int amount) {
28 | this.amount = amount;
29 | }
30 |
31 | public int getAmount() {
32 | return amount;
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/spin/dataformat-configuration-global/src/main/resources/META-INF/services/org.camunda.spin.spi.DataFormatConfigurator:
--------------------------------------------------------------------------------
1 | org.camunda.bpm.example.spin.dataformat.configuration.JacksonDataFormatConfigurator
--------------------------------------------------------------------------------
/spin/dataformat-configuration-global/src/main/resources/testProcess.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/spin/dataformat-configuration-global/src/main/resources/testProcess.png
--------------------------------------------------------------------------------
/spin/dataformat-configuration-global/src/test/resources/camunda.cfg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
--------------------------------------------------------------------------------
/spin/dataformat-configuration-in-process-application/src/main/java/org/camunda/bpm/example/spin/dataformat/configuration/Car.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.spin.dataformat.configuration;
18 |
19 | /**
20 | * We want objects of this class to serialize like
21 | *
22 | * {"price" : 1000}
23 | *
24 | * However, default Jackson serialization makes
25 | *
26 | * {"price" : {"amount" : 1000}}
27 | *
28 | * out of it.
29 | * That's why we register a Jackson module to change the (de-)serialization of {@link Money} objects.
30 | *
31 | * @author Thorben Lindhauer
32 | */
33 | public class Car {
34 |
35 | protected Money price;
36 |
37 | public Money getPrice() {
38 | return price;
39 | }
40 |
41 | public void setPrice(Money price) {
42 | this.price = price;
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/spin/dataformat-configuration-in-process-application/src/main/java/org/camunda/bpm/example/spin/dataformat/configuration/Money.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.spin.dataformat.configuration;
18 |
19 | /**
20 | * @author Thorben Lindhauer
21 | *
22 | */
23 | public class Money {
24 |
25 | protected int amount;
26 |
27 | public Money(int amount) {
28 | this.amount = amount;
29 | }
30 |
31 | public int getAmount() {
32 | return amount;
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/spin/dataformat-configuration-in-process-application/src/main/resources/META-INF/processes.xml:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/spin/dataformat-configuration-in-process-application/src/main/resources/META-INF/processes.xml
--------------------------------------------------------------------------------
/spin/dataformat-configuration-in-process-application/src/main/resources/META-INF/services/org.camunda.spin.spi.DataFormatConfigurator:
--------------------------------------------------------------------------------
1 | org.camunda.bpm.example.spin.dataformat.configuration.JacksonDataFormatConfigurator
--------------------------------------------------------------------------------
/spin/dataformat-configuration-in-process-application/src/main/resources/testProcess.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/spin/dataformat-configuration-in-process-application/src/main/resources/testProcess.png
--------------------------------------------------------------------------------
/spin/dataformat-configuration-in-process-application/src/main/runtime/jboss/webapp/WEB-INF/jboss-deployment-structure.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/spin/dataformat-configuration-in-process-application/src/main/runtime/jboss/webapp/WEB-INF/jboss-web.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | /dataformat-example
4 |
--------------------------------------------------------------------------------
/spin/dataformat-configuration-in-process-application/src/main/runtime/tomcat/java/org/camunda/bpm/example/spin/dataformat/IgnoreBean.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.spin.dataformat;
18 |
19 | import java.lang.annotation.ElementType;
20 | import java.lang.annotation.Retention;
21 | import java.lang.annotation.RetentionPolicy;
22 | import java.lang.annotation.Target;
23 |
24 | import jakarta.inject.Qualifier;
25 |
26 | /**
27 | * @author Thorben Lindhauer
28 | */
29 | @Qualifier
30 | @Retention(RetentionPolicy.RUNTIME)
31 | @Target(ElementType.TYPE)
32 | public @interface IgnoreBean {
33 |
34 | }
35 |
--------------------------------------------------------------------------------
/spin/dataformat-configuration-in-process-application/src/main/runtime/tomcat/java/org/camunda/bpm/example/spin/dataformat/ProcessApplicationProducer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.spin.dataformat;
18 |
19 | import jakarta.enterprise.context.Dependent;
20 | import jakarta.enterprise.inject.Produces;
21 |
22 | import org.camunda.bpm.application.ProcessApplicationInterface;
23 |
24 | /**
25 | * @author Thorben Lindhauer
26 | *
27 | */
28 | public class ProcessApplicationProducer {
29 |
30 | @Produces
31 | @Dependent
32 | public ProcessApplicationInterface getProcessApplication() {
33 | return TomcatProcessApplication.INSTANCE;
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/spin/dataformat-configuration-in-process-application/src/main/runtime/tomcat/java/org/camunda/bpm/example/spin/dataformat/TomcatProcessApplication.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.spin.dataformat;
18 |
19 | import org.camunda.bpm.application.PostDeploy;
20 | import org.camunda.bpm.application.ProcessApplication;
21 | import org.camunda.bpm.application.impl.JakartaServletProcessApplication;
22 |
23 | /**
24 | * @author Thorben Lindhauer
25 | *
26 | */
27 | @IgnoreBean
28 | @ProcessApplication
29 | public class TomcatProcessApplication extends JakartaServletProcessApplication {
30 | public static TomcatProcessApplication INSTANCE;
31 |
32 | // empty implementation
33 |
34 | @PostDeploy
35 | public void postDeploy() {
36 | INSTANCE = this;
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/spin/dataformat-configuration-in-process-application/src/main/runtime/weblogic/webapp/WEB-INF/glassfish-web.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | /dataformat-example
5 |
6 |
7 |
--------------------------------------------------------------------------------
/spin/dataformat-configuration-in-process-application/src/main/runtime/wildfly/webapp/WEB-INF/jboss-deployment-structure.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/spin/dataformat-configuration-in-process-application/src/main/runtime/wildfly/webapp/WEB-INF/jboss-web.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | /dataformat-example
4 |
--------------------------------------------------------------------------------
/spin/dataformat-configuration-in-process-application/src/main/webapp/WEB-INF/beans.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 | org.camunda.bpm.example.spin.dataformat.servlet.ProcessApplicationContextInterceptor
9 |
10 |
--------------------------------------------------------------------------------
/spin/dataformat-configuration-in-process-application/src/main/webapp/WEB-INF/web.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Process Starter Servlet
6 | org.camunda.bpm.example.spin.dataformat.servlet.StartProcessServlet
7 |
8 |
9 |
10 | Process Starter Servlet
11 | /start-process
12 |
13 |
--------------------------------------------------------------------------------
/spin/dataformat-configuration-in-process-application/src/test/resources/camunda.cfg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-autodeployment/README.md:
--------------------------------------------------------------------------------
1 | # Spring Boot application with embedded Camunda engine and auto-deployed process
2 |
3 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/spring-boot-starter/example-autodeployment).
4 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
5 | might need to adjust them to make them work.
6 |
7 | Or have a look at another Spring Boot Starter example: [spring-boot-starter/example-simple](/spring-boot-starter/example-simple).
--------------------------------------------------------------------------------
/spring-boot-starter/example-dmn-rest/README.md:
--------------------------------------------------------------------------------
1 | # Spring Boot Web application with embedded Camunda engine
2 |
3 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/spring-boot-starter/example-dmn-rest).
4 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
5 | might need to adjust them to make them work.
--------------------------------------------------------------------------------
/spring-boot-starter/example-invoice/src/main/resources/META-INF/processes.xml:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/spring-boot-starter/example-invoice/src/main/resources/META-INF/processes.xml
--------------------------------------------------------------------------------
/spring-boot-starter/example-invoice/src/main/resources/application.yaml:
--------------------------------------------------------------------------------
1 | spring.datasource:
2 | url: jdbc:h2:./camunda-h2-default/process-engine;TRACE_LEVEL_FILE=0;DB_CLOSE_ON_EXIT=FALSE
3 | # url: jdbc:postgresql://localhost:5432/process-engine # for PostgreSQL or CockroachDB
4 | # url: jdbc:mysql://localhost:3306/process-engine?sendFractionalSeconds=false
5 | # url: jdbc:mariadb://localhost:3306/process-engine
6 | # url: jdbc:oracle:thin:@localhost:1521:ORCL
7 | # url: jdbc:db2://localhost:50000/engine
8 | # url: jdbc:sqlserver://localhost:1433;databaseName=processEngine
9 | username: camunda
10 | password: camunda
11 | driver-class-name: org.h2.Driver
12 | # driver-class-name: org.postgresql.Driver # for PostgreSQL
13 | # driver-class-name: com.mysql.cj.jdbc.Driver
14 | # driver-class-name: org.mariadb.jdbc.Driver
15 | # driver-class-name: com.microsoft.sqlserver.jdbc.SQLServerDriver
16 | # driver-class-name: oracle.jdbc.OracleDriver
17 | # driver-class-name: com.ibm.db2.jcc.DB2Driver
18 |
19 | camunda:
20 | bpm:
21 | job-execution:
22 | core-pool-size: 10
23 | authorization.enabled: true
24 | # Uncomment to add additional properties,
25 | # not directly implemented by the Camunda Spring Boot Starter
26 | # generic-properties.properties:
27 |
28 | # Uncomment if you need to run the application on a non-standard port
29 | # server.port: 18080
30 |
31 | # logging:
32 | # level.root: INFO
33 | # file: logs/server.log
34 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-simple/src/main/java/org/camunda/bpm/spring/boot/example/simple/SayHelloDelegate.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.spring.boot.example.simple;
18 |
19 | import org.camunda.bpm.engine.delegate.DelegateExecution;
20 | import org.camunda.bpm.engine.delegate.JavaDelegate;
21 | import org.slf4j.Logger;
22 | import org.slf4j.LoggerFactory;
23 | import org.springframework.stereotype.Component;
24 |
25 | @Component
26 | public class SayHelloDelegate implements JavaDelegate {
27 |
28 | private final Logger logger = LoggerFactory.getLogger(this.getClass());
29 |
30 | @Override
31 | public void execute(DelegateExecution execution) throws Exception {
32 | logger.info("executed sayHelloDelegate: {}", execution);
33 | }
34 |
35 | }
36 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-simple/src/main/resources/META-INF/processes.xml:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/spring-boot-starter/example-simple/src/main/resources/META-INF/processes.xml
--------------------------------------------------------------------------------
/spring-boot-starter/example-simple/src/main/resources/application.yaml:
--------------------------------------------------------------------------------
1 | spring.application.name: simpleApplication
2 | spring:
3 | datasource:
4 | url: jdbc:h2:mem:example-simple;DB_CLOSE_DELAY=-1;DB_CLOSE_ON_EXIT=FALSE
5 | camunda:
6 | bpm:
7 | application:
8 | delete-upon-undeploy: false
9 | scan-for-process-definitions: false
10 | deploy-changed-only: true
11 | resume-previous-versions: true
12 | resume-previous-by: a value
13 | job-execution:
14 | enabled: true
15 | metrics:
16 | enabled: false
17 | db-reporter-activate: false
18 |
19 |
20 | #camunda.bpm.auto-deployment-enabled: false
21 |
22 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-simple/src/test/resources/logback-test.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-twitter/src/main/java/org/camunda/bpm/spring/boot/example/twitter/TwitterServletProcessApplication.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.spring.boot.example.twitter;
18 |
19 | import org.camunda.bpm.spring.boot.starter.annotation.EnableProcessApplication;
20 | import org.springframework.boot.SpringApplication;
21 | import org.springframework.boot.autoconfigure.SpringBootApplication;
22 |
23 | @SpringBootApplication
24 | @EnableProcessApplication
25 | public class TwitterServletProcessApplication {
26 |
27 | public static void main(String... args) {
28 | SpringApplication.run(TwitterServletProcessApplication.class, args);
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-twitter/src/main/resources/META-INF/processes.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 | default
9 |
10 | false
11 | true
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-twitter/src/main/resources/application.yaml:
--------------------------------------------------------------------------------
1 | camunda.bpm:
2 | admin-user:
3 | id: demo
4 | password: demo
5 | filter.create: All
--------------------------------------------------------------------------------
/spring-boot-starter/example-twitter/src/main/resources/static/forms/createTweet.html:
--------------------------------------------------------------------------------
1 | Create Tweet
2 |
3 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-twitter/src/main/resources/static/forms/reviewTweet.html:
--------------------------------------------------------------------------------
1 | Do you approve this tweet?
2 |
3 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-web/src/main/java/org/camunda/bpm/spring/boot/example/web/RestApplication.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.spring.boot.example.web;
18 |
19 | import org.camunda.bpm.spring.boot.starter.annotation.EnableProcessApplication;
20 | import org.springframework.boot.SpringApplication;
21 | import org.springframework.boot.autoconfigure.SpringBootApplication;
22 |
23 | @SpringBootApplication
24 | @EnableProcessApplication
25 | public class RestApplication {
26 |
27 | public static void main(final String... args) throws Exception {
28 | SpringApplication.run(RestApplication.class, args);
29 | }
30 |
31 | }
32 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-web/src/main/resources/META-INF/processes.xml:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/spring-boot-starter/example-web/src/main/resources/META-INF/processes.xml
--------------------------------------------------------------------------------
/spring-boot-starter/example-web/src/main/resources/application.yml:
--------------------------------------------------------------------------------
1 | camunda.bpm.metrics:
2 | enabled: false
3 | db-reporter-activate: false
4 |
5 | spring:
6 | main.allow-bean-definition-overriding: true
7 | security.user:
8 | name: demo
9 | password: demo
--------------------------------------------------------------------------------
/spring-boot-starter/example-web/src/test/java/org/camunda/bpm/spring/boot/example/web/RestConfig.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.spring.boot.example.web;
18 |
19 | import org.springframework.beans.factory.annotation.Value;
20 | import org.springframework.boot.test.context.TestConfiguration;
21 | import org.springframework.boot.web.client.RestTemplateBuilder;
22 | import org.springframework.context.annotation.Bean;
23 | import org.springframework.web.client.RestTemplate;
24 |
25 | @TestConfiguration
26 | public class RestConfig {
27 |
28 | @Value("${spring.security.user.name}")
29 | private String name;
30 |
31 | @Value("${spring.security.user.password}")
32 | private String password;
33 |
34 | @Bean
35 | public RestTemplate restTemplate() {
36 | return new RestTemplateBuilder().basicAuthentication(name, password).build();
37 | }
38 |
39 | }
--------------------------------------------------------------------------------
/spring-boot-starter/example-web/src/test/resources/logback-test.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-webapp-ee/.gitignore:
--------------------------------------------------------------------------------
1 | camunda-license.txt
2 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-webapp-ee/src/main/java/org/camunda/bpm/spring/boot/example/webapp/ee/EnterpriseWebappExampleApplication.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.spring.boot.example.webapp.ee;
18 |
19 | import org.camunda.bpm.spring.boot.starter.annotation.EnableProcessApplication;
20 | import org.springframework.boot.SpringApplication;
21 | import org.springframework.boot.autoconfigure.SpringBootApplication;
22 |
23 | @SpringBootApplication
24 | @EnableProcessApplication
25 | public class EnterpriseWebappExampleApplication {
26 |
27 | public static void main(String... args) {
28 | SpringApplication.run(EnterpriseWebappExampleApplication.class, args);
29 | }
30 |
31 | }
32 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-webapp-ee/src/main/resources/META-INF/processes.xml:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/spring-boot-starter/example-webapp-ee/src/main/resources/META-INF/processes.xml
--------------------------------------------------------------------------------
/spring-boot-starter/example-webapp-ee/src/main/resources/application.yaml:
--------------------------------------------------------------------------------
1 | camunda:
2 | bpm:
3 | filter:
4 | create: All
5 | job-execution:
6 | core-pool-size: 10
7 | admin-user:
8 | id: demo
9 | password: demo
10 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-webapp/src/main/java/org/camunda/bpm/spring/boot/example/webapp/WebappExampleApplication.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.spring.boot.example.webapp;
18 |
19 | import org.camunda.bpm.spring.boot.starter.annotation.EnableProcessApplication;
20 | import org.springframework.boot.SpringApplication;
21 | import org.springframework.boot.autoconfigure.SpringBootApplication;
22 |
23 | @SpringBootApplication
24 | @EnableProcessApplication
25 | public class WebappExampleApplication {
26 |
27 | public static void main(String... args) {
28 | SpringApplication.run(WebappExampleApplication.class, args);
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-webapp/src/main/java/org/camunda/bpm/spring/boot/example/webapp/delegate/SayHelloDelegate.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.spring.boot.example.webapp.delegate;
18 |
19 | import org.camunda.bpm.engine.delegate.DelegateExecution;
20 | import org.camunda.bpm.engine.delegate.JavaDelegate;
21 | import org.slf4j.Logger;
22 | import org.slf4j.LoggerFactory;
23 | import org.springframework.stereotype.Component;
24 |
25 | @Component
26 | public class SayHelloDelegate implements JavaDelegate {
27 |
28 | private static final Logger LOGGER = LoggerFactory.getLogger(SayHelloDelegate.class);
29 |
30 | @Override
31 | public void execute(DelegateExecution execution) throws Exception {
32 | LOGGER.info("hello {}", execution);
33 | }
34 |
35 | }
36 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-webapp/src/main/resources/META-INF/processes.xml:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/spring-boot-starter/example-webapp/src/main/resources/META-INF/processes.xml
--------------------------------------------------------------------------------
/spring-boot-starter/example-webapp/src/main/resources/application.yaml:
--------------------------------------------------------------------------------
1 | camunda.bpm:
2 | webapp:
3 | index-redirect-enabled: true
4 | admin-user:
5 | id: demo
6 | password: demo
7 |
8 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-webapp/src/test/java/org/camunda/bpm/spring/boot/example/webapp/ApplicationTest.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.spring.boot.example.webapp;
18 |
19 | import org.junit.Test;
20 | import org.junit.runner.RunWith;
21 | import org.springframework.boot.test.context.SpringBootTest;
22 | import org.springframework.test.context.junit4.SpringRunner;
23 |
24 | @RunWith(SpringRunner.class)
25 | @SpringBootTest(classes = { WebappExampleApplication.class }, webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
26 | public class ApplicationTest {
27 |
28 | @Test
29 | public void startUpTest() {
30 | // context init test
31 | }
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/spring-boot-starter/example-webapp/src/test/resources/logback-test.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/spring-boot-starter/external-task-client/loan-granting-spring-boot-webapp/src/main/java/org/camunda/bpm/spring/boot/example/Application.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.spring.boot.example;
18 |
19 | import org.springframework.boot.SpringApplication;
20 | import org.springframework.boot.autoconfigure.SpringBootApplication;
21 |
22 | @SpringBootApplication
23 | public class Application {
24 |
25 | public static void main(String... args) {
26 | SpringApplication.run(Application.class, args);
27 | }
28 |
29 | }
30 |
--------------------------------------------------------------------------------
/spring-boot-starter/external-task-client/loan-granting-spring-boot-webapp/src/main/resources/application.yml:
--------------------------------------------------------------------------------
1 | camunda.bpm:
2 | admin-user:
3 | id: demo
4 | password: demo
5 | client:
6 | base-url: http://localhost:8080/engine-rest # The URL pointing to the Camunda Platform Runtime REST API
7 | async-response-timeout: 1000 # Defines the maximum duration of the long-polling request
8 | worker-id: spring-boot-client # Identifies the worker towards the Engine
9 | # basic-auth: # Configure if REST API is secured with basic authentication
10 | # username: my-username
11 | # password: my-password
12 | subscriptions:
13 | creditScoreChecker: # This topic name must match the respective `@ExternalTaskSubscription`
14 | process-definition-key: loan_process # Filters for External Tasks of this key
15 | auto-open: false # Defines whether the subscription is opened automatically or not
16 | loanGranter:
17 | lock-duration: 10000 # Defines for how long the External Tasks are locked until they can be fetched again
18 |
19 | logging.level.org.camunda.bpm.client: info
--------------------------------------------------------------------------------
/spring-boot-starter/external-task-client/loan-granting-spring/README.md:
--------------------------------------------------------------------------------
1 | # External Task Client Spring: Loan Granting Example
2 |
3 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/spring-boot-starter/external-task-client/loan-granting-spring).
4 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
5 | might need to adjust them to make them work.
6 |
7 | Or have a look at another Spring Boot Starter example: [external-task-client/loan-granting-spring-boot-webapp](/spring-boot-starter/external-task-client/loan-granting-spring-boot-webapp).
--------------------------------------------------------------------------------
/spring-boot-starter/external-task-client/order-handling-spring-boot/README.md:
--------------------------------------------------------------------------------
1 | # External Task Client Spring Boot Starter: Order Handling Example
2 |
3 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/spring-boot-starter/external-task-client/order-handling-spring-boot).
4 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
5 | might need to adjust them to make them work.
6 |
7 | Or have a look at another Spring Boot Starter example: [external-task-client/loan-granting-spring-boot-webapp](/spring-boot-starter/external-task-client/loan-granting-spring-boot-webapp).
--------------------------------------------------------------------------------
/spring-boot-starter/external-task-client/request-interceptor-spring-boot/README.md:
--------------------------------------------------------------------------------
1 | # Spring Boot External Task Client Starter: Request Interceptor Example
2 |
3 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/spring-boot-starter/external-task-client/request-interceptor-spring-boot).
4 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
5 | might need to adjust them to make them work.
6 |
7 | Or have a look at another Spring Boot Starter example: [external-task-client/loan-granting-spring-boot-webapp](/spring-boot-starter/external-task-client/loan-granting-spring-boot-webapp).
--------------------------------------------------------------------------------
/startevent/message-start/README.md:
--------------------------------------------------------------------------------
1 | # Overview
2 |
3 | This quickstart demonstrates how to start a process by message. It consists of two process definitions. One that defines a message start event as follows:
4 |
5 | ![Message Start Process][1]
6 |
7 | The other process definition contains a service task that sends a message. This message instantiates the message start event process.
8 |
9 | ![Instantiating Process][2]
10 |
11 | # Run it
12 |
13 | 1. Checkout the project with Git
14 | 2. Read and run the [unit test][3]
15 |
16 | [1]: src/main/resources/message_start_process.png
17 | [2]: src/main/resources/instantiating_process.png
18 | [3]: src/test/java/org/camunda/bpm/example/event/message/MessageStartEventTest.java
19 |
--------------------------------------------------------------------------------
/startevent/message-start/src/main/java/org/camunda/bpm/example/event/message/InstantiateProcessByMessageDelegate.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.example.event.message;
18 |
19 | import org.camunda.bpm.engine.RuntimeService;
20 | import org.camunda.bpm.engine.delegate.DelegateExecution;
21 | import org.camunda.bpm.engine.delegate.JavaDelegate;
22 |
23 | /**
24 | * @author Thorben Lindhauer
25 | */
26 | public class InstantiateProcessByMessageDelegate implements JavaDelegate {
27 |
28 | public void execute(DelegateExecution execution) {
29 | RuntimeService runtimeService = execution.getProcessEngineServices().getRuntimeService();
30 | runtimeService.startProcessInstanceByMessage("instantiationMessage");
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/startevent/message-start/src/main/resources/instantiating_process.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/startevent/message-start/src/main/resources/instantiating_process.png
--------------------------------------------------------------------------------
/startevent/message-start/src/main/resources/message_start_process.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/startevent/message-start/src/main/resources/message_start_process.png
--------------------------------------------------------------------------------
/startevent/message-start/src/test/resources/camunda.cfg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
--------------------------------------------------------------------------------
/startevent/soap-cxf-server-start/README.md:
--------------------------------------------------------------------------------
1 | SOAP CXF server start process example
2 | ===============================================================
3 |
4 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/startevent/soap-cxf-server-start).
5 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
6 | might need to adjust them to make them work.
--------------------------------------------------------------------------------
/tasklist/cats-plugin/cats.js:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 |
19 | export default {
20 | id: 'tasklist.cats',
21 | pluginPoint: 'tasklist.task.detail',
22 | priority: 9001,
23 | render: (node) => {
24 | node.innerHTML = '
Cats!
';
25 | },
26 | properties: {
27 | label: 'Cats!'
28 | }
29 | }
--------------------------------------------------------------------------------
/tasklist/cats-plugin/screenshot.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/tasklist/cats-plugin/screenshot.png
--------------------------------------------------------------------------------
/tasklist/jquery-34-behavior/README.md:
--------------------------------------------------------------------------------
1 | JQuery 3.4 Behavior Patch
2 | =================================
3 |
4 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/tasklist/jquery-34-behavior).
5 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
6 | might need to adjust them to make them work.
--------------------------------------------------------------------------------
/testing/assert/job-announcement-publication-process/README.md:
--------------------------------------------------------------------------------
1 | # Executing Camunda Platform Assert tests
2 |
3 | This project demonstrates how to setup a minimal project to run Camunda Platform Assert tests
4 |
5 | ## Prerequisites
6 | * Java 17/21
7 |
8 | ## How to run it
9 |
10 | 1. Checkout the project with Git
11 | 2. Read and run the [unit tests][1]
12 |
13 | ### Running the test with maven
14 |
15 | In order to run the testsuite with maven you can use:
16 |
17 | ```
18 | mvn clean test
19 | ```
20 |
21 | ## Further reading
22 | If you want to read more about [Camunda Platform Assert][assert], go to the [testing user guide](https://docs.camunda.org/manual/7.23/user-guide/testing/) in the Camunda docs.
23 |
24 |
25 | [assert]: https://github.com/camunda/camunda-bpm-platform/tree/master/test-utils/assert
26 | [1]: src/test/java/org/camunda/bpm/engine/test/assertions/examples
27 |
--------------------------------------------------------------------------------
/testing/assert/job-announcement-publication-process/src/main/java/org/camunda/bpm/engine/test/assertions/examples/jobannouncement/JobAnnouncement.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.engine.test.assertions.examples.jobannouncement;
18 |
19 | public interface JobAnnouncement {
20 |
21 | Long getId();
22 |
23 | }
24 |
--------------------------------------------------------------------------------
/testing/assert/job-announcement-publication-process/src/main/java/org/camunda/bpm/engine/test/assertions/examples/jobannouncement/JobAnnouncementService.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
3 | * under one or more contributor license agreements. See the NOTICE file
4 | * distributed with this work for additional information regarding copyright
5 | * ownership. Camunda licenses this file to you under the Apache License,
6 | * Version 2.0; you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.camunda.bpm.engine.test.assertions.examples.jobannouncement;
18 |
19 | public interface JobAnnouncementService {
20 |
21 | void postToWebsite(Long jobAnnouncementId);
22 | void postToTwitter(Long jobAnnouncementId);
23 | void postToFacebook(Long jobAnnouncementId);
24 | void notifyAboutPostings(Long jobAnnouncementId);
25 | String findRequester(Long jobAnnouncementId);
26 | String findEditor(Long jobAnnouncementId);
27 |
28 | }
29 |
--------------------------------------------------------------------------------
/testing/assert/job-announcement-publication-process/src/test/resources/camunda.cfg.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/testing/junit5/camunda-bpm-junit-assert/src/test/resources/camunda.cfg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/testing/junit5/camunda-bpm-junit-assert/src/test/resources/logback-test.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
6 |
7 | %d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/testing/junit5/camunda-bpm-junit-use-engine/README.md:
--------------------------------------------------------------------------------
1 | # Register Your Process Engine in JUnit 5 and Camunda Platform Assert
2 |
3 | This examples shows how to create a process engine in your test class without a configuration file and register it for your test runs using the [JUnit 5 extension][junit5] and [Camunda Platform Assert][assert].
4 |
5 | The project contains the following files:
6 |
7 | ```
8 | src
9 | ├── main
10 | │ ├── java
11 | │ └── resources
12 | └── test
13 | ├── java
14 | │ └── org
15 | │ └── camunda
16 | │ └── bpm
17 | │ └── unittest
18 | │ └── UseProcessEngineTest.java (1)
19 | └── resources
20 | └── testProcess.bpmn (2)
21 | ```
22 | Explanation:
23 | * (1) The test class that
24 | * creates the process engine from the configuration builder
25 | * registers the process engine for the JUnit 5 test
26 | * registers the process engine for the Camunda Platform Assert library
27 | * (2) The process model to test
28 |
29 | ## Prerequisites
30 | * Java 17/21
31 |
32 | ## Running the test with maven
33 |
34 | In order to run the test with maven you can use:
35 |
36 | ```
37 | mvn clean test
38 | ```
39 |
40 | [junit5]: https://github.com/camunda/camunda-bpm-platform/tree/master/test-utils/junit5-extension
41 | [assert]: https://github.com/camunda/camunda-bpm-platform/tree/master/test-utils/assert
--------------------------------------------------------------------------------
/testing/junit5/camunda-bpm-junit-use-engine/src/test/resources/logback-test.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
6 |
7 | %d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/usertask/task-assignment-email/README.md:
--------------------------------------------------------------------------------
1 | # Task Assignment Email
2 |
3 | This example is not actively maintained anymore. You can refer to the [example with fixed version of Camunda 7.18](https://github.com/camunda/camunda-bpm-examples/blob/7.18/usertask/task-assignment-email).
4 | Due to Camunda Platform 7 backward compatibility, the examples usually still work with later versions. However, you
5 | might need to adjust them to make them work.
--------------------------------------------------------------------------------
/usertask/task-camunda-forms/README.md:
--------------------------------------------------------------------------------
1 | # Camunda Task Forms
2 |
3 | This quickstart demonstrates how to use the [Camunda Forms][5] feature. Camunda Forms are `.form` files created in the Camunda Modeler and embedded inside the camunda Tasklist:
4 |
5 | ![Camunda Forms Screenshot][1]
6 |
7 | # Overview
8 | This example uses Jakarta API. It is compatible with the latest releases of Camunda Tomcat and WildFly distributions.
9 |
10 | ## Where are Camunda Forms added?
11 |
12 | Camunda Forms can be added to the web resources of a web application. As we use maven, they are added to the [src/main/webapp][4] folder of your project.
13 |
14 | ## How are Camunda Forms referenced?
15 |
16 | Camunda Forms are referenced using the `camunda:formKey` property of a BPMN `` or a BPMN ``:
17 |
18 | ```xml
19 |
20 | ...
21 |
22 | ```
23 |
24 | The attribute can also be set through the properties panel using the camunda Modeler:
25 |
26 | ![Camunda Forms Screenshot Modeler][2]
27 |
28 | ## How to use it?
29 |
30 | 1. Checkout the project with Git
31 | 2. Build the project with maven
32 | 3. Deploy the war file to a Camunda Platform Runtime distribution
33 | 4. Go the the Tasklist and start a process instance for the process named "Camunda Forms Quickstart"
34 |
35 | [1]: docs/screenshot.png
36 | [2]: docs/screenshot-modeler.png
37 | [3]: src/main/webapp/start-form.html
38 | [4]: src/main/webapp
39 | [5]: https://docs.camunda.org/manual/7.23/user-guide/task-forms/#camunda-task-forms
40 |
--------------------------------------------------------------------------------
/usertask/task-camunda-forms/docs/screenshot-modeler.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/usertask/task-camunda-forms/docs/screenshot-modeler.png
--------------------------------------------------------------------------------
/usertask/task-camunda-forms/docs/screenshot.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/usertask/task-camunda-forms/docs/screenshot.png
--------------------------------------------------------------------------------
/usertask/task-camunda-forms/src/main/resources/META-INF/processes.xml:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/camunda/camunda-bpm-examples/27ec0f9378554f6e3cea02bc3bce248360af129a/usertask/task-camunda-forms/src/main/resources/META-INF/processes.xml
--------------------------------------------------------------------------------
/usertask/task-camunda-forms/src/main/webapp/start-form.form:
--------------------------------------------------------------------------------
1 | {
2 | "components": [
3 | {
4 | "key": "creditor",
5 | "label": "Creditor",
6 | "type": "textfield",
7 | "validate": {
8 | "required": true
9 | }
10 | },
11 | {
12 | "key": "amount",
13 | "label": "Amount",
14 | "type": "textfield",
15 | "validate": {
16 | "required": true,
17 | "pattern": "^[0-9]+$"
18 | }
19 | },
20 | {
21 | "description": "An invoice number in the format: C-123.",
22 | "key": "invoiceNumber",
23 | "label": "Invoice Number",
24 | "type": "textfield",
25 | "validate": {
26 | "pattern": "^C-[0-9]+$"
27 | }
28 | }
29 | ],
30 | "type": "default"
31 | }
32 |
--------------------------------------------------------------------------------
/usertask/task-camunda-forms/src/main/webapp/task-form.form:
--------------------------------------------------------------------------------
1 | {
2 | "components": [
3 | {
4 | "key": "creditor",
5 | "label": "Creditor",
6 | "type": "textfield",
7 | "validate": {
8 | "required": true
9 | }
10 | },
11 | {
12 | "key": "amount",
13 | "label": "Amount",
14 | "type": "textfield",
15 | "validate": {
16 | "required": true,
17 | "pattern": "^[0-9]+$"
18 | }
19 | },
20 | {
21 | "description": "An invoice number in the format: C-123.",
22 | "key": "invoiceNumber",
23 | "label": "Invoice Number",
24 | "type": "textfield",
25 | "validate": {
26 | "pattern": "^C-[0-9]+$"
27 | }
28 | },
29 | {
30 | "key": "approved",
31 | "label": "Approved?",
32 | "type": "textfield",
33 | "validate": {
34 | "required": true,
35 | "pattern": "(true|false)"
36 | }
37 | },
38 | {
39 | "key": "approvedBy",
40 | "label": "Approved By",
41 | "type": "textfield"
42 | }
43 | ],
44 | "type": "default"
45 | }
46 |
--------------------------------------------------------------------------------
/usertask/task-form-embedded-bpmn-events/README.md:
--------------------------------------------------------------------------------
1 | # Error and Escalation Events in Embedded Forms
2 |
3 | This quickstart demonstrates how to use escalation and error events in embedded forms.
4 |
5 | # Overview
6 | This example uses Jakarta API. It is compatible with the latest releases of Camunda Tomcat and WildFly distributions.
7 |
8 | ## Where are Error and Escalation events defined?
9 |
10 | Boundary Events can be added in the Camunda Modeler. Each can be referenced by its error- or escalation code.
11 |
12 | ![Modeler Screenshot][1]
13 |
14 | ## How are these events triggered from an embedded form?
15 |
16 | Error events can be triggered by calling `camForm.error('error-code', 'error-message')` from a custom Script or using the `