├── demo
├── demo-introducing-machine-learning
│ ├── demo-listener
│ │ ├── src
│ │ │ └── main
│ │ │ │ └── resources
│ │ │ │ ├── processes
│ │ │ │ └── empty.txt
│ │ │ │ └── application.properties
│ │ └── pom.xml
│ ├── demo-process
│ │ └── src
│ │ │ └── main
│ │ │ ├── resources
│ │ │ ├── loan.bar
│ │ │ ├── log4j.properties
│ │ │ └── application.properties
│ │ │ └── java
│ │ │ └── org
│ │ │ └── flowable
│ │ │ └── demo
│ │ │ ├── delegate
│ │ │ └── DummyServiceTask.java
│ │ │ ├── StartController.java
│ │ │ └── RabbitMQMessageBasedJobManager.java
│ ├── README.md
│ ├── demo-decision-analysis
│ │ └── src
│ │ │ └── main
│ │ │ ├── resources
│ │ │ ├── application.properties
│ │ │ └── log4j.properties
│ │ │ └── java
│ │ │ └── org
│ │ │ └── flowable
│ │ │ └── decision
│ │ │ └── SuggestionRestController.java
│ ├── demo-admin
│ │ ├── pom.xml
│ │ └── src
│ │ │ └── main
│ │ │ └── java
│ │ │ └── org
│ │ │ └── flowable
│ │ │ └── AdminApplication.java
│ └── demo-spark
│ │ └── src
│ │ └── main
│ │ └── java
│ │ └── org
│ │ └── flowable
│ │ └── dto
│ │ └── Rule.java
└── demo-jax-2018
│ ├── demo-hello-world
│ ├── src
│ │ └── main
│ │ │ ├── resources
│ │ │ ├── application.properties
│ │ │ ├── log4j.properties
│ │ │ └── flowable-banner.txt
│ │ │ └── java
│ │ │ └── org
│ │ │ └── flowable
│ │ │ └── jaxdemo
│ │ │ └── MyApplication.java
│ └── pom.xml
│ ├── demo-process-mongo
│ ├── src
│ │ └── main
│ │ │ ├── resources
│ │ │ ├── application.properties
│ │ │ ├── log4j.properties
│ │ │ ├── demo-app
│ │ │ │ ├── form-name.form
│ │ │ │ ├── form-advreview.form
│ │ │ │ ├── form-loanreview.form
│ │ │ │ └── form-loanin.form
│ │ │ └── flowable-banner.txt
│ │ │ └── java
│ │ │ └── org
│ │ │ └── flowable
│ │ │ ├── delegate
│ │ │ └── CreditAdviceDelegate.java
│ │ │ ├── demo
│ │ │ ├── delegate
│ │ │ │ └── DummyServiceTask.java
│ │ │ └── StartController.java
│ │ │ └── ProcessApplication.java
│ └── pom.xml
│ ├── demo-decision-analysis
│ ├── src
│ │ └── main
│ │ │ ├── resources
│ │ │ ├── application.properties
│ │ │ ├── log4j.properties
│ │ │ └── flowable-banner.txt
│ │ │ └── java
│ │ │ └── org
│ │ │ └── flowable
│ │ │ └── DecisionAnalysisApplication.java
│ └── pom.xml
│ ├── quick-benchmark
│ └── src
│ │ └── main
│ │ └── java
│ │ └── org
│ │ └── flowable
│ │ └── delegate
│ │ ├── NoopDelegate.java
│ │ ├── ValidateInputDelegate.java
│ │ └── SetVariablesDelegate.java
│ └── demo-spark
│ └── src
│ └── main
│ └── java
│ └── org
│ └── flowable
│ └── dto
│ └── Rule.java
├── flowable-kafka
├── frontend
│ ├── src
│ │ ├── react-app-env.d.ts
│ │ ├── dashBoard.scss
│ │ ├── stationsMap.scss
│ │ ├── commentMarker.scss
│ │ ├── rating.scss
│ │ ├── GlobalStyle.ts
│ │ ├── avatar.scss
│ │ ├── model.ts
│ │ ├── settings.ts
│ │ ├── index.css
│ │ ├── Switch.tsx
│ │ ├── Rating.tsx
│ │ ├── lineChart.scss
│ │ ├── CommentMarker.tsx
│ │ ├── index.tsx
│ │ ├── switch.scss
│ │ ├── settingsForm.scss
│ │ ├── Avatar.tsx
│ │ ├── SettingsForm.tsx
│ │ ├── api.ts
│ │ ├── stationMapForm.scss
│ │ └── DashBoard.tsx
│ ├── .prettierignore
│ ├── public
│ │ ├── robots.txt
│ │ ├── favicon.ico
│ │ ├── logo192.png
│ │ ├── logo512.png
│ │ ├── manifest.json
│ │ └── index.html
│ ├── .prettierrc
│ ├── .gitignore
│ ├── tsconfig.json
│ ├── README.md
│ ├── .vscode
│ │ └── settings.json
│ └── package.json
├── event-demo-review-app
│ ├── src
│ │ └── main
│ │ │ ├── resources
│ │ │ └── application.properties
│ │ │ └── java
│ │ │ └── org
│ │ │ └── flowable
│ │ │ └── eventdemo
│ │ │ └── review
│ │ │ ├── ReviewController.java
│ │ │ ├── ReviewService.java
│ │ │ └── ReviewApplication.java
│ └── pom.xml
├── event-demo-sentiment-analysis-app
│ ├── src
│ │ └── main
│ │ │ ├── resources
│ │ │ ├── application.properties
│ │ │ └── eventregistry
│ │ │ │ ├── channel-sentimentAnalysisResultOutboundChannel.channel
│ │ │ │ ├── event-sentimentAnalysisEvent.event
│ │ │ │ ├── channel-sentimentAnalysisInboundChannel.channel
│ │ │ │ └── event-sentimentAnalysisResultEvent.event
│ │ │ └── java
│ │ │ └── org
│ │ │ └── flowable
│ │ │ └── eventdemo
│ │ │ ├── service
│ │ │ ├── RandomSentimentService.java
│ │ │ └── SentimentService.java
│ │ │ └── sentiment
│ │ │ └── SentimentAnalysisApplication.java
│ └── pom.xml
├── event-demo-customer-case-app
│ ├── src
│ │ └── main
│ │ │ ├── resources
│ │ │ ├── eventregistry
│ │ │ │ ├── channel-sentimentAnalysisOutboundChannel.channel
│ │ │ │ ├── channel-reviewInboundChannel.channel
│ │ │ │ ├── channel-sentimentAnalysisResultChannel.channel
│ │ │ │ ├── event-sentimentAnalysisEvent.event
│ │ │ │ ├── event-reviewEvent.event
│ │ │ │ └── event-sentimentAnalysisResultEvent.event
│ │ │ ├── application.properties
│ │ │ └── forms
│ │ │ │ └── form-badReviewForm.form
│ │ │ └── java
│ │ │ └── org
│ │ │ └── flowable
│ │ │ └── eventdemo
│ │ │ ├── CustomerCaseApplication.java
│ │ │ └── controller
│ │ │ └── ReviewEventCounter.java
│ └── pom.xml
├── event-demo-common
│ ├── src
│ │ └── main
│ │ │ └── java
│ │ │ └── org
│ │ │ └── flowable
│ │ │ └── eventdemo
│ │ │ └── constant
│ │ │ └── KafkaTopicConstants.java
│ └── pom.xml
├── event-demo-api-gateway
│ ├── src
│ │ └── main
│ │ │ ├── java
│ │ │ └── org
│ │ │ │ └── flowable
│ │ │ │ └── eventdemo
│ │ │ │ └── ApiGatewayApplication.java
│ │ │ └── resources
│ │ │ └── application.yml
│ └── pom.xml
├── pom.xml
└── README.md
├── blog
├── EventApp.zip
├── migration-bpmn
│ ├── process_v1.png
│ ├── process_v4.png
│ ├── src
│ │ ├── main
│ │ │ ├── java
│ │ │ │ └── com
│ │ │ │ │ └── example
│ │ │ │ │ └── reservation
│ │ │ │ │ └── app
│ │ │ │ │ ├── migration
│ │ │ │ │ ├── MigrationReservationService.java
│ │ │ │ │ └── MigrationReservationServiceImpl.java
│ │ │ │ │ ├── service
│ │ │ │ │ ├── ReservationService.java
│ │ │ │ │ └── ReservationServiceImpl.java
│ │ │ │ │ └── ReservationApplication.java
│ │ │ └── resources
│ │ │ │ └── application.properties
│ │ └── test
│ │ │ └── resources
│ │ │ └── application.properties
│ ├── readme.md
│ └── pom.xml
├── demystifying-asynchronous-flag
│ └── Async Demo App.zip
├── 2022-02-flowable-spring-native
│ ├── .mvn
│ │ └── wrapper
│ │ │ ├── maven-wrapper.jar
│ │ │ └── maven-wrapper.properties
│ ├── src
│ │ ├── main
│ │ │ ├── resources
│ │ │ │ ├── META-INF
│ │ │ │ │ └── spring.factories
│ │ │ │ ├── application.properties
│ │ │ │ └── processes
│ │ │ │ │ ├── oneTaskProcess.bpmn20.xml
│ │ │ │ │ └── oneServiceTaskDelegateProcess.bpmn20.xml
│ │ │ └── java
│ │ │ │ ├── io
│ │ │ │ └── cloudnativejava
│ │ │ │ │ └── HintsUtils.java
│ │ │ │ └── com
│ │ │ │ └── example
│ │ │ │ └── demo
│ │ │ │ ├── DemoDelegate.java
│ │ │ │ ├── ProcessEngineCustomConfiguration.java
│ │ │ │ └── DemoApplication.java
│ │ └── test
│ │ │ └── java
│ │ │ └── com
│ │ │ └── example
│ │ │ └── demo
│ │ │ └── DemoApplicationTests.java
│ └── .gitignore
├── 2022-11-ms-exchange-online-modern-auth
│ ├── .mvn
│ │ └── wrapper
│ │ │ ├── maven-wrapper.jar
│ │ │ └── maven-wrapper.properties
│ ├── readme.md
│ ├── src
│ │ └── test
│ │ │ └── java
│ │ │ └── org
│ │ │ └── flowable
│ │ │ └── example
│ │ │ └── blog
│ │ │ └── MsExchangeOnlineModernAuthTestCliTest.java
│ └── pom.xml
├── 04-2021-flowable-spring-boot-native
│ └── src
│ │ └── main
│ │ ├── resources
│ │ ├── META-INF
│ │ │ └── native-image
│ │ │ │ └── resource-config.json
│ │ ├── application.properties
│ │ └── org
│ │ │ └── flowable
│ │ │ └── test.bpmn20.xml
│ │ └── java
│ │ └── org
│ │ └── flowable
│ │ └── demo
│ │ └── DemoApplication.java
└── 04-2021-jobs
│ ├── src
│ └── main
│ │ ├── resources
│ │ └── processes
│ │ │ ├── async-job-noop.bpmn20.xml
│ │ │ └── async-job-wait-time.bpmn20.xml
│ │ └── java
│ │ └── org
│ │ └── flowable
│ │ └── JobDelegate.java
│ └── pom.xml
├── spring-boot-example
├── src
│ ├── main
│ │ ├── resources
│ │ │ ├── application.properties
│ │ │ ├── cases
│ │ │ │ └── one-task-model.cmmn
│ │ │ └── forms
│ │ │ │ ├── vacation-request.form
│ │ │ │ ├── handle-vacation-request.form
│ │ │ │ └── adjust-vacation-request.form
│ │ └── java
│ │ │ └── org
│ │ │ └── flowable
│ │ │ └── examples
│ │ │ └── spring
│ │ │ └── boot
│ │ │ └── FlowableSpringBootExampleApplication.java
│ └── test
│ │ └── java
│ │ └── org
│ │ └── flowable
│ │ └── examples
│ │ └── spring
│ │ └── boot
│ │ └── FlowableSpringBootExampleApplicationTests.java
├── README.md
└── pom.xml
├── .gitignore
├── flowable-intro
├── README.md
├── src
│ └── main
│ │ ├── resources
│ │ ├── log4j.properties
│ │ ├── intro.bpmn20.xml
│ │ ├── flowable.cfg.xml
│ │ ├── flowable5.cfg.xml
│ │ ├── dmn.bpmn20.xml
│ │ ├── flowable.dmn.cfg.xml
│ │ └── intro.dmn
│ │ └── java
│ │ └── org
│ │ └── flowable
│ │ └── intro
│ │ └── IntroTask.java
└── pom.xml
├── flowfest-2018
└── demo-own-application
│ ├── src
│ ├── test
│ │ ├── resources
│ │ │ └── application-test.properties
│ │ └── java
│ │ │ └── com
│ │ │ └── example
│ │ │ └── demoflowfest
│ │ │ ├── DemoFlowfestApplicationTests.java
│ │ │ └── risk
│ │ │ └── RiskCalculatorTest.java
│ └── main
│ │ ├── java
│ │ └── com
│ │ │ └── example
│ │ │ └── demoflowfest
│ │ │ ├── HelloController.java
│ │ │ ├── vacation
│ │ │ ├── ConfirmationService.java
│ │ │ ├── VacationRequestInput.java
│ │ │ ├── VacationRequest.java
│ │ │ └── VacationRequestProcessor.java
│ │ │ ├── risk
│ │ │ ├── RiskInput.java
│ │ │ ├── RiskOutput.java
│ │ │ └── RiskCalculator.java
│ │ │ ├── DemoFlowfestApplication.java
│ │ │ ├── DefinitionsController.java
│ │ │ ├── UserCreatorCommandLineRunner.java
│ │ │ └── SecurityConfiguration.java
│ │ └── resources
│ │ └── application.properties
│ ├── .mvn
│ └── wrapper
│ │ ├── maven-wrapper.jar
│ │ └── maven-wrapper.properties
│ └── README.md
└── async-history
├── async-history-default-cfg
├── src
│ └── main
│ │ ├── resources
│ │ ├── diagrams
│ │ │ ├── default-history.png
│ │ │ ├── async-history-default.png
│ │ │ └── async-history-default2.png
│ │ └── log4j.properties
│ │ └── java
│ │ └── org
│ │ └── flowable
│ │ └── delegate
│ │ └── DummyServiceTask.java
└── pom.xml
├── async-history-jms-jta-cfg
└── src
│ └── main
│ ├── resources
│ ├── diagrams
│ │ └── async-history-jms-jta.png
│ └── log4j.properties
│ └── java
│ └── org
│ └── flowable
│ ├── delegate
│ └── DummyServiceTask.java
│ ├── ExampleJmsListener.java
│ └── JmsAsyncHistoryListener.java
├── async-history-rabbitmq-cfg
├── src
│ └── main
│ │ ├── resources
│ │ ├── diagrams
│ │ │ └── async-history-rabbitmq.png
│ │ └── log4j.properties
│ │ └── java
│ │ └── org
│ │ └── flowable
│ │ ├── delegate
│ │ └── DummyServiceTask.java
│ │ └── RabbitMQMessageBasedJobManager.java
└── pom.xml
├── async-history-jms-cfg
├── src
│ └── main
│ │ ├── resources
│ │ ├── diagrams
│ │ │ ├── async-history-message-queue-custom.png
│ │ │ └── async-history-message-queue-default.png
│ │ └── log4j.properties
│ │ └── java
│ │ └── org
│ │ └── flowable
│ │ └── delegate
│ │ └── DummyServiceTask.java
└── pom.xml
├── README.md
├── async-history-rabbitmq-springboot-listener
├── src
│ └── main
│ │ └── java
│ │ └── org
│ │ └── flowable
│ │ ├── MyJobMessageHandler.java
│ │ └── Receiver.java
└── pom.xml
└── pom.xml
/demo/demo-introducing-machine-learning/demo-listener/src/main/resources/processes/empty.txt:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/react-app-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/blog/EventApp.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/blog/EventApp.zip
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-review-app/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | server.port=8084
--------------------------------------------------------------------------------
/flowable-kafka/frontend/.prettierignore:
--------------------------------------------------------------------------------
1 | vendor/sockjs
2 | vendor/flowable-draw
3 | node_modules/
4 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/public/robots.txt:
--------------------------------------------------------------------------------
1 | # https://www.robotstxt.org/robotstxt.html
2 | User-agent: *
3 |
--------------------------------------------------------------------------------
/spring-boot-example/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | management.endpoints.web.exposure.include=*
2 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-hello-world/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | spring.banner.location=flowable-banner.txt
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-process-mongo/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | spring.banner.location=flowable-banner.txt
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | target
2 | *.iml
3 | *.ipr
4 | *.iws
5 | .idea
6 | .classpath
7 | .project
8 | .settings
9 | .DS_Store
10 |
--------------------------------------------------------------------------------
/blog/migration-bpmn/process_v1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/blog/migration-bpmn/process_v1.png
--------------------------------------------------------------------------------
/blog/migration-bpmn/process_v4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/blog/migration-bpmn/process_v4.png
--------------------------------------------------------------------------------
/flowable-intro/README.md:
--------------------------------------------------------------------------------
1 | See this [blogpost](http://bpmn20inaction.blogspot.com/2016/12/coding-introduction-with-flowable-6.html) for more details.
--------------------------------------------------------------------------------
/flowable-kafka/frontend/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/flowable-kafka/frontend/public/favicon.ico
--------------------------------------------------------------------------------
/flowable-kafka/frontend/public/logo192.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/flowable-kafka/frontend/public/logo192.png
--------------------------------------------------------------------------------
/flowable-kafka/frontend/public/logo512.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/flowable-kafka/frontend/public/logo512.png
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/src/test/resources/application-test.properties:
--------------------------------------------------------------------------------
1 | spring.datasource.url=jdbc:h2:mem:flowable-flowfest-db;DB_CLOSE_DELAY=1000;MVCC=TRUE
--------------------------------------------------------------------------------
/blog/demystifying-asynchronous-flag/Async Demo App.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/blog/demystifying-asynchronous-flag/Async Demo App.zip
--------------------------------------------------------------------------------
/flowable-kafka/frontend/.prettierrc:
--------------------------------------------------------------------------------
1 | {
2 | "printWidth": 130,
3 | "tabWidth": 2,
4 | "useTabs": false,
5 | "jsxBracketSameLine": true,
6 | "singleQuote": true
7 | }
8 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-decision-analysis/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | server.port=8083
2 | management.security.enabled=false\
3 |
4 | spring.banner.location=flowable-banner.txt
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/.mvn/wrapper/maven-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/flowfest-2018/demo-own-application/.mvn/wrapper/maven-wrapper.jar
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/.mvn/wrapper/maven-wrapper.properties:
--------------------------------------------------------------------------------
1 | distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.5.4/apache-maven-3.5.4-bin.zip
2 |
--------------------------------------------------------------------------------
/blog/2022-02-flowable-spring-native/.mvn/wrapper/maven-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/blog/2022-02-flowable-spring-native/.mvn/wrapper/maven-wrapper.jar
--------------------------------------------------------------------------------
/blog/2022-11-ms-exchange-online-modern-auth/.mvn/wrapper/maven-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/blog/2022-11-ms-exchange-online-modern-auth/.mvn/wrapper/maven-wrapper.jar
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/dashBoard.scss:
--------------------------------------------------------------------------------
1 | .flw-dashBoard {
2 | padding: 50px;
3 | display: grid;
4 | grid-template-columns: repeat(2, 40%);
5 | grid-gap: 30px;
6 | grid-auto-rows: repeat(2, auto);
7 | }
--------------------------------------------------------------------------------
/demo/demo-introducing-machine-learning/demo-process/src/main/resources/loan.bar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/demo/demo-introducing-machine-learning/demo-process/src/main/resources/loan.bar
--------------------------------------------------------------------------------
/async-history/async-history-default-cfg/src/main/resources/diagrams/default-history.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/async-history/async-history-default-cfg/src/main/resources/diagrams/default-history.png
--------------------------------------------------------------------------------
/demo/demo-introducing-machine-learning/README.md:
--------------------------------------------------------------------------------
1 | Code for the Devoxx 2017 demo.
2 |
3 | Following servers should be installed (all simply by unzipping and starting with defaults):
4 |
5 | * RabbitMQ
6 | * Elasticsearch
7 | * Spark
8 |
--------------------------------------------------------------------------------
/async-history/async-history-default-cfg/src/main/resources/diagrams/async-history-default.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/async-history/async-history-default-cfg/src/main/resources/diagrams/async-history-default.png
--------------------------------------------------------------------------------
/async-history/async-history-jms-jta-cfg/src/main/resources/diagrams/async-history-jms-jta.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/async-history/async-history-jms-jta-cfg/src/main/resources/diagrams/async-history-jms-jta.png
--------------------------------------------------------------------------------
/async-history/async-history-default-cfg/src/main/resources/diagrams/async-history-default2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/async-history/async-history-default-cfg/src/main/resources/diagrams/async-history-default2.png
--------------------------------------------------------------------------------
/async-history/async-history-rabbitmq-cfg/src/main/resources/diagrams/async-history-rabbitmq.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/async-history/async-history-rabbitmq-cfg/src/main/resources/diagrams/async-history-rabbitmq.png
--------------------------------------------------------------------------------
/blog/04-2021-flowable-spring-boot-native/src/main/resources/META-INF/native-image/resource-config.json:
--------------------------------------------------------------------------------
1 | {
2 | "resources": {
3 | "includes": [
4 | {"pattern": ".*flowable.*xml$"},
5 | {"pattern": ".*flowable.*sql$"}
6 | ]
7 | }
8 | }
--------------------------------------------------------------------------------
/demo/demo-introducing-machine-learning/demo-listener/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | server.port=8082
2 | spring.boot.admin.url=http://localhost:8080
3 | spring.boot.admin.client.name=History to Elasticsearch
4 | management.security.enabled=false
--------------------------------------------------------------------------------
/async-history/async-history-jms-cfg/src/main/resources/diagrams/async-history-message-queue-custom.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/async-history/async-history-jms-cfg/src/main/resources/diagrams/async-history-message-queue-custom.png
--------------------------------------------------------------------------------
/async-history/async-history-jms-cfg/src/main/resources/diagrams/async-history-message-queue-default.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/flowable/flowable-examples/HEAD/async-history/async-history-jms-cfg/src/main/resources/diagrams/async-history-message-queue-default.png
--------------------------------------------------------------------------------
/blog/04-2021-flowable-spring-boot-native/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | spring.datasource.url=jdbc:postgresql://localhost/nativetest
2 | spring.datasource.username=flowable
3 | spring.datasource.password=flowable
4 |
5 | flowable.database-schema-update=none
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-sentiment-analysis-app/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | server.port=8085
2 | spring.kafka.consumer.group-id=consumer-group-1
3 | spring.kafka.consumer.auto-offset-reset=earliest
4 | spring.kafka.listener.missing-topics-fatal=false
--------------------------------------------------------------------------------
/blog/2022-02-flowable-spring-native/src/main/resources/META-INF/spring.factories:
--------------------------------------------------------------------------------
1 | org.springframework.nativex.type.NativeConfiguration=\
2 | org.flowable.spring.nativex.hints.FlowableProcessEngineNativeConfiguration,\
3 | io.cloudnativejava.liquibase.LiquibaseNativeConfiguration
4 |
--------------------------------------------------------------------------------
/demo/demo-introducing-machine-learning/demo-decision-analysis/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | server.port=8083
2 | spring.boot.admin.url=http://localhost:8080
3 | spring.boot.admin.client.name=Decision Analysis
4 | management.security.enabled=false
5 |
6 | liquibase.enabled=false
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/stationsMap.scss:
--------------------------------------------------------------------------------
1 | .flw-inMap-form.flw-stationMap-form {
2 | position: relative;
3 | bottom: 0;
4 | right: 0;
5 | width: 250px;
6 | padding: 10px;
7 | box-shadow: none;
8 | .flw-stationMap-form__input textarea {
9 | height: 50px;
10 | }
11 | }
--------------------------------------------------------------------------------
/async-history/async-history-jms-cfg/src/main/resources/log4j.properties:
--------------------------------------------------------------------------------
1 | log4j.rootLogger=INFO, CA
2 |
3 | # ConsoleAppender
4 | log4j.appender.CA=org.apache.log4j.ConsoleAppender
5 | log4j.appender.CA.layout=org.apache.log4j.PatternLayout
6 | log4j.appender.CA.layout.ConversionPattern= %d{hh:mm:ss,SSS} [%t] %-5p %c %x - %m%n
7 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-hello-world/src/main/resources/log4j.properties:
--------------------------------------------------------------------------------
1 | log4j.rootLogger=INFO, CA
2 |
3 | # ConsoleAppender
4 | log4j.appender.CA=org.apache.log4j.ConsoleAppender
5 | log4j.appender.CA.layout=org.apache.log4j.PatternLayout
6 | log4j.appender.CA.layout.ConversionPattern= %d{hh:mm:ss,SSS} [%t] %-5p %c %x - %m%n
7 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-process-mongo/src/main/resources/log4j.properties:
--------------------------------------------------------------------------------
1 | log4j.rootLogger=INFO, CA
2 |
3 | # ConsoleAppender
4 | log4j.appender.CA=org.apache.log4j.ConsoleAppender
5 | log4j.appender.CA.layout=org.apache.log4j.PatternLayout
6 | log4j.appender.CA.layout.ConversionPattern= %d{hh:mm:ss,SSS} [%t] %-5p %c %x - %m%n
7 |
--------------------------------------------------------------------------------
/async-history/async-history-default-cfg/src/main/resources/log4j.properties:
--------------------------------------------------------------------------------
1 | log4j.rootLogger=INFO, CA
2 |
3 | # ConsoleAppender
4 | log4j.appender.CA=org.apache.log4j.ConsoleAppender
5 | log4j.appender.CA.layout=org.apache.log4j.PatternLayout
6 | log4j.appender.CA.layout.ConversionPattern= %d{hh:mm:ss,SSS} [%t] %-5p %c %x - %m%n
7 |
--------------------------------------------------------------------------------
/async-history/async-history-jms-jta-cfg/src/main/resources/log4j.properties:
--------------------------------------------------------------------------------
1 | log4j.rootLogger=INFO, CA
2 |
3 | # ConsoleAppender
4 | log4j.appender.CA=org.apache.log4j.ConsoleAppender
5 | log4j.appender.CA.layout=org.apache.log4j.PatternLayout
6 | log4j.appender.CA.layout.ConversionPattern= %d{hh:mm:ss,SSS} [%t] %-5p %c %x - %m%n
7 |
--------------------------------------------------------------------------------
/async-history/async-history-rabbitmq-cfg/src/main/resources/log4j.properties:
--------------------------------------------------------------------------------
1 | log4j.rootLogger=INFO, CA
2 |
3 | # ConsoleAppender
4 | log4j.appender.CA=org.apache.log4j.ConsoleAppender
5 | log4j.appender.CA.layout=org.apache.log4j.PatternLayout
6 | log4j.appender.CA.layout.ConversionPattern= %d{hh:mm:ss,SSS} [%t] %-5p %c %x - %m%n
7 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-decision-analysis/src/main/resources/log4j.properties:
--------------------------------------------------------------------------------
1 | log4j.rootLogger=INFO, CA
2 |
3 | # ConsoleAppender
4 | log4j.appender.CA=org.apache.log4j.ConsoleAppender
5 | log4j.appender.CA.layout=org.apache.log4j.PatternLayout
6 | log4j.appender.CA.layout.ConversionPattern= %d{hh:mm:ss,SSS} [%t] %-5p %c %x - %m%n
7 |
--------------------------------------------------------------------------------
/blog/migration-bpmn/src/main/java/com/example/reservation/app/migration/MigrationReservationService.java:
--------------------------------------------------------------------------------
1 | package com.example.reservation.app.migration;
2 |
3 | /**
4 | * @author Simon Amport
5 | */
6 | public interface MigrationReservationService {
7 |
8 | void migrateProcessInstancesToLatestDefinition();
9 |
10 | }
11 |
--------------------------------------------------------------------------------
/demo/demo-introducing-machine-learning/demo-process/src/main/resources/log4j.properties:
--------------------------------------------------------------------------------
1 | log4j.rootLogger=INFO, CA
2 |
3 | # ConsoleAppender
4 | log4j.appender.CA=org.apache.log4j.ConsoleAppender
5 | log4j.appender.CA.layout=org.apache.log4j.PatternLayout
6 | log4j.appender.CA.layout.ConversionPattern= %d{hh:mm:ss,SSS} [%t] %-5p %c %x - %m%n
7 |
--------------------------------------------------------------------------------
/blog/migration-bpmn/src/main/java/com/example/reservation/app/service/ReservationService.java:
--------------------------------------------------------------------------------
1 | package com.example.reservation.app.service;
2 |
3 | /**
4 | * @author Simon Amport
5 | */
6 | public interface ReservationService {
7 |
8 | void reserveTable();
9 |
10 | void releaseTable();
11 |
12 | boolean showUp();
13 |
14 | }
15 |
--------------------------------------------------------------------------------
/demo/demo-introducing-machine-learning/demo-decision-analysis/src/main/resources/log4j.properties:
--------------------------------------------------------------------------------
1 | log4j.rootLogger=INFO, CA
2 |
3 | # ConsoleAppender
4 | log4j.appender.CA=org.apache.log4j.ConsoleAppender
5 | log4j.appender.CA.layout=org.apache.log4j.PatternLayout
6 | log4j.appender.CA.layout.ConversionPattern= %d{hh:mm:ss,SSS} [%t] %-5p %c %x - %m%n
7 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-customer-case-app/src/main/resources/eventregistry/channel-sentimentAnalysisOutboundChannel.channel:
--------------------------------------------------------------------------------
1 | {
2 | "type": "kafka",
3 | "channelType": "outbound",
4 | "serializerType": "json",
5 | "topic": "sentiment-analysis",
6 | "name": "Sentiment Analysis Outbound Channel",
7 | "key": "sentimentAnalysisOutboundChannel"
8 | }
--------------------------------------------------------------------------------
/blog/2022-02-flowable-spring-native/src/test/java/com/example/demo/DemoApplicationTests.java:
--------------------------------------------------------------------------------
1 | package com.example.demo;
2 |
3 | import org.junit.jupiter.api.Test;
4 | import org.springframework.boot.test.context.SpringBootTest;
5 |
6 | @SpringBootTest
7 | class DemoApplicationTests {
8 |
9 | @Test
10 | void contextLoads() {
11 | }
12 |
13 | }
14 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-process-mongo/src/main/resources/demo-app/form-name.form:
--------------------------------------------------------------------------------
1 | {"name":"Get name","key":"name","version":0,"fields":[{"fieldType":"FormField","id":"fullname","name":"Fullname","type":"text","value":null,"required":true,"readOnly":false,"overrideId":false,"placeholder":"Please enter the full name of the applicant...","layout":null}],"outcomes":[]}
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-sentiment-analysis-app/src/main/resources/eventregistry/channel-sentimentAnalysisResultOutboundChannel.channel:
--------------------------------------------------------------------------------
1 | {
2 | "type": "kafka",
3 | "channelType": "outbound",
4 | "serializerType": "xml",
5 | "topic": "sentiment-analysis-results",
6 | "name": "Sentiment Analysis Result Outbound Channel",
7 | "key": "sentimentAnalysisResultOutboundChannel"
8 | }
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/src/test/java/com/example/demoflowfest/DemoFlowfestApplicationTests.java:
--------------------------------------------------------------------------------
1 | package com.example.demoflowfest;
2 |
3 | import org.junit.jupiter.api.Test;
4 | import org.springframework.boot.test.context.SpringBootTest;
5 |
6 | @SpringBootTest
7 | class DemoFlowfestApplicationTests {
8 |
9 | @Test
10 | void contextLoads() {
11 | }
12 |
13 | }
14 |
--------------------------------------------------------------------------------
/blog/migration-bpmn/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | # General server settings
2 | server.port=8090
3 | server.servlet.context-path=/blog-bpmn-migration
4 |
5 | # Datasource
6 | spring.datasource.url=jdbc:h2:~/flowable-db/flowable-blog-bpmn-migration-db;AUTO_SERVER=TRUE;AUTO_SERVER_PORT=9091;DB_CLOSE_DELAY=-1
7 | spring.datasource.username=flowable
8 | spring.datasource.password=flowable
--------------------------------------------------------------------------------
/demo/demo-introducing-machine-learning/demo-process/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | server.port=8081
2 | spring.boot.admin.url=http://localhost:8080
3 | spring.boot.admin.client.name=Process Application
4 | management.security.enabled=false
5 |
6 | # Workaround for a startup bug (liquibase on classpath (via the dmn engine) = spring boots expects a changelog file)
7 | liquibase.enabled=false
--------------------------------------------------------------------------------
/flowable-intro/src/main/resources/log4j.properties:
--------------------------------------------------------------------------------
1 | log4j.rootLogger=INFO, CA
2 |
3 | # ConsoleAppender
4 | log4j.appender.CA=org.apache.log4j.ConsoleAppender
5 | log4j.appender.CA.layout=org.apache.log4j.PatternLayout
6 | log4j.appender.CA.layout.ConversionPattern= %d{hh:mm:ss,SSS} [%t] %-5p %c %x - %m%n
7 |
8 |
9 | log4j.logger.org.apache.ibatis.level=WARN
10 | log4j.logger.javax.activation.level=INFO
11 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-common/src/main/java/org/flowable/eventdemo/constant/KafkaTopicConstants.java:
--------------------------------------------------------------------------------
1 | package org.flowable.eventdemo.constant;
2 |
3 | public interface KafkaTopicConstants {
4 |
5 | String TOPIC_REVIEWS = "reviews";
6 |
7 | String TOPIC_SENTIMENT_ANALYSIS = "sentiment-analysis";
8 |
9 | String TOPIC_SENTIMENT_ANALYSIS_RESULT = "sentiment-analysis-results";
10 |
11 | }
12 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-customer-case-app/src/main/resources/eventregistry/channel-reviewInboundChannel.channel:
--------------------------------------------------------------------------------
1 | {
2 | "type": "kafka",
3 | "channelType": "inbound",
4 | "deserializerType": "json",
5 | "topics": [
6 | "reviews"
7 | ],
8 | "channelEventKeyDetection": {
9 | "fixedValue": "reviewEvent"
10 | },
11 | "name": "Review Inbound Channel",
12 | "key": "reviewInboundChannel"
13 | }
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-sentiment-analysis-app/src/main/resources/eventregistry/event-sentimentAnalysisEvent.event:
--------------------------------------------------------------------------------
1 | {
2 | "correlationParameters": [],
3 | "payload": [
4 | {
5 | "name": "userId",
6 | "type": "string"
7 | },
8 | {
9 | "name": "comment",
10 | "type": "string"
11 | }
12 | ],
13 | "name": "Sentiment Analysis Event",
14 | "key": "sentimentAnalysisEvent"
15 | }
--------------------------------------------------------------------------------
/blog/2022-02-flowable-spring-native/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | spring.datasource.url=jdbc:postgresql:native
2 | spring.datasource.user=flowable
3 | spring.datasource.passwords=flowable
4 |
5 | # Disable liquibase because of:
6 | # Error creating bean with name 'dataSourceScriptDatabaseInitializer': Circular depends-on relationship between 'dataSourceScriptDatabaseInitializer' and 'liquibase'
7 | spring.liquibase.enabled=false
8 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/.gitignore:
--------------------------------------------------------------------------------
1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2 |
3 | # dependencies
4 | /node_modules
5 | /.pnp
6 | .pnp.js
7 |
8 | # testing
9 | /coverage
10 |
11 | # production
12 | /build
13 |
14 | # misc
15 | .DS_Store
16 | .env.local
17 | .env.development.local
18 | .env.test.local
19 | .env.production.local
20 |
21 | npm-debug.log*
22 | yarn-debug.log*
23 | yarn-error.log*
24 |
--------------------------------------------------------------------------------
/blog/migration-bpmn/readme.md:
--------------------------------------------------------------------------------
1 | ### Migration of a BPMN process
2 |
3 | In this Spring Boot (v2.1.6.RELEASE) project we migrate a Flowable BPMN process with Flowable OSS (v6.4.1). The use case is a simple restaurant reservation process.
4 |
5 |
6 | old process model:
7 |
8 | 
9 |
10 | new process model:
11 |
12 | 
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-customer-case-app/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | server.port=8123
2 |
3 | spring.datasource.url=jdbc:postgresql://localhost/eventdemo
4 | spring.datasource.username=flowable
5 | spring.datasource.password=flowable
6 | spring.datasource.driver-class-name=org.postgresql.Driver
7 |
8 | spring.kafka.consumer.group-id=consumer-group-1
9 | spring.kafka.consumer.auto-offset-reset=earliest
10 | spring.kafka.listener.missing-topics-fatal=false
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-sentiment-analysis-app/src/main/resources/eventregistry/channel-sentimentAnalysisInboundChannel.channel:
--------------------------------------------------------------------------------
1 | {
2 | "type": "kafka",
3 | "channelType": "inbound",
4 | "deserializerType": "json",
5 | "topics": [
6 | "sentiment-analysis"
7 | ],
8 | "channelEventKeyDetection": {
9 | "fixedValue": "sentimentAnalysisEvent"
10 | },
11 | "name": "Sentiment Analysis Inbound Channel",
12 | "key": "sentimentAnalysisInboundChannel"
13 | }
--------------------------------------------------------------------------------
/async-history/README.md:
--------------------------------------------------------------------------------
1 | Root project for various Async History configuration examples:
2 |
3 | * [Enabling Async History and using the default Async History executor](async-history-default-cfg/)
4 | * [Using Async History in combination with a Message Queue (JMS)](async-history-jms-cfg)
5 | * [Using Async History with a Message Queue (JMS) and JTA](async-history-jms-jta-cfg)
6 | * [Using Async History with RabbitMQ and Spring Boot message listener application](async-history-rabbitmq-cfg)
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-customer-case-app/src/main/resources/eventregistry/channel-sentimentAnalysisResultChannel.channel:
--------------------------------------------------------------------------------
1 | {
2 | "type": "kafka",
3 | "channelType": "inbound",
4 | "deserializerType": "xml",
5 | "topics": [
6 | "sentiment-analysis-results"
7 | ],
8 | "channelEventKeyDetection": {
9 | "fixedValue": "sentimentAnalysisResultEvent"
10 | },
11 | "name": "Sentiment Analysis Result Channel",
12 | "key": "sentimentAnalysisResultChannel"
13 | }
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/commentMarker.scss:
--------------------------------------------------------------------------------
1 | .flw-commentMarker {
2 | display: flex;
3 | flex-direction: column;
4 | padding: 5px;
5 | color: gray;
6 | max-width: 200px;
7 | &__content {
8 | margin-bottom: 10px;
9 | display: flex;
10 | flex-direction: row;
11 | &__user {
12 | font-size: 16px;
13 | font-weight: 500;
14 | margin: 0 10px 10px;
15 | }
16 | &__comment {
17 | word-break: break-word;
18 | }
19 | }
20 | }
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-api-gateway/src/main/java/org/flowable/eventdemo/ApiGatewayApplication.java:
--------------------------------------------------------------------------------
1 | package org.flowable.eventdemo;
2 |
3 | import org.springframework.boot.SpringApplication;
4 | import org.springframework.boot.autoconfigure.SpringBootApplication;
5 |
6 | @SpringBootApplication
7 | public class ApiGatewayApplication {
8 |
9 | public static void main(String[] args) {
10 | SpringApplication.run(ApiGatewayApplication.class, args);
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/rating.scss:
--------------------------------------------------------------------------------
1 | .flw-rating {
2 | display: flex;
3 | flex-direction: row;
4 | margin: 0 10px 0 10px;
5 | .flw-star {
6 | width: 15px;
7 | height: 15px;
8 | background-color: #E8EAED;
9 | clip-path: polygon( 50% 0%, 63% 38%, 100% 38%, 69% 59%, 82% 100%, 50% 75%, 18% 100%, 31% 59%, 0% 38%, 37% 38% );
10 | &.selected {
11 | background-color: #FBBC04;
12 | }
13 | &.enabled {
14 | cursor: pointer;
15 | }
16 | }
17 | }
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/GlobalStyle.ts:
--------------------------------------------------------------------------------
1 | import { createGlobalStyle } from 'styled-components';
2 |
3 | export const GlobalStyles = createGlobalStyle`
4 | body {
5 | background: ${({ theme }: any) => theme.bodyBackground};
6 | color: ${({ theme }: any) => theme.bodyColor};
7 | transition: all 0.25s linear;
8 | }
9 | .body-bg {
10 | background: #F3F4FA !important;
11 | }
12 |
13 | h1, h2, h3, h4, h5, h6, strong {
14 | font-weight: 600;
15 | }
16 | `;
17 |
--------------------------------------------------------------------------------
/spring-boot-example/README.md:
--------------------------------------------------------------------------------
1 | Example project for using the Flowable starters with Spring boot.
2 | It automatically deploys all process and cases from the `processes` and `cases` folders respectively.
3 | Exposes the REST endpoints for the 6 engines of Flowable:
4 | * `process-api` for the Process Engine
5 | * `cmmn-api` for the CMMN Engine
6 | * `dmn-api` for the DMN Engine
7 | * `idm-api` for the IDM Engine
8 | * `form-api` for the Form Engine
9 | * `content-api` for the Content Engine
10 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-sentiment-analysis-app/src/main/java/org/flowable/eventdemo/service/RandomSentimentService.java:
--------------------------------------------------------------------------------
1 | package org.flowable.eventdemo.service;
2 |
3 | import java.util.Random;
4 |
5 | import org.springframework.stereotype.Service;
6 |
7 | @Service
8 | public class RandomSentimentService {
9 |
10 | private Random random = new Random();
11 |
12 | public String generator() {
13 | return random.nextBoolean() ? "negative" : "positive";
14 | }
15 |
16 | }
17 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-customer-case-app/src/main/resources/eventregistry/event-sentimentAnalysisEvent.event:
--------------------------------------------------------------------------------
1 | {
2 | "correlationParameters": [],
3 | "payload": [
4 | {
5 | "name": "userId",
6 | "type": "string"
7 | },
8 | {
9 | "name": "comment",
10 | "type": "string"
11 | }
12 | ],
13 | "name": "Sentiment Analysis Event",
14 | "key": "sentimentAnalysisEvent",
15 | "outboundChannelKeys": [
16 | "sentimentAnalysisOutboundChannel"
17 | ]
18 | }
--------------------------------------------------------------------------------
/blog/migration-bpmn/src/main/java/com/example/reservation/app/ReservationApplication.java:
--------------------------------------------------------------------------------
1 | package com.example.reservation.app;
2 |
3 | import org.springframework.boot.SpringApplication;
4 | import org.springframework.boot.autoconfigure.SpringBootApplication;
5 |
6 | /**
7 | * @author Simon Amport
8 | */
9 | @SpringBootApplication
10 | public class ReservationApplication {
11 |
12 | public static void main(String[] args) {
13 | SpringApplication.run(ReservationApplication.class, args);
14 | }
15 |
16 | }
--------------------------------------------------------------------------------
/blog/migration-bpmn/src/test/resources/application.properties:
--------------------------------------------------------------------------------
1 | # Datasource
2 | spring.datasource.url=jdbc:h2:mem:flowable-blog-bpmn-migration-db;DB_CLOSE_DELAY=1000;MVCC=TRUE
3 | spring.datasource.username=sa
4 | spring.datasource.password=
5 |
6 | # Email
7 | flowable.mail.server.host=
8 | flowable.mail.server.port=
9 | flowable.mail.server.username=
10 | flowable.mail.server.password=
11 | flowable.mail.server.use-ssl=
12 | flowable.mail.server.use-tls=
13 | flowable.mail.server.force-to=
14 | flowable.mail.server.default-from=
15 |
--------------------------------------------------------------------------------
/spring-boot-example/src/main/resources/cases/one-task-model.cmmn:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/avatar.scss:
--------------------------------------------------------------------------------
1 | .flw-avatar {
2 | $size: 36px;
3 | margin: 5px 0;
4 | color: White;
5 | background-color: blue;
6 | display: block;
7 | height: $size;
8 | width: $size;
9 | border-radius: 50%;
10 | line-height: $size;
11 | text-align: center;
12 | font-size: 14px;
13 | font-weight: 400;
14 | img { display: none; }
15 | &--image {
16 | img {
17 | width: $size;
18 | height: $size;
19 | display: block;
20 | border-radius: 50px;
21 | }
22 | background: transparent;
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/blog/2022-02-flowable-spring-native/src/main/java/io/cloudnativejava/HintsUtils.java:
--------------------------------------------------------------------------------
1 | package io.cloudnativejava;
2 |
3 | import org.springframework.util.ClassUtils;
4 |
5 | public abstract class HintsUtils {
6 |
7 | public static boolean isClassPresent(String className) {
8 | return ClassUtils.isPresent(className, HintsUtils.class.getClassLoader());
9 | }
10 |
11 | public static Class> classForName(String clazzName) {
12 | try {
13 | return Class.forName(clazzName);
14 | } //
15 | catch (Exception e) {
16 | return null;
17 | }
18 |
19 | }
20 |
21 | }
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/model.ts:
--------------------------------------------------------------------------------
1 | export type FitBounds = [[number, number], [number, number]];
2 |
3 | export type Comment = {
4 | id: string;
5 | user: string;
6 | station?: number;
7 | rating: number;
8 | comment?: string;
9 | avatarUrl?: string;
10 | };
11 |
12 | export type MarkerProps = {
13 | id: number;
14 | coordinates: number[];
15 | comment: Comment;
16 | };
17 |
18 | export type FormData = {
19 | user: string;
20 | rating: number;
21 | comment: string;
22 | };
23 |
24 | export type SettingsData = {
25 | speed: string;
26 | }
27 |
--------------------------------------------------------------------------------
/blog/2022-02-flowable-spring-native/.gitignore:
--------------------------------------------------------------------------------
1 | HELP.md
2 | target/
3 | !.mvn/wrapper/maven-wrapper.jar
4 | !**/src/main/**/target/
5 | !**/src/test/**/target/
6 |
7 | ### STS ###
8 | .apt_generated
9 | .classpath
10 | .factorypath
11 | .project
12 | .settings
13 | .springBeans
14 | .sts4-cache
15 |
16 | ### IntelliJ IDEA ###
17 | .idea
18 | *.iws
19 | *.iml
20 | *.ipr
21 |
22 | ### NetBeans ###
23 | /nbproject/private/
24 | /nbbuild/
25 | /dist/
26 | /nbdist/
27 | /.nb-gradle/
28 | build/
29 | !**/src/main/**/build/
30 | !**/src/test/**/build/
31 |
32 | ### VS Code ###
33 | .vscode/
34 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/settings.ts:
--------------------------------------------------------------------------------
1 | import ReactMapboxGl from 'react-mapbox-gl';
2 | import { FitBounds } from './model';
3 |
4 | export const Mapbox = ReactMapboxGl({
5 | minZoom: 8,
6 | maxZoom: 15,
7 | doubleClickZoom: false,
8 | touchZoomRotate: false,
9 | accessToken: 'pk.eyJ1IjoiamNhc2FscnVpeiIsImEiOiJjazJkNWk5cjgwc29kM2hwNDBhZDl2a3AxIn0.aDwI1MEYvA_swKkLYIMXbA'
10 | });
11 |
12 | export const flyToOptions = {
13 | speed: 0.8
14 | };
15 |
16 | export const maxBounds = [[-0.481747846041145, 51.3233379650232], [0.23441119994140536, 51.654967740310525]] as FitBounds;
17 |
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/src/main/java/com/example/demoflowfest/HelloController.java:
--------------------------------------------------------------------------------
1 | package com.example.demoflowfest;
2 |
3 | import java.security.Principal;
4 |
5 | import org.springframework.web.bind.annotation.GetMapping;
6 | import org.springframework.web.bind.annotation.RestController;
7 |
8 | /**
9 | * @author Filip Hrisafov
10 | */
11 | @RestController
12 | public class HelloController {
13 |
14 | @GetMapping("/hello")
15 | public String hello(Principal principal) {
16 | return "Hello " + principal.getName() + ", welcome FlowFest 2018";
17 | }
18 |
19 | }
20 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-customer-case-app/src/main/resources/eventregistry/event-reviewEvent.event:
--------------------------------------------------------------------------------
1 | {
2 | "correlationParameters": [
3 | {
4 | "name": "userId",
5 | "type": "string"
6 | }
7 | ],
8 | "payload": [
9 | {
10 | "name": "userId",
11 | "type": "string"
12 | },
13 | {
14 | "name": "stationId",
15 | "type": "integer"
16 | },
17 | {
18 | "name": "rating",
19 | "type": "integer"
20 | },
21 | {
22 | "name": "comment",
23 | "type": "string"
24 | }
25 | ],
26 | "name": "Review Event",
27 | "key": "reviewEvent"
28 | }
--------------------------------------------------------------------------------
/flowable-kafka/frontend/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "target": "es5",
4 | "lib": [
5 | "dom",
6 | "dom.iterable",
7 | "esnext"
8 | ],
9 | "allowJs": true,
10 | "skipLibCheck": true,
11 | "esModuleInterop": true,
12 | "allowSyntheticDefaultImports": true,
13 | "strict": true,
14 | "forceConsistentCasingInFileNames": true,
15 | "module": "esnext",
16 | "moduleResolution": "node",
17 | "resolveJsonModule": true,
18 | "isolatedModules": true,
19 | "noEmit": true,
20 | "jsx": "react"
21 | },
22 | "include": [
23 | "src"
24 | ]
25 | }
26 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/public/manifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "short_name": "React App",
3 | "name": "Create React App Sample",
4 | "icons": [
5 | {
6 | "src": "favicon.ico",
7 | "sizes": "64x64 32x32 24x24 16x16",
8 | "type": "image/x-icon"
9 | },
10 | {
11 | "src": "logo192.png",
12 | "type": "image/png",
13 | "sizes": "192x192"
14 | },
15 | {
16 | "src": "logo512.png",
17 | "type": "image/png",
18 | "sizes": "512x512"
19 | }
20 | ],
21 | "start_url": ".",
22 | "display": "standalone",
23 | "theme_color": "#000000",
24 | "background_color": "#ffffff"
25 | }
26 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/index.css:
--------------------------------------------------------------------------------
1 | html {
2 | height: 100%;
3 | }
4 | body {
5 | height: 100%;
6 | margin: 0;
7 | font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen",
8 | "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue",
9 | sans-serif;
10 | -webkit-font-smoothing: antialiased;
11 | -moz-osx-font-smoothing: grayscale;
12 | }
13 | span {
14 | position: relative;
15 | }
16 | #root {
17 | height: 100%;
18 | }
19 | code {
20 | font-family: source-code-pro, Menlo, Monaco, Consolas, "Courier New",
21 | monospace;
22 | }
23 | .mapboxgl-map {
24 | height: 100%;
25 | }
26 |
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/src/main/resources/application.properties:
--------------------------------------------------------------------------------
1 | spring.datasource.url=jdbc:h2:~/flowable-flowfest-db/db;AUTO_SERVER=TRUE;AUTO_SERVER_PORT=9091;DB_CLOSE_DELAY=-1
2 | spring.datasource.username=flowable
3 | spring.datasource.password=flowable
4 |
5 | # Health endpoint
6 | # When authorized the health endpoint will show all the information
7 | management.endpoint.health.show-details=when_authorized
8 | # Expose all actuator over the REST API
9 | management.endpoints.web.exposure.include=*
10 |
11 | # Use the Spring Security 5 Delegating Password encoder by default
12 | flowable.idm.password-encoder=spring_delegating
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/Switch.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 |
3 | import './switch.scss';
4 | type SwitchProps = {
5 | isOn: boolean;
6 | handleToggle: any;
7 | };
8 |
9 | export const Switch = (props: SwitchProps) => {
10 | return (
11 | <>
12 |
19 |
22 | >
23 | );
24 | };
25 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-customer-case-app/src/main/resources/eventregistry/event-sentimentAnalysisResultEvent.event:
--------------------------------------------------------------------------------
1 | {
2 | "correlationParameters": [
3 | {
4 | "name": "userId",
5 | "type": "string"
6 | },
7 | {
8 | "name": "comment",
9 | "type": "string"
10 | }
11 | ],
12 | "payload": [
13 | {
14 | "name": "userId",
15 | "type": "string"
16 | },
17 | {
18 | "name": "comment",
19 | "type": "string"
20 | },
21 | {
22 | "name": "sentiment",
23 | "type": "string"
24 | }
25 | ],
26 | "name": "Sentiment Analysis Result Event",
27 | "key": "sentimentAnalysisResultEvent"
28 | }
--------------------------------------------------------------------------------
/blog/2022-02-flowable-spring-native/src/main/java/com/example/demo/DemoDelegate.java:
--------------------------------------------------------------------------------
1 | package com.example.demo;
2 |
3 | import org.flowable.engine.delegate.DelegateExecution;
4 | import org.flowable.engine.delegate.JavaDelegate;
5 | import org.slf4j.Logger;
6 | import org.slf4j.LoggerFactory;
7 |
8 | /**
9 | * @author Filip Hrisafov
10 | * @author Joram Barrez
11 | */
12 | public class DemoDelegate implements JavaDelegate {
13 |
14 | protected final Logger logger = LoggerFactory.getLogger(getClass());
15 |
16 | @Override
17 | public void execute(DelegateExecution execution) {
18 | logger.info("Hello " + execution.getVariable("user"));
19 | }
20 | }
21 |
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/src/main/java/com/example/demoflowfest/vacation/ConfirmationService.java:
--------------------------------------------------------------------------------
1 | package com.example.demoflowfest.vacation;
2 |
3 | import org.slf4j.Logger;
4 | import org.slf4j.LoggerFactory;
5 | import org.springframework.stereotype.Service;
6 |
7 | /**
8 | * @author Filip Hrisafov
9 | */
10 | @Service
11 | public class ConfirmationService {
12 |
13 | private static final Logger LOGGER = LoggerFactory.getLogger(ConfirmationService.class);
14 |
15 | public void confirm(String employeeName, int numberOfDays) {
16 | LOGGER.info("Vacation request for {} for {} days was confirmed", employeeName, numberOfDays);
17 | }
18 |
19 | }
20 |
--------------------------------------------------------------------------------
/flowable-intro/src/main/resources/intro.bpmn20.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/blog/04-2021-flowable-spring-boot-native/src/main/resources/org/flowable/test.bpmn20.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
7 | This is a process for testing purposes
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/README.md:
--------------------------------------------------------------------------------
1 | # City bikes
2 |
3 | A map of London Cycle stations With users comments
4 |
5 | ### `yarn start`
6 |
7 | Runs the app in development mode.
8 | Open [http://localhost:3000](http://localhost:3000) to view it in the browser.
9 |
10 | The page will automatically reload if you make changes to the code.
11 | You will see the build errors and lint warnings in the console.
12 |
13 | ### `yarn build`
14 |
15 | Builds the app for production to the `build` folder.
16 | It correctly bundles React in production mode and optimizes the build for the best performance.
17 |
18 | The build is minified and the filenames include the hashes.
19 |
20 | Your app is ready to be deployed in the static resource folder.
21 |
22 |
--------------------------------------------------------------------------------
/blog/2022-02-flowable-spring-native/src/main/resources/processes/oneTaskProcess.bpmn20.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-sentiment-analysis-app/src/main/resources/eventregistry/event-sentimentAnalysisResultEvent.event:
--------------------------------------------------------------------------------
1 | {
2 | "correlationParameters": [
3 | {
4 | "name": "userId",
5 | "type": "string"
6 | },
7 | {
8 | "name": "comment",
9 | "type": "string"
10 | }
11 | ],
12 | "payload": [
13 | {
14 | "name": "userId",
15 | "type": "string"
16 | },
17 | {
18 | "name": "comment",
19 | "type": "string"
20 | },
21 | {
22 | "name": "sentiment",
23 | "type": "string"
24 | }
25 | ],
26 | "name": "Sentiment Analysis Result Event",
27 | "key": "sentimentAnalysisResultEvent",
28 | "outboundChannelKeys": [
29 | "sentimentAnalysisResultOutboundChannel"
30 | ]
31 | }
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/Rating.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import classNames from 'classnames';
3 |
4 | import './rating.scss';
5 |
6 | var stars = new Array(5).fill(undefined);
7 |
8 | type RatingProps = {
9 | rate: number;
10 | onClick?: (rate: number) => void;
11 | };
12 |
13 | export const Rating = (props: RatingProps) => (
14 |
{stars.map((el, i) => renderStar(i, props.rate, props.onClick))}
15 | );
16 |
17 | const renderStar = (i: number, rate: number, onClick?: (rate: number) => void) => {
18 | const starClass = classNames('flw-star', {
19 | selected: i < rate,
20 | enabled: onClick
21 | });
22 |
23 | return onClick && onClick(i + 1)} />;
24 | };
25 |
--------------------------------------------------------------------------------
/blog/04-2021-jobs/src/main/resources/processes/async-job-noop.bpmn20.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/blog/2022-02-flowable-spring-native/src/main/resources/processes/oneServiceTaskDelegateProcess.bpmn20.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/blog/04-2021-jobs/src/main/resources/processes/async-job-wait-time.bpmn20.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/flowable-intro/src/main/resources/flowable.cfg.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/lineChart.scss:
--------------------------------------------------------------------------------
1 | .flw-lineChart {
2 | &.dark {
3 | background-color: #2F4562;
4 | .apexcharts-xaxistooltip {
5 | background: #1B213B;
6 | color: #fff;
7 | }
8 | text {
9 | fill: #fff;
10 | }
11 | }
12 |
13 | background-color: #dedede;
14 | .apexcharts-xaxistooltip {
15 | background: #fff;
16 | color: #363537;
17 | }
18 | text {
19 | fill: #363537;
20 | }
21 |
22 | padding: 25px 25px;
23 | border-radius: 4px;
24 | font-weight: bold;
25 | text {
26 | font-weight: 600;
27 | }
28 | }
29 |
30 | .columnbox {
31 | padding-right: 15px;
32 | }
33 | .radialbox {
34 | max-height: 333px;
35 | margin-bottom: 60px;
36 | }
37 |
38 | .apexcharts-legend-series tspan:nth-child(3) {
39 | font-weight: bold;
40 | font-size: 20px;
41 | }
--------------------------------------------------------------------------------
/flowable-kafka/frontend/.vscode/settings.json:
--------------------------------------------------------------------------------
1 | {
2 | "editor.insertSpaces": true,
3 | "editor.trimAutoWhitespace": true,
4 | "editor.tabSize": 2,
5 | "typescript.tsdk": "node_modules/typescript/lib",
6 | "editor.formatOnSave": true,
7 | "[scss]": {
8 | // We need a bit of work with prettier here, disabled for now
9 | "editor.formatOnSave": false
10 | },
11 | "[markdown]": {
12 | "editor.wordWrap": "on",
13 | "editor.quickSuggestions": false,
14 | "editor.formatOnSave": false
15 | },
16 | "files.associations": {
17 | ".prettierrc": "json",
18 | "*.ejs.t": "ejs"
19 | },
20 | "markdown-toc.depthFrom": 2,
21 | "eslint.validate": ["javascript", "javascriptreact", "typescript", "typescriptreact", "html"],
22 | "search.exclude": {
23 | "**/.yarn": true,
24 | "**/node": true
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/CommentMarker.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 |
3 | import { Comment } from './model';
4 | import { Avatar } from './Avatar';
5 | import { Rating } from './Rating';
6 | import './commentMarker.scss';
7 |
8 | export const CommentMarker = (props: Comment) => (
9 |
10 |
11 |
14 |
15 |
{props.user}
16 |
17 |
18 |
19 |
{props.comment}
20 |
21 | );
22 |
--------------------------------------------------------------------------------
/blog/2022-11-ms-exchange-online-modern-auth/readme.md:
--------------------------------------------------------------------------------
1 | # Blog Article
2 |
3 | [MS Office 365 Exchange OAuth2 IMAP Authentication with Flowable](https://www.flowable.com/blog/office-365-exchange-oauth2-imap-authentication?slug=blog/office-365-exchange-oauth2-imap-authentication)
4 |
5 | A simple [JBang-ready](https://www.jbang.dev/download/) testing tool, to test Microsoft Office 365 Exchange Online SMTP access with modern OAuth2-based authentication.
6 | ## Usage
7 |
8 | `$jbang src/main/java/org/flowable/example/blog/MsExchangeOnlineModernAuthTestCli.java
-c --cs -email `
9 |
10 | Or see [MsExchangeOnlineModernAuthCliTest.java](src/test/java/org/flowable/example/blog/MsExchangeOnlineModernAuthTestCliTest.java) to run the testing tool.
11 |
12 | ## Disclaimer
13 | No production-ready code. Treat it as example only.
--------------------------------------------------------------------------------
/blog/migration-bpmn/src/main/java/com/example/reservation/app/service/ReservationServiceImpl.java:
--------------------------------------------------------------------------------
1 | package com.example.reservation.app.service;
2 |
3 | import org.slf4j.Logger;
4 | import org.slf4j.LoggerFactory;
5 | import org.springframework.stereotype.Service;
6 |
7 | /**
8 | * @author Simon Amport
9 | */
10 | @Service("reservationService")
11 | public class ReservationServiceImpl implements ReservationService {
12 |
13 | private static final Logger LOGGER = LoggerFactory.getLogger(ReservationServiceImpl.class);
14 |
15 | @Override
16 | public void reserveTable() {
17 | LOGGER.info("Table reserved.");
18 | }
19 |
20 | @Override
21 | public void releaseTable() {
22 | LOGGER.info("Table released.");
23 | }
24 |
25 | @Override
26 | public boolean showUp() {
27 | return true;
28 | }
29 |
30 | }
31 |
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/src/main/java/com/example/demoflowfest/risk/RiskInput.java:
--------------------------------------------------------------------------------
1 | package com.example.demoflowfest.risk;
2 |
3 | /**
4 | * @author Filip Hrisafov
5 | */
6 | public class RiskInput {
7 |
8 | protected int age;
9 | protected String category;
10 | protected boolean debtReview;
11 |
12 | public int getAge() {
13 | return age;
14 | }
15 |
16 | public void setAge(int age) {
17 | this.age = age;
18 | }
19 |
20 | public String getCategory() {
21 | return category;
22 | }
23 |
24 | public void setCategory(String category) {
25 | this.category = category;
26 | }
27 |
28 | public boolean isDebtReview() {
29 | return debtReview;
30 | }
31 |
32 | public void setDebtReview(boolean debtReview) {
33 | this.debtReview = debtReview;
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/index.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom';
3 | import './index.css';
4 | import { StationsMapWithApi } from './StationsMapWithApi';
5 | import { DashBoard } from './DashBoard';
6 |
7 | import * as serviceWorker from './serviceWorker';
8 | import { HashRouter, Switch, Route } from 'react-router-dom';
9 |
10 | ReactDOM.render(
11 |
12 |
13 |
14 |
15 |
16 | ,
17 | document.getElementById('root')
18 | );
19 |
20 | // If you want your app to work offline and load faster, you can change
21 | // unregister() to register() below. Note this comes with some pitfalls.
22 | // Learn more about service workers: https://bit.ly/CRA-PWA
23 | serviceWorker.unregister();
24 |
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/src/main/java/com/example/demoflowfest/risk/RiskOutput.java:
--------------------------------------------------------------------------------
1 | package com.example.demoflowfest.risk;
2 | /**
3 | * @author Filip Hrisafov
4 | */
5 | public class RiskOutput {
6 |
7 | protected String routing;
8 | protected String reviewLevel;
9 | protected String reason;
10 |
11 | public String getRouting() {
12 | return routing;
13 | }
14 |
15 | public void setRouting(String routing) {
16 | this.routing = routing;
17 | }
18 |
19 | public String getReviewLevel() {
20 | return reviewLevel;
21 | }
22 |
23 | public void setReviewLevel(String reviewLevel) {
24 | this.reviewLevel = reviewLevel;
25 | }
26 |
27 | public String getReason() {
28 | return reason;
29 | }
30 |
31 | public void setReason(String reason) {
32 | this.reason = reason;
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/flowable-intro/src/main/resources/flowable5.cfg.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
--------------------------------------------------------------------------------
/flowable-intro/src/main/resources/dmn.bpmn20.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-review-app/src/main/java/org/flowable/eventdemo/review/ReviewController.java:
--------------------------------------------------------------------------------
1 | package org.flowable.eventdemo.review;
2 |
3 | import org.springframework.http.ResponseEntity;
4 | import org.springframework.web.bind.annotation.PostMapping;
5 | import org.springframework.web.bind.annotation.RequestBody;
6 | import org.springframework.web.bind.annotation.RestController;
7 |
8 | import reactor.core.publisher.Mono;
9 |
10 | @RestController
11 | public class ReviewController {
12 |
13 | private ReviewService reviewService;
14 |
15 | public ReviewController(ReviewService reviewService) {
16 | this.reviewService = reviewService;
17 | }
18 |
19 | @PostMapping(value = "/reviews")
20 | public Mono> processReview(@RequestBody String review) {
21 | return reviewService.sendReviewToKafka(review)
22 | .then(Mono.just(ResponseEntity.ok().build()));
23 | }
24 |
25 | }
26 |
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/src/main/java/com/example/demoflowfest/DemoFlowfestApplication.java:
--------------------------------------------------------------------------------
1 | package com.example.demoflowfest;
2 |
3 | import org.flowable.spring.SpringProcessEngineConfiguration;
4 | import org.flowable.spring.boot.EngineConfigurationConfigurer;
5 | import org.springframework.boot.SpringApplication;
6 | import org.springframework.boot.autoconfigure.SpringBootApplication;
7 | import org.springframework.context.annotation.Bean;
8 |
9 | @SpringBootApplication
10 | public class DemoFlowfestApplication {
11 |
12 | public static void main(String[] args) {
13 | SpringApplication.run(DemoFlowfestApplication.class, args);
14 | }
15 |
16 | @Bean
17 | public EngineConfigurationConfigurer customProcessEngineConfigurer() {
18 | return engineConfiguration -> {
19 | engineConfiguration.setValidateFlowable5EntitiesEnabled(false);
20 | };
21 | }
22 | }
23 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/switch.scss:
--------------------------------------------------------------------------------
1 | .flw-switch-checkbox {
2 | height: 0;
3 | width: 0;
4 | visibility: hidden;
5 | }
6 |
7 | .flw-switch-label {
8 | margin: 20px 0 0 50px;
9 | display: flex;
10 | align-items: center;
11 | justify-content: space-between;
12 | cursor: pointer;
13 | width: 50px;
14 | height: 25px;
15 | background: #2F4562;
16 | border-radius: 100px;
17 | position: relative;
18 | transition: background-color .2s;
19 | .flw-switch-button {
20 | content: '';
21 | position: absolute;
22 | top: 2px;
23 | left: 2px;
24 | width: 20px;
25 | height: 20px;
26 | border-radius: 45px;
27 | transition: 0.2s;
28 | background: #fff;
29 | box-shadow: 0 0 2px 0 rgba(10, 10, 10, 0.29);
30 | }
31 | }
32 |
33 | .flw-switch-checkbox:checked + .flw-switch-label{
34 | background: #dedede;
35 | .flw-switch-button {
36 | left: calc(100% - 2px);
37 | transform: translateX(-100%);
38 | }
39 | }
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-hello-world/src/main/resources/flowable-banner.txt:
--------------------------------------------------------------------------------
1 |
2 | ////////// &&&& &&& ,,, ,,,
3 | ////////////// &&&&&&& &&& ,,, ,,,
4 | /// /// &&& &&& ,,, ,,,
5 | //////// /// &&&&&&&& &&& &&&&&&& &&& &&& &&& ,,,,,,,,,, ,,,,,,,,, ,,, ,,,,,,,
6 | ////// // /// &&&&&&&& &&& &&&& &&&& &&& &&& &&& ,,, ,,,, ,,,, ,,,, ,,, ,,, ,,
7 | /// //// /// &&& &&& &&& &&& &&& &&& &&& ,, ,,, ,,, ,,, ,,, ,,,,,,,,,
8 | // ///// /// &&& &&& &&& &&&& &&& &&& &&& ,,, ,,,, ,,,, ,,, ,,, ,,,
9 | /////////// &&& &&& &&&&&&&& &&&&&&&&&&&&&& ,,,,,,,,,, ,,,,,,,, ,,, ,,,,,,,,
10 |
11 | :: Flowable :: JAX 2018 DEMO (process service) :: Spring Boot :: ${spring-boot.formatted-version}
12 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-process-mongo/src/main/resources/flowable-banner.txt:
--------------------------------------------------------------------------------
1 |
2 | ////////// &&&& &&& ,,, ,,,
3 | ////////////// &&&&&&& &&& ,,, ,,,
4 | /// /// &&& &&& ,,, ,,,
5 | //////// /// &&&&&&&& &&& &&&&&&& &&& &&& &&& ,,,,,,,,,, ,,,,,,,,, ,,, ,,,,,,,
6 | ////// // /// &&&&&&&& &&& &&&& &&&& &&& &&& &&& ,,, ,,,, ,,,, ,,,, ,,, ,,, ,,
7 | /// //// /// &&& &&& &&& &&& &&& &&& &&& ,, ,,, ,,, ,,, ,,, ,,,,,,,,,
8 | // ///// /// &&& &&& &&& &&&& &&& &&& &&& ,,, ,,,, ,,,, ,,, ,,, ,,,
9 | /////////// &&& &&& &&&&&&&& &&&&&&&&&&&&&& ,,,,,,,,,, ,,,,,,,, ,,, ,,,,,,,,
10 |
11 | :: Flowable :: JAX 2018 DEMO (process service) :: Spring Boot :: ${spring-boot.formatted-version}
12 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-decision-analysis/src/main/resources/flowable-banner.txt:
--------------------------------------------------------------------------------
1 |
2 | ////////// &&&& &&& ,,, ,,,
3 | ////////////// &&&&&&& &&& ,,, ,,,
4 | /// /// &&& &&& ,,, ,,,
5 | //////// /// &&&&&&&& &&& &&&&&&& &&& &&& &&& ,,,,,,,,,, ,,,,,,,,, ,,, ,,,,,,,
6 | ////// // /// &&&&&&&& &&& &&&& &&&& &&& &&& &&& ,,, ,,,, ,,,, ,,,, ,,, ,,, ,,
7 | /// //// /// &&& &&& &&& &&& &&& &&& &&& ,, ,,, ,,, ,,, ,,, ,,,,,,,,,
8 | // ///// /// &&& &&& &&& &&&& &&& &&& &&& ,,, ,,,, ,,,, ,,, ,,, ,,,
9 | /////////// &&& &&& &&&&&&&& &&&&&&&&&&&&&& ,,,,,,,,,, ,,,,,,,, ,,, ,,,,,,,,
10 |
11 | :: Flowable :: JAX 2018 DEMO (decision analysis service) :: Spring Boot :: ${spring-boot.formatted-version}
12 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-sentiment-analysis-app/src/main/java/org/flowable/eventdemo/sentiment/SentimentAnalysisApplication.java:
--------------------------------------------------------------------------------
1 | package org.flowable.eventdemo.sentiment;
2 |
3 | import org.flowable.eventdemo.service.RandomSentimentService;
4 | import org.flowable.eventdemo.service.SentimentService;
5 | import org.springframework.boot.SpringApplication;
6 | import org.springframework.boot.autoconfigure.SpringBootApplication;
7 | import org.springframework.context.annotation.Bean;
8 |
9 | @SpringBootApplication
10 | public class SentimentAnalysisApplication {
11 |
12 | public static void main(String[] args) {
13 | SpringApplication.run(SentimentAnalysisApplication.class, args);
14 | }
15 |
16 | @Bean
17 | public RandomSentimentService randomSentimentService() {
18 | return new RandomSentimentService();
19 | }
20 |
21 | @Bean
22 | public SentimentService sentimentService() {
23 | return new SentimentService();
24 | }
25 |
26 | }
27 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/quick-benchmark/src/main/java/org/flowable/delegate/NoopDelegate.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.delegate;
14 |
15 | import org.flowable.engine.delegate.DelegateExecution;
16 | import org.flowable.engine.delegate.JavaDelegate;
17 |
18 | public class NoopDelegate implements JavaDelegate {
19 |
20 | @Override
21 | public void execute(DelegateExecution delegateExecution) {
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-common/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 | eventbus-demo
7 | org.flowable
8 | 0.0.1-SNAPSHOT
9 |
10 | 4.0.0
11 |
12 | event-demo-common
13 |
14 |
15 |
16 | org.springframework.kafka
17 | spring-kafka
18 |
19 |
20 | org.flowable
21 | flowable-spring-boot-starter
22 | 6.5.0
23 |
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/src/main/java/com/example/demoflowfest/vacation/VacationRequestInput.java:
--------------------------------------------------------------------------------
1 | package com.example.demoflowfest.vacation;
2 |
3 | /**
4 | * @author Filip Hrisafov
5 | */
6 | public class VacationRequestInput {
7 |
8 | protected String employeeName;
9 | protected int numberOfDays;
10 | protected String vacationMotivation;
11 |
12 | public String getEmployeeName() {
13 | return employeeName;
14 | }
15 |
16 | public void setEmployeeName(String employeeName) {
17 | this.employeeName = employeeName;
18 | }
19 |
20 | public int getNumberOfDays() {
21 | return numberOfDays;
22 | }
23 |
24 | public void setNumberOfDays(int numberOfDays) {
25 | this.numberOfDays = numberOfDays;
26 | }
27 |
28 | public String getVacationMotivation() {
29 | return vacationMotivation;
30 | }
31 |
32 | public void setVacationMotivation(String vacationMotivation) {
33 | this.vacationMotivation = vacationMotivation;
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/async-history/async-history-jms-cfg/src/main/java/org/flowable/delegate/DummyServiceTask.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.delegate;
14 |
15 | import org.flowable.engine.delegate.DelegateExecution;
16 | import org.flowable.engine.delegate.JavaDelegate;
17 |
18 | public class DummyServiceTask implements JavaDelegate {
19 |
20 | public void execute(DelegateExecution execution) {
21 | // Simply passing through, doesn't do anything
22 | }
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/async-history/async-history-default-cfg/src/main/java/org/flowable/delegate/DummyServiceTask.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.delegate;
14 |
15 | import org.flowable.engine.delegate.DelegateExecution;
16 | import org.flowable.engine.delegate.JavaDelegate;
17 |
18 | public class DummyServiceTask implements JavaDelegate {
19 |
20 | public void execute(DelegateExecution execution) {
21 | // Simply passing through, doesn't do anything
22 | }
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/async-history/async-history-jms-jta-cfg/src/main/java/org/flowable/delegate/DummyServiceTask.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.delegate;
14 |
15 | import org.flowable.engine.delegate.DelegateExecution;
16 | import org.flowable.engine.delegate.JavaDelegate;
17 |
18 | public class DummyServiceTask implements JavaDelegate {
19 |
20 | public void execute(DelegateExecution execution) {
21 | // Simply passing through, doesn't do anything
22 | }
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/async-history/async-history-rabbitmq-cfg/src/main/java/org/flowable/delegate/DummyServiceTask.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.delegate;
14 |
15 | import org.flowable.engine.delegate.DelegateExecution;
16 | import org.flowable.engine.delegate.JavaDelegate;
17 |
18 | public class DummyServiceTask implements JavaDelegate {
19 |
20 | public void execute(DelegateExecution execution) {
21 | // Simply passing through, doesn't do anything
22 | }
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-process-mongo/src/main/java/org/flowable/delegate/CreditAdviceDelegate.java:
--------------------------------------------------------------------------------
1 | package org.flowable.delegate;
2 |
3 | import org.flowable.engine.delegate.DelegateExecution;
4 | import org.flowable.engine.delegate.JavaDelegate;
5 |
6 | public class CreditAdviceDelegate implements JavaDelegate {
7 |
8 | @Override
9 | public void execute(DelegateExecution execution) {
10 | Integer age = (Integer) execution.getVariable("age");
11 | String home = (String) execution.getVariable("home");
12 |
13 | String guidance = null;
14 | if (age < 25) {
15 | guidance = "Young, needs further checks";
16 | } else if ("rented".equals(home)) {
17 | guidance = "No collateral, so consider viability";
18 | } else if (age > 60 && "Mortgaged".equals(home)) {
19 | guidance = "Potentially overstretched debt to consider";
20 | } else {
21 | guidance = "No guidance";
22 | }
23 | execution.setVariable("guidance", guidance);
24 | }
25 |
26 | }
27 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-process-mongo/src/main/java/org/flowable/demo/delegate/DummyServiceTask.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.demo.delegate;
14 |
15 | import org.flowable.engine.delegate.DelegateExecution;
16 | import org.flowable.engine.delegate.JavaDelegate;
17 |
18 | public class DummyServiceTask implements JavaDelegate {
19 |
20 | public void execute(DelegateExecution execution) {
21 | // Simply passing through, doesn't do anything
22 | }
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/demo/demo-introducing-machine-learning/demo-process/src/main/java/org/flowable/demo/delegate/DummyServiceTask.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.demo.delegate;
14 |
15 | import org.flowable.engine.delegate.DelegateExecution;
16 | import org.flowable.engine.delegate.JavaDelegate;
17 |
18 | public class DummyServiceTask implements JavaDelegate {
19 |
20 | public void execute(DelegateExecution execution) {
21 | // Simply passing through, doesn't do anything
22 | }
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/quick-benchmark/src/main/java/org/flowable/delegate/ValidateInputDelegate.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.delegate;
14 |
15 | import org.flowable.engine.delegate.DelegateExecution;
16 | import org.flowable.engine.delegate.JavaDelegate;
17 |
18 | public class ValidateInputDelegate implements JavaDelegate {
19 |
20 | @Override
21 | public void execute(DelegateExecution delegateExecution) {
22 | delegateExecution.setVariable("inputValid", true);
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-customer-case-app/src/main/java/org/flowable/eventdemo/CustomerCaseApplication.java:
--------------------------------------------------------------------------------
1 | package org.flowable.eventdemo;
2 |
3 | import org.flowable.app.spring.SpringAppEngineConfiguration;
4 | import org.flowable.eventdemo.controller.ReviewEventCounter;
5 | import org.flowable.spring.boot.EngineConfigurationConfigurer;
6 | import org.springframework.boot.SpringApplication;
7 | import org.springframework.boot.autoconfigure.SpringBootApplication;
8 | import org.springframework.context.annotation.Bean;
9 |
10 | @SpringBootApplication
11 | public class CustomerCaseApplication {
12 |
13 | public static void main(String[] args) {
14 | SpringApplication.run(CustomerCaseApplication.class, args);
15 | }
16 |
17 | @Bean
18 | public EngineConfigurationConfigurer customAppEngineConfigurer(ReviewEventCounter reviewEventCounter) {
19 | return engineConfiguration -> {
20 | engineConfiguration.addEventRegistryEventConsumer(reviewEventCounter.getConsumerKey(), reviewEventCounter);
21 | };
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-review-app/src/main/java/org/flowable/eventdemo/review/ReviewService.java:
--------------------------------------------------------------------------------
1 | package org.flowable.eventdemo.review;
2 |
3 | import org.apache.kafka.clients.producer.ProducerRecord;
4 | import org.springframework.stereotype.Service;
5 |
6 | import com.fasterxml.jackson.databind.ObjectMapper;
7 |
8 | import reactor.core.publisher.Mono;
9 | import reactor.kafka.sender.KafkaSender;
10 | import reactor.kafka.sender.SenderRecord;
11 |
12 | @Service
13 | public class ReviewService {
14 |
15 | private KafkaSender kafkaSender;
16 | private ObjectMapper objectMapper;
17 |
18 | public ReviewService(KafkaSender kafkaSender, ObjectMapper objectMapper) {
19 | this.kafkaSender = kafkaSender;
20 | this.objectMapper = objectMapper;
21 | }
22 |
23 | public Mono sendReviewToKafka(String messageContent) {
24 | SenderRecord message =
25 | SenderRecord.create(new ProducerRecord("reviews", messageContent), null);
26 | return kafkaSender.send(Mono.just(message)).next();
27 | }
28 |
29 | }
30 |
--------------------------------------------------------------------------------
/flowable-intro/src/main/resources/flowable.dmn.cfg.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/src/main/java/com/example/demoflowfest/DefinitionsController.java:
--------------------------------------------------------------------------------
1 | package com.example.demoflowfest;
2 |
3 | import java.util.List;
4 | import java.util.stream.Collectors;
5 |
6 | import org.flowable.engine.RepositoryService;
7 | import org.flowable.engine.repository.ProcessDefinition;
8 | import org.springframework.web.bind.annotation.GetMapping;
9 | import org.springframework.web.bind.annotation.RestController;
10 |
11 | /**
12 | * @author Filip Hrisafov
13 | */
14 | @RestController
15 | public class DefinitionsController {
16 |
17 | protected final RepositoryService repositoryService;
18 |
19 | public DefinitionsController(RepositoryService repositoryService) {
20 | this.repositoryService = repositoryService;
21 | }
22 |
23 | @GetMapping("/latest-definitions")
24 | public List latestDefinitions() {
25 | return repositoryService.createProcessDefinitionQuery()
26 | .latestVersion()
27 | .list()
28 | .stream()
29 | .map(ProcessDefinition::getKey)
30 | .collect(Collectors.toList());
31 | }
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/blog/2022-02-flowable-spring-native/.mvn/wrapper/maven-wrapper.properties:
--------------------------------------------------------------------------------
1 | # Licensed to the Apache Software Foundation (ASF) under one
2 | # or more contributor license agreements. See the NOTICE file
3 | # distributed with this work for additional information
4 | # regarding copyright ownership. The ASF licenses this file
5 | # to you under the Apache License, Version 2.0 (the
6 | # "License"); you may not use this file except in compliance
7 | # with the License. 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,
12 | # software distributed under the License is distributed on an
13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14 | # KIND, either express or implied. See the License for the
15 | # specific language governing permissions and limitations
16 | # under the License.
17 | distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.8.4/apache-maven-3.8.4-bin.zip
18 | wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar
19 |
--------------------------------------------------------------------------------
/blog/2022-11-ms-exchange-online-modern-auth/.mvn/wrapper/maven-wrapper.properties:
--------------------------------------------------------------------------------
1 | # Licensed to the Apache Software Foundation (ASF) under one
2 | # or more contributor license agreements. See the NOTICE file
3 | # distributed with this work for additional information
4 | # regarding copyright ownership. The ASF licenses this file
5 | # to you under the Apache License, Version 2.0 (the
6 | # "License"); you may not use this file except in compliance
7 | # with the License. You may obtain a copy of the License at
8 | #
9 | # https://www.apache.org/licenses/LICENSE-2.0
10 | #
11 | # Unless required by applicable law or agreed to in writing,
12 | # software distributed under the License is distributed on an
13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14 | # KIND, either express or implied. See the License for the
15 | # specific language governing permissions and limitations
16 | # under the License.
17 | distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.8.6/apache-maven-3.8.6-bin.zip
18 | wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.1/maven-wrapper-3.1.1.jar
19 |
--------------------------------------------------------------------------------
/spring-boot-example/src/main/java/org/flowable/examples/spring/boot/FlowableSpringBootExampleApplication.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.examples.spring.boot;
14 |
15 | import org.springframework.boot.SpringApplication;
16 | import org.springframework.boot.autoconfigure.SpringBootApplication;
17 |
18 | /**
19 | * @author Filip Hrisafov
20 | */
21 | @SpringBootApplication
22 | public class FlowableSpringBootExampleApplication {
23 |
24 | public static void main(String[] args) {
25 | SpringApplication.run(FlowableSpringBootExampleApplication.class, args);
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/blog/04-2021-jobs/src/main/java/org/flowable/JobDelegate.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable;
14 |
15 | import org.flowable.engine.delegate.DelegateExecution;
16 | import org.flowable.engine.delegate.JavaDelegate;
17 |
18 | public class JobDelegate implements JavaDelegate {
19 |
20 | public static long WAIT_MS = 100;
21 |
22 | @Override
23 | public void execute(DelegateExecution execution) {
24 | try {
25 | Thread.sleep(WAIT_MS);
26 | } catch (InterruptedException e) {
27 | e.printStackTrace();
28 | }
29 | }
30 |
31 | }
32 |
--------------------------------------------------------------------------------
/spring-boot-example/src/test/java/org/flowable/examples/spring/boot/FlowableSpringBootExampleApplicationTests.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.examples.spring.boot;
14 |
15 | import org.junit.Test;
16 | import org.junit.runner.RunWith;
17 | import org.springframework.boot.test.context.SpringBootTest;
18 | import org.springframework.test.context.junit4.SpringRunner;
19 |
20 | /**
21 | * @author Filip Hrisafov
22 | */
23 | @RunWith(SpringRunner.class)
24 | @SpringBootTest
25 | public class FlowableSpringBootExampleApplicationTests {
26 |
27 | @Test
28 | public void contextLoads() {
29 | }
30 |
31 | }
32 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-process-mongo/src/main/resources/demo-app/form-advreview.form:
--------------------------------------------------------------------------------
1 | {"name":"Advanced review","key":"advreview","version":0,"fields":[{"fieldType":"FormField","id":"fullname","name":"Fullname","type":"text","value":null,"required":false,"readOnly":true,"overrideId":false,"placeholder":null,"layout":null},{"fieldType":"FormField","id":"loan","name":"Loan","type":"integer","value":null,"required":false,"readOnly":true,"overrideId":false,"placeholder":null,"layout":null},{"fieldType":"FormField","id":"age","name":"Age","type":"integer","value":null,"required":false,"readOnly":true,"overrideId":false,"placeholder":null,"layout":null},{"fieldType":"FormField","id":"nationality","name":"Nationality","type":"text","value":null,"required":false,"readOnly":true,"overrideId":false,"placeholder":null,"layout":null},{"fieldType":"FormField","id":"income","name":"Income","type":"integer","value":null,"required":false,"readOnly":true,"overrideId":false,"placeholder":null,"layout":null},{"fieldType":"FormField","id":"home","name":"Home","type":"text","value":null,"required":false,"readOnly":true,"overrideId":false,"placeholder":null,"layout":null}],"outcomes":[{"id":null,"name":"Reject"},{"id":null,"name":"Accept"}]}
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/src/main/java/com/example/demoflowfest/vacation/VacationRequest.java:
--------------------------------------------------------------------------------
1 | package com.example.demoflowfest.vacation;
2 |
3 | import java.util.HashMap;
4 | import java.util.Map;
5 | import java.util.function.Consumer;
6 |
7 | import org.flowable.engine.RuntimeService;
8 | import org.springframework.stereotype.Component;
9 |
10 | /**
11 | * @author Filip Hrisafov
12 | */
13 | @Component
14 | public class VacationRequest implements Consumer {
15 |
16 | protected final RuntimeService runtimeService;
17 |
18 | public VacationRequest(RuntimeService runtimeService) {
19 | this.runtimeService = runtimeService;
20 | }
21 |
22 | @Override
23 | public void accept(VacationRequestInput vacationRequestInput) {
24 | Map variables = new HashMap<>();
25 | variables.put("employeeName", vacationRequestInput.getEmployeeName());
26 | variables.put("numberOfDays", vacationRequestInput.getNumberOfDays());
27 | variables.put("vacationMotivation", vacationRequestInput.getVacationMotivation());
28 | runtimeService.signalEventReceived("Start process instance", variables);
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/spring-boot-example/src/main/resources/forms/vacation-request.form:
--------------------------------------------------------------------------------
1 | {
2 | "name": "Vacation Request",
3 | "key": "vacation-request",
4 | "version": 0,
5 | "fields": [
6 | {
7 | "fieldType": "FormField",
8 | "id": "numberOfDays",
9 | "name": "Number of days",
10 | "type": "integer",
11 | "value": null,
12 | "required": true,
13 | "readOnly": false,
14 | "overrideId": true,
15 | "placeholder": null,
16 | "layout": null
17 | },
18 | {
19 | "fieldType": "FormField",
20 | "id": "startDate",
21 | "name": "First day of holiday (dd-MM-yyy)",
22 | "type": "date",
23 | "value": null,
24 | "required": true,
25 | "readOnly": false,
26 | "overrideId": true,
27 | "placeholder": null,
28 | "layout": null
29 | },
30 | {
31 | "fieldType": "FormField",
32 | "id": "vacationMotivation",
33 | "name": "Motivation",
34 | "type": "multi-line-text",
35 | "value": null,
36 | "required": false,
37 | "readOnly": false,
38 | "overrideId": true,
39 | "placeholder": null,
40 | "layout": null
41 | }
42 | ],
43 | "outcomes": []
44 | }
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/src/main/java/com/example/demoflowfest/vacation/VacationRequestProcessor.java:
--------------------------------------------------------------------------------
1 | package com.example.demoflowfest.vacation;
2 |
3 | import org.flowable.engine.delegate.DelegateExecution;
4 | import org.flowable.engine.delegate.JavaDelegate;
5 | import org.slf4j.Logger;
6 | import org.slf4j.LoggerFactory;
7 | import org.springframework.stereotype.Component;
8 |
9 | /**
10 | * @author Filip Hrisafov
11 | */
12 | @Component("vacationRequestProcessor")
13 | public class VacationRequestProcessor implements JavaDelegate {
14 |
15 | private static final Logger LOGGER = LoggerFactory.getLogger(VacationRequestProcessor.class);
16 |
17 | @Override
18 | public void execute(DelegateExecution execution) {
19 | String employeeName = execution.getVariable("employeeName", String.class);
20 | Integer numberOfDays = execution.getVariable("numberOfDays", Integer.class);
21 | String vacationMotivation = execution.getVariable("vacationMotivation", String.class);
22 |
23 | LOGGER.info("{} requested vacation for {} days. Motivation {}", employeeName, numberOfDays, vacationMotivation);
24 |
25 | execution.setVariable("vacationApproved", true);
26 | }
27 |
28 | }
29 |
--------------------------------------------------------------------------------
/spring-boot-example/src/main/resources/forms/handle-vacation-request.form:
--------------------------------------------------------------------------------
1 | {
2 | "name": "Handle Vacation Request",
3 | "key": "handle-vacation-request",
4 | "version": 0,
5 | "fields": [
6 | {
7 | "fieldType": "OptionFormField",
8 | "id": "vacationApproved",
9 | "name": "Do you approve this vacation?",
10 | "type": "radio-buttons",
11 | "value": "Approve",
12 | "required": true,
13 | "readOnly": false,
14 | "overrideId": true,
15 | "placeholder": null,
16 | "layout": null,
17 | "optionType": null,
18 | "hasEmptyValue": null,
19 | "options": [
20 | {
21 | "id": null,
22 | "name": "Approve"
23 | },
24 | {
25 | "id": null,
26 | "name": "Reject"
27 | }
28 | ],
29 | "optionsExpression": null
30 | },
31 | {
32 | "fieldType": "FormField",
33 | "id": "managerMotivation",
34 | "name": "Motivation",
35 | "type": "multi-line-text",
36 | "value": null,
37 | "required": false,
38 | "readOnly": false,
39 | "overrideId": true,
40 | "placeholder": null,
41 | "layout": null
42 | }
43 | ],
44 | "outcomes": []
45 | }
--------------------------------------------------------------------------------
/flowable-intro/src/main/resources/intro.dmn:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | name
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-api-gateway/src/main/resources/application.yml:
--------------------------------------------------------------------------------
1 | server:
2 | port: 8090
3 | use-forward-headers: true
4 |
5 |
6 | spring:
7 | jackson:
8 | serialization:
9 | WRITE_DATES_AS_TIMESTAMPS: false
10 | servlet:
11 | multipart:
12 | max-file-size: 128MB
13 | max-request-size: 128MB
14 | cloud:
15 | gateway:
16 | routes:
17 | - id: review-application
18 | uri: http://localhost:8084/
19 | predicates:
20 | - Path=/reviews/**
21 | - id: dashboard
22 | uri: http://localhost:8123/dashboard/
23 | predicates:
24 | - Path=/dashboard/**
25 |
26 | management:
27 | endpoints:
28 | web:
29 | exposure:
30 | # Expose all actuator endpoints to the web
31 | # They are exposed, but only authenticated users can see /info and /health abd users with access-admin can see the others
32 | include: "*"
33 | endpoint:
34 | health:
35 | # Full health details should only be displayed when a user is authorized
36 | show-details: when_authorized
37 | # Only users with role access-admin can access full health details
38 | roles: access-admin
39 |
40 | ribbon:
41 | eureka:
42 | enabled: false
43 |
--------------------------------------------------------------------------------
/blog/04-2021-flowable-spring-boot-native/src/main/java/org/flowable/demo/DemoApplication.java:
--------------------------------------------------------------------------------
1 | package org.flowable.demo;
2 |
3 | import org.flowable.engine.ProcessEngine;
4 | import org.springframework.boot.CommandLineRunner;
5 | import org.springframework.boot.SpringApplication;
6 | import org.springframework.boot.autoconfigure.SpringBootApplication;
7 | import org.springframework.context.annotation.Bean;
8 |
9 | @SpringBootApplication
10 | public class DemoApplication {
11 |
12 | public static void main(String[] args) {
13 | SpringApplication.run(DemoApplication.class, args);
14 | }
15 |
16 | @Bean
17 | public CommandLineRunner commandLineRunner(ProcessEngine processEngine) {
18 | return new CommandLineRunner() {
19 |
20 | @Override
21 | public void run(String... args) throws Exception {
22 | processEngine.getRepositoryService().createDeployment()
23 | .disableSchemaValidation()
24 | .addClasspathResource("org/flowable/test.bpmn20.xml")
25 | .deploy();
26 |
27 | while (true) {
28 | processEngine.getRuntimeService().startProcessInstanceByKey("oneTaskProcess");
29 | System.out.println("Number of tasks: " + processEngine.getTaskService().createTaskQuery().count());
30 | Thread.sleep(1000);
31 | }
32 | }
33 | };
34 | }
35 |
36 | }
37 |
--------------------------------------------------------------------------------
/async-history/async-history-rabbitmq-springboot-listener/src/main/java/org/flowable/MyJobMessageHandler.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable;
14 |
15 | import org.flowable.engine.impl.history.async.message.AsyncHistoryJobMessageHandler;
16 | import org.flowable.engine.impl.persistence.entity.HistoryJobEntity;
17 |
18 | import com.fasterxml.jackson.databind.JsonNode;
19 |
20 | public class MyJobMessageHandler implements AsyncHistoryJobMessageHandler {
21 |
22 | @Override
23 | public boolean handleJob(HistoryJobEntity historyJobEntity, JsonNode historyData) {
24 | System.out.println("Handling job " + historyJobEntity.getId() + ", data = " + historyData);
25 | return true;
26 | }
27 |
28 | }
29 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-customer-case-app/src/main/resources/forms/form-badReviewForm.form:
--------------------------------------------------------------------------------
1 | {"name":"badReviewForm","key":"badReviewForm","version":0,"fields":[{"fieldType":"FormField","id":"badreviewreceived","name":"Bad review received","type":"headline-with-line","value":null,"required":false,"readOnly":false,"overrideId":false,"placeholder":null,"layout":null},{"fieldType":"ExpressionFormField","id":"label","name":"Label","type":"expression","value":null,"required":false,"readOnly":false,"overrideId":false,"placeholder":null,"layout":null,"expression":"${userId} has written following bad review for our awesome bike service: ${comment}"},{"fieldType":"FormField","id":"ourresponse","name":"Our response","type":"headline-with-line","value":null,"required":false,"readOnly":false,"overrideId":false,"placeholder":null,"layout":null},{"fieldType":"ExpressionFormField","id":"label","name":"Label","type":"expression","value":null,"required":false,"readOnly":false,"overrideId":false,"placeholder":null,"layout":null,"expression":"Fill in a gentle and friendly reply in the textbox below here. BEWARE! This will be posted online, so choose your words carefully!"},{"fieldType":"FormField","id":"response","name":"Response","type":"multi-line-text","value":null,"required":true,"readOnly":false,"overrideId":false,"placeholder":null,"layout":null}],"outcomes":[]}
--------------------------------------------------------------------------------
/async-history/async-history-jms-jta-cfg/src/main/java/org/flowable/ExampleJmsListener.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable;
14 |
15 | import javax.jms.JMSException;
16 | import javax.jms.Message;
17 | import javax.jms.TextMessage;
18 |
19 | public class ExampleJmsListener implements javax.jms.MessageListener {
20 |
21 | @Override
22 | public void onMessage(Message message) {
23 | if (message instanceof TextMessage) {
24 | TextMessage textMessage = (TextMessage) message;
25 | try {
26 | System.out.println("Received historical data : " + textMessage.getText());
27 | } catch (JMSException e) {
28 | e.printStackTrace();
29 | }
30 | }
31 | }
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/flowable-intro/src/main/java/org/flowable/intro/IntroTask.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.intro;
14 |
15 | import org.flowable.engine.delegate.DelegateExecution;
16 | import org.flowable.engine.delegate.JavaDelegate;
17 |
18 | /**
19 | * @author Tijs Rademakers
20 | */
21 | public class IntroTask implements JavaDelegate {
22 |
23 | public void execute(DelegateExecution execution) {
24 | if (execution.hasVariable("intro")) {
25 | System.out.println("Intro variable available with value " + execution.getVariable("intro"));
26 | execution.setVariable("variablePresent", true);
27 | } else {
28 | System.out.println("Intro variable not available");
29 | execution.setVariable("variablePresent", false);
30 | }
31 | }
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/demo/demo-introducing-machine-learning/demo-admin/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 | 4.0.0
5 |
6 | demo-admin
7 | jar
8 |
9 |
10 | org.springframework.boot
11 | spring-boot-starter-parent
12 | 1.5.8.RELEASE
13 |
14 |
15 |
16 | 1.8
17 | 1.8
18 | 6.2.0
19 |
20 |
21 |
22 |
23 | de.codecentric
24 | spring-boot-admin-server
25 | 1.5.4
26 |
27 |
28 | de.codecentric
29 | spring-boot-admin-server-ui
30 | 1.5.4
31 |
32 |
33 |
34 |
35 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-hello-world/src/main/java/org/flowable/jaxdemo/MyApplication.java:
--------------------------------------------------------------------------------
1 | package org.flowable.jaxdemo;
2 |
3 | import org.flowable.engine.RuntimeService;
4 | import org.springframework.beans.factory.annotation.Autowired;
5 | import org.springframework.boot.SpringApplication;
6 | import org.springframework.boot.autoconfigure.SpringBootApplication;
7 | import org.springframework.web.bind.annotation.PostMapping;
8 | import org.springframework.web.bind.annotation.RestController;
9 |
10 | @SpringBootApplication
11 | public class MyApplication {
12 |
13 | public static void main(String[] args) {
14 | SpringApplication.run(MyApplication.class, args);
15 | }
16 |
17 | @RestController
18 | public class InsuranceRestController {
19 |
20 | private RuntimeService runtimeService;
21 |
22 | @Autowired
23 | public InsuranceRestController(RuntimeService runtimeService) {
24 | this.runtimeService = runtimeService;
25 | }
26 |
27 | @PostMapping("/insurance-claim")
28 | public String start() {
29 | return runtimeService.createProcessInstanceBuilder()
30 | .processDefinitionKey("myProcess")
31 | .variable("someData", "Hello")
32 | .start()
33 | .getId();
34 | }
35 |
36 | }
37 |
38 | }
39 |
40 |
41 |
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/src/main/java/com/example/demoflowfest/risk/RiskCalculator.java:
--------------------------------------------------------------------------------
1 | package com.example.demoflowfest.risk;
2 |
3 | import java.util.Map;
4 | import java.util.function.Function;
5 |
6 | import org.flowable.dmn.api.DmnRuleService;
7 | import org.springframework.stereotype.Component;
8 |
9 | /**
10 | * @author Filip Hrisafov
11 | */
12 | @Component
13 | public class RiskCalculator implements Function {
14 |
15 | protected final DmnRuleService ruleService;
16 |
17 | public RiskCalculator(DmnRuleService ruleService) {
18 | this.ruleService = ruleService;
19 | }
20 |
21 | @Override
22 | public RiskOutput apply(RiskInput riskInput) {
23 | Map result = ruleService.createExecuteDecisionBuilder()
24 | .decisionKey("RiskRatingDecisionTable")
25 | .variable("age", riskInput.getAge())
26 | .variable("riskcategory", riskInput.getCategory())
27 | .variable("debtreview", riskInput.isDebtReview())
28 | .executeWithSingleResult();
29 | RiskOutput output = new RiskOutput();
30 | output.setRouting((String) result.get("routing"));
31 | output.setReviewLevel((String) result.get("reviewlevel"));
32 | output.setReason((String) result.get("reason"));
33 | return output;
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/flowable-kafka/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 | 4.0.0
5 | pom
6 |
7 | event-demo-review-app
8 | event-demo-sentiment-analysis-app
9 | event-demo-customer-case-app
10 | event-demo-api-gateway
11 | event-demo-common
12 |
13 |
14 | org.springframework.boot
15 | spring-boot-starter-parent
16 | 2.2.5.RELEASE
17 |
18 |
19 | org.flowable
20 | eventbus-demo
21 | 0.0.1-SNAPSHOT
22 | eventbus-demo
23 | Demo project for Spring Boot
24 |
25 |
26 | 1.8
27 |
28 |
29 |
30 |
31 |
32 | org.springframework.boot
33 | spring-boot-maven-plugin
34 |
35 |
36 |
37 |
38 |
39 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-process-mongo/src/main/resources/demo-app/form-loanreview.form:
--------------------------------------------------------------------------------
1 | {"name":"Loan review","key":"loanreview","version":0,"fields":[{"fieldType":"FormField","id":"fullname","name":"Fullname","type":"text","value":null,"required":false,"readOnly":true,"overrideId":false,"placeholder":null,"layout":null},{"fieldType":"FormField","id":"loan","name":"Loan","type":"integer","value":null,"required":false,"readOnly":true,"overrideId":false,"placeholder":null,"layout":null},{"fieldType":"FormField","id":"age","name":"Age","type":"integer","value":null,"required":false,"readOnly":true,"overrideId":false,"placeholder":null,"layout":null},{"fieldType":"FormField","id":"nationality","name":"Nationality","type":"text","value":null,"required":false,"readOnly":true,"overrideId":false,"placeholder":null,"layout":null},{"fieldType":"FormField","id":"income","name":"Income","type":"integer","value":null,"required":false,"readOnly":true,"overrideId":false,"placeholder":null,"layout":null},{"fieldType":"FormField","id":"home","name":"Home","type":"text","value":null,"required":false,"readOnly":true,"overrideId":false,"placeholder":null,"layout":null},{"fieldType":"FormField","id":"guidance","name":"Guidance","type":"text","value":null,"required":false,"readOnly":true,"overrideId":false,"placeholder":null,"layout":null}],"outcomes":[{"id":null,"name":"Reject"},{"id":null,"name":"Consider"},{"id":null,"name":"Accept"}]}
--------------------------------------------------------------------------------
/async-history/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 | 4.0.0
5 |
6 | Flowable Async History Examples
7 | org.flowable.examples
8 | flowable-async-history-examples
9 | pom
10 | 1.0
11 |
12 |
13 | 6.1.1
14 | 4.3.9.RELEASE
15 |
16 |
17 |
18 | async-history-default-cfg
19 | async-history-jms-inmem-cfg
20 | async-history-jms-cfg
21 | async-history-jms-jta
22 |
23 |
24 |
25 |
26 | org.slf4j
27 | slf4j-api
28 | 1.7.25
29 |
30 |
31 | org.slf4j
32 | jcl-over-slf4j
33 | 1.7.25
34 |
35 |
36 | org.slf4j
37 | slf4j-log4j12
38 | 1.7.25
39 |
40 |
41 |
42 |
43 |
--------------------------------------------------------------------------------
/blog/2022-11-ms-exchange-online-modern-auth/src/test/java/org/flowable/example/blog/MsExchangeOnlineModernAuthTestCliTest.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.example.blog;
14 |
15 | class MsExchangeOnlineModernAuthCliTest {
16 |
17 | /**
18 | * Simply delegates execution to test cli. Add your tenant, client id, client secret and optionally email to test MS Exchange Online modern auth
19 | * and access a mailbox.
20 | * See https://www.flowable.com/blog/office-365-exchange-oauth2-imap-authentication?slug=blog/office-365-exchange-oauth2-imap-authentication<
21 | */
22 | public static void main(String ignore[]) {
23 | String[] args = new String[] { "", "-c=", "-cs=", "-e=" };
24 | MsExchangeOnlineModernAuthTestCli.main(args);
25 | }
26 |
27 | }
28 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-review-app/src/main/java/org/flowable/eventdemo/review/ReviewApplication.java:
--------------------------------------------------------------------------------
1 | package org.flowable.eventdemo.review;
2 |
3 | import java.util.Properties;
4 |
5 | import org.apache.kafka.clients.producer.ProducerConfig;
6 | import org.apache.kafka.common.serialization.StringSerializer;
7 | import org.springframework.boot.SpringApplication;
8 | import org.springframework.boot.autoconfigure.SpringBootApplication;
9 | import org.springframework.context.annotation.Bean;
10 |
11 | import reactor.kafka.sender.KafkaSender;
12 | import reactor.kafka.sender.SenderOptions;
13 |
14 | @SpringBootApplication
15 | public class ReviewApplication {
16 |
17 | public static void main(String[] args) {
18 | SpringApplication.run(ReviewApplication.class, args);
19 | }
20 |
21 | @Bean
22 | public KafkaSender kafkaSender() {
23 | Properties props = new Properties();
24 | props.put(ProducerConfig.BOOTSTRAP_SERVERS_CONFIG, "localhost:9092");
25 | props.put(ProducerConfig.CLIENT_ID_CONFIG, "myClient");
26 | props.put(ProducerConfig.KEY_SERIALIZER_CLASS_CONFIG, StringSerializer.class.getName());
27 | props.put(ProducerConfig.VALUE_SERIALIZER_CLASS_CONFIG, StringSerializer.class.getName());
28 |
29 | SenderOptions producerOptions = SenderOptions.create(props);
30 | return KafkaSender.create(producerOptions);
31 | }
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-review-app/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 | org.springframework.boot
7 | spring-boot-starter-parent
8 | 2.2.0.RELEASE
9 |
10 |
11 | 4.0.0
12 |
13 | event-demo-review-app
14 |
15 |
16 | 1.8
17 |
18 |
19 |
20 |
21 | org.springframework.boot
22 | spring-boot-starter-webflux
23 |
24 |
25 |
26 | io.projectreactor.kafka
27 | reactor-kafka
28 | 1.1.0.RELEASE
29 |
30 |
31 |
32 |
33 |
34 |
35 | org.springframework.boot
36 | spring-boot-maven-plugin
37 |
38 |
39 |
40 |
41 |
42 |
--------------------------------------------------------------------------------
/async-history/async-history-rabbitmq-cfg/src/main/java/org/flowable/RabbitMQMessageBasedJobManager.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable;
14 |
15 | import org.flowable.engine.impl.asyncexecutor.message.AbstractMessageBasedJobManager;
16 | import org.flowable.engine.runtime.JobInfo;
17 | import org.springframework.amqp.rabbit.core.RabbitTemplate;
18 |
19 | public class RabbitMQMessageBasedJobManager extends AbstractMessageBasedJobManager {
20 |
21 | private RabbitTemplate rabbitTemplate;
22 |
23 | @Override
24 | protected void sendMessage(JobInfo job) {
25 | rabbitTemplate.convertAndSend("flowable-exchange", "flowable-history-jobs", job.getId());
26 | }
27 |
28 | public RabbitTemplate getRabbitTemplate() {
29 | return rabbitTemplate;
30 | }
31 |
32 | public void setRabbitTemplate(RabbitTemplate rabbitTemplate) {
33 | this.rabbitTemplate = rabbitTemplate;
34 | }
35 |
36 | }
37 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/settingsForm.scss:
--------------------------------------------------------------------------------
1 | .flw-settingsForm-form {
2 | position: absolute;
3 | z-index: 99999;
4 | bottom: 50px;
5 | right: 35px;
6 | width: 390px;
7 | background: #fff;
8 | border-radius: 10px;
9 | overflow: hidden;
10 | padding: 20px;
11 | box-shadow: 0 5px 10px 0 rgba(0,0,0,.1);
12 | color: #555;
13 | .flw-rating {
14 | .flw-star {
15 | margin-right: 5px;
16 | width: 30px;
17 | height: 30px;
18 | }
19 | }
20 | &__title {
21 | width: 100%;
22 | display: block;
23 | font-size: 25px;
24 | line-height: 1.2;
25 | text-align: center;
26 | }
27 | &__label {
28 | font-size: 15px;
29 | line-height: 1.5;
30 | padding: 13px 0 9px 0;
31 | }
32 | &__input {
33 | background-color: #f7f7f7;
34 | display: flex;
35 | padding: 10px 10px;
36 | input, textarea {
37 | color: #333;
38 | line-height: 1.2;
39 | font-size: 18px;
40 | border: none;
41 | background: 0 0;
42 | }
43 | textarea {
44 | height: 100px;
45 | padding: 10px 20px;
46 | }
47 | }
48 | button {
49 | margin-top: 17px;
50 | cursor: pointer;
51 | display: flex;
52 | justify-content: center;
53 | align-items: center;
54 | padding: 0 20px;
55 | width: 100%;
56 | height: 50px;
57 | background-color: #333;
58 | border-radius: 10px;
59 | font-size: 16px;
60 | color: #fff;
61 | line-height: 1.2;
62 | &:disabled {
63 | opacity: 0.4;
64 | }
65 | }
66 | }
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-process-mongo/src/main/java/org/flowable/demo/StartController.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.demo;
14 |
15 | import org.springframework.beans.factory.annotation.Autowired;
16 | import org.springframework.web.bind.annotation.GetMapping;
17 | import org.springframework.web.bind.annotation.PathVariable;
18 | import org.springframework.web.bind.annotation.RestController;
19 |
20 | /**
21 | * Quick-n-Dirty rest controller to trigger starting a number of random process instances.
22 | *
23 | * @author Joram Barrez
24 | */
25 | @RestController
26 | public class StartController {
27 |
28 | @Autowired
29 | private ProcessService processService;
30 |
31 | @GetMapping("/start/{nrOfInstances}")
32 | public String start(@PathVariable int nrOfInstances) {
33 | processService.execute(nrOfInstances);
34 | return "Triggered the start of " + nrOfInstances + " instances";
35 | }
36 |
37 | }
38 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/Avatar.tsx:
--------------------------------------------------------------------------------
1 | import React, { useState } from 'react';
2 | import classNames from 'classnames';
3 |
4 | import './avatar.scss';
5 |
6 | export type AvatarProps = {
7 | id: string;
8 | avatarUrl?: string;
9 | displayName?: string;
10 | };
11 |
12 | export type AvatarState = {
13 | imageStatus: 'loading' | 'calm' | 'hide';
14 | };
15 |
16 | export const Avatar = ({ id, avatarUrl, displayName }: AvatarProps) => {
17 | const [imageStatus, setImageStatus] = useState((avatarUrl && 'calm') || 'hide');
18 | const renderImage = avatarUrl ? imageStatus === 'calm' : false;
19 | return (
20 |
25 | {avatarUrl && (
26 |

setImageStatus('calm')}
32 | onError={() => setImageStatus('hide')}
33 | />
34 | )}
35 | {!renderImage && initialsFromName(displayName)}
36 |
37 | );
38 | };
39 |
40 | const DEFAULT_INITIALS = 'Anonymous User';
41 |
42 | export function initialsFromName(displayName?: string): string {
43 | if (displayName) {
44 | return (displayName || DEFAULT_INITIALS)
45 | .split(' ')
46 | .map(e => e[0])
47 | .slice(0, 2)
48 | .join('')
49 | .toUpperCase();
50 | }
51 | return DEFAULT_INITIALS;
52 | }
53 |
--------------------------------------------------------------------------------
/demo/demo-introducing-machine-learning/demo-process/src/main/java/org/flowable/demo/StartController.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.demo;
14 |
15 | import org.springframework.beans.factory.annotation.Autowired;
16 | import org.springframework.web.bind.annotation.GetMapping;
17 | import org.springframework.web.bind.annotation.PathVariable;
18 | import org.springframework.web.bind.annotation.RestController;
19 |
20 | /**
21 | * Quick-n-Dirty rest controller to trigger starting a number of random process instances.
22 | *
23 | * @author Joram Barrez
24 | */
25 | @RestController
26 | public class StartController {
27 |
28 | @Autowired
29 | private ProcessService processService;
30 |
31 | @GetMapping("/start/{nrOfInstances}")
32 | public String start(@PathVariable int nrOfInstances) {
33 | processService.execute(nrOfInstances);
34 | return "Triggered the start of " + nrOfInstances + " instances";
35 | }
36 |
37 | }
38 |
--------------------------------------------------------------------------------
/demo/demo-introducing-machine-learning/demo-process/src/main/java/org/flowable/demo/RabbitMQMessageBasedJobManager.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.demo;
14 |
15 | import org.flowable.engine.impl.asyncexecutor.message.AbstractMessageBasedJobManager;
16 | import org.flowable.job.api.JobInfo;
17 | import org.springframework.amqp.rabbit.core.RabbitTemplate;
18 |
19 | /**
20 | * @author Joram Barrez
21 | */
22 | public class RabbitMQMessageBasedJobManager extends AbstractMessageBasedJobManager {
23 |
24 | private RabbitTemplate rabbitTemplate;
25 |
26 | @Override
27 | protected void sendMessage(JobInfo job) {
28 | rabbitTemplate.convertAndSend("flowable-exchange", "flowable-history-jobs", job.getId());
29 | }
30 |
31 | public RabbitTemplate getRabbitTemplate() {
32 | return rabbitTemplate;
33 | }
34 |
35 | public void setRabbitTemplate(RabbitTemplate rabbitTemplate) {
36 | this.rabbitTemplate = rabbitTemplate;
37 | }
38 |
39 | }
40 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/SettingsForm.tsx:
--------------------------------------------------------------------------------
1 | import React, { useState, FormEvent, useCallback } from 'react';
2 |
3 | import { SettingsData } from './model';
4 | import { Settings } from './api';
5 |
6 | import './settingsForm.scss';
7 |
8 | type settingFormProps = {
9 | settings: Settings;
10 | setSpeed: (speed: string) => void;
11 | };
12 |
13 | const speedSettings = {
14 | lazySunday: 'A lazy sunday morning',
15 | franticFriday: 'A frantic friday evening',
16 | freezeTime: 'Freeze the mists of time'
17 | };
18 |
19 | export const SettingsForm = (props: settingFormProps) => {
20 | let [formData, setFormData] = useState({
21 | speed: props.settings.speed
22 | });
23 |
24 | const onSpeedChange = useCallback(
25 | (e: FormEvent) => {
26 | setFormData({ ...formData, speed: e.currentTarget.value });
27 | props.setSpeed(e.currentTarget.value);
28 | },
29 | [formData]
30 | );
31 |
32 | return (
33 |
34 |
Settings
35 |
36 |
Demo speed
37 | {Object.keys(speedSettings).map(s => (
38 |
39 |
43 |
44 | ))}
45 |
46 |
47 | );
48 | };
49 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-sentiment-analysis-app/src/main/java/org/flowable/eventdemo/service/SentimentService.java:
--------------------------------------------------------------------------------
1 | package org.flowable.eventdemo.service;
2 |
3 | import org.springframework.stereotype.Service;
4 |
5 | import com.amazonaws.auth.AWSCredentialsProvider;
6 | import com.amazonaws.auth.DefaultAWSCredentialsProviderChain;
7 | import com.amazonaws.services.comprehend.AmazonComprehend;
8 | import com.amazonaws.services.comprehend.AmazonComprehendClientBuilder;
9 | import com.amazonaws.services.comprehend.model.DetectSentimentRequest;
10 | import com.amazonaws.services.comprehend.model.DetectSentimentResult;
11 |
12 | @Service
13 | public class SentimentService {
14 |
15 | public String analyse(String comment) {
16 | AWSCredentialsProvider awsCreds = DefaultAWSCredentialsProviderChain.getInstance();
17 |
18 | AmazonComprehend comprehendClient =
19 | AmazonComprehendClientBuilder.standard()
20 | .withCredentials(awsCreds)
21 | .withRegion("eu-central-1")
22 | .build();
23 |
24 | // Call detectSentiment API
25 | System.out.println("Calling AWS Comprehend API");
26 | DetectSentimentRequest detectSentimentRequest = new DetectSentimentRequest()
27 | .withText(comment)
28 | .withLanguageCode("en");
29 | DetectSentimentResult detectSentimentResult = comprehendClient.detectSentiment(detectSentimentRequest);
30 | System.out.println("Finished calling AWS Comprehend API. Result: " + detectSentimentResult);
31 | return detectSentimentResult.getSentiment();
32 | }
33 |
34 | }
35 |
--------------------------------------------------------------------------------
/demo/demo-introducing-machine-learning/demo-admin/src/main/java/org/flowable/AdminApplication.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable;
14 |
15 | import org.springframework.boot.SpringApplication;
16 | import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
17 | import org.springframework.boot.autoconfigure.SpringBootApplication;
18 | import org.springframework.context.annotation.Configuration;
19 |
20 | import de.codecentric.boot.admin.config.EnableAdminServer;
21 |
22 | /**
23 | * Having the spring-boot-admin-xyz dependency in the pom.xml
24 | * is enough to have the server and ui being booted up automatically.
25 | *
26 | * The UI is available on http://localhost:8080/
27 | *
28 | * @author Joram Barrez
29 | */
30 | @SpringBootApplication
31 | @Configuration
32 | @EnableAutoConfiguration
33 | @EnableAdminServer
34 | public class AdminApplication {
35 |
36 | public static void main(String[] args) throws InterruptedException {
37 | SpringApplication.run(AdminApplication.class, args);
38 | }
39 |
40 | }
41 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/api.ts:
--------------------------------------------------------------------------------
1 | import { parseString } from 'xml2js';
2 | import { promisify } from 'es6-promisify';
3 |
4 | export interface Settings {
5 | speed: string;
6 | }
7 |
8 | export interface Station {
9 | id: string;
10 | name: string;
11 | position: number[];
12 | bikes: number;
13 | slots: number;
14 | }
15 |
16 | export type CommentData = {
17 | userId: string;
18 | stationId: number;
19 | rating: number;
20 | comment: string;
21 | };
22 |
23 | export type StationDict = { [id: string]: Station };
24 |
25 | const parse = promisify(parseString);
26 |
27 | // tslint:disable-next-line:no-any
28 | const normalize = (station: any) => ({
29 | id: station.id[0],
30 | name: station.name[0],
31 | position: [parseFloat(station.long[0]), parseFloat(station.lat[0])],
32 | bikes: parseInt(station.nbBikes[0], 10),
33 | slots: parseInt(station.nbDocks[0], 10)
34 | });
35 |
36 | export const getCycleStations = () =>
37 | fetch('https://tfl.gov.uk/tfl/syndication/feeds/cycle-hire/livecyclehireupdates.xml')
38 | .then(res => res.text())
39 | .then(parse)
40 | .then((res: any) => res.stations.station.map(normalize))
41 | .then((stations: Station[]) =>
42 | // tslint:disable-next-line:no-object-literal-type-assertion
43 | stations.reduce((acc, station) => ((acc[station.id] = station), acc), {} as StationDict)
44 | );
45 |
46 | export const sendComment = (comment: CommentData) =>
47 | fetch('/reviews', {
48 | method: 'POST',
49 | body: JSON.stringify(comment)
50 | });
51 |
52 | export const getDashBoardData = () => fetch('/dashboard').then(res => res.json());
53 |
--------------------------------------------------------------------------------
/async-history/async-history-rabbitmq-springboot-listener/src/main/java/org/flowable/Receiver.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable;
14 |
15 | import org.flowable.engine.impl.history.async.message.AsyncHistoryJobMessageReceiver;
16 |
17 | public class Receiver {
18 |
19 | private AsyncHistoryJobMessageReceiver asyncHistoryJobMessageReceiver;
20 |
21 | public void receiveMessage(byte[] messageBytes) {
22 | receiveMessage(new String(messageBytes));
23 | }
24 |
25 | public void receiveMessage(String message) {
26 | System.out.println("Received <" + message + ">");
27 | asyncHistoryJobMessageReceiver.messageForJobReceived(message);
28 | }
29 |
30 | public AsyncHistoryJobMessageReceiver getAsyncHistoryJobMessageReceiver() {
31 | return asyncHistoryJobMessageReceiver;
32 | }
33 |
34 | public void setAsyncHistoryJobMessageReceiver(AsyncHistoryJobMessageReceiver asyncHistoryJobMessageReceiver) {
35 | this.asyncHistoryJobMessageReceiver = asyncHistoryJobMessageReceiver;
36 | }
37 |
38 | }
--------------------------------------------------------------------------------
/demo/demo-jax-2018/quick-benchmark/src/main/java/org/flowable/delegate/SetVariablesDelegate.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.delegate;
14 |
15 | import java.util.HashMap;
16 | import java.util.Map;
17 | import java.util.Random;
18 |
19 | import org.flowable.engine.delegate.DelegateExecution;
20 | import org.flowable.engine.delegate.JavaDelegate;
21 |
22 | public class SetVariablesDelegate implements JavaDelegate {
23 |
24 | private static final Random random = new Random();
25 |
26 | @Override
27 | public void execute(DelegateExecution delegateExecution) {
28 | Map variables = new HashMap<>();
29 | for (int i = 0; i < 10; i++) {
30 | if (random.nextBoolean()) {
31 | variables.put("delegateStringVariable_" + delegateExecution.getId() + "_" + i, i*100 + "");
32 | } else {
33 | variables.put("delegateIntVariable_" + delegateExecution.getId() + "_" + i, i*100);
34 | }
35 | }
36 | delegateExecution.setVariables(variables);
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/async-history/async-history-default-cfg/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 | 4.0.0
5 |
6 | Flowable Examples - Async History Default Configuration
7 | flowable-async-history-default-cfg
8 | jar
9 |
10 |
11 | org.flowable.examples
12 | flowable-async-history-examples
13 | 1.0
14 |
15 |
16 |
17 | 1.8
18 | 1.8
19 |
20 |
21 |
22 |
23 |
24 | org.flowable
25 | flowable-engine
26 | ${flowable.version}
27 |
28 |
29 | org.flowable
30 | flowable-spring
31 | ${flowable.version}
32 |
33 |
34 |
35 | com.h2database
36 | h2
37 | 1.3.176
38 |
39 |
40 |
41 | com.zaxxer
42 | HikariCP
43 | 2.6.3
44 |
45 |
46 |
47 |
48 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-process-mongo/src/main/resources/demo-app/form-loanin.form:
--------------------------------------------------------------------------------
1 | {"name":"Loan Application","key":"loanin","version":0,"fields":[{"fieldType":"FormField","id":"fullname","name":"Fullname:","type":"text","value":null,"required":false,"readOnly":true,"overrideId":false,"placeholder":"","layout":null},{"fieldType":"FormField","id":"loan","name":"Requested loan","type":"integer","value":null,"required":true,"readOnly":false,"overrideId":true,"placeholder":"Loan amount requested...","layout":null},{"fieldType":"OptionFormField","id":"home","name":"Home","type":"radio-buttons","value":"Rented","required":true,"readOnly":false,"overrideId":false,"placeholder":null,"layout":null,"optionType":null,"hasEmptyValue":null,"options":[{"id":null,"name":"Rented"},{"id":null,"name":"Mortgaged"},{"id":null,"name":"Owned"}]},{"fieldType":"FormField","id":"age","name":"Age","type":"integer","value":null,"required":true,"readOnly":false,"overrideId":false,"placeholder":null,"layout":null},{"fieldType":"OptionFormField","id":"nationality","name":"Nationality","type":"dropdown","value":"Please choose one...","required":true,"readOnly":false,"overrideId":false,"placeholder":null,"layout":null,"optionType":null,"hasEmptyValue":true,"options":[{"id":null,"name":"Please choose one..."},{"id":null,"name":"Belgian"},{"id":null,"name":"Dutch"},{"id":null,"name":"French"},{"id":null,"name":"German"},{"id":null,"name":"Italian"},{"id":null,"name":"Spanish"},{"id":null,"name":"UK"},{"id":null,"name":"Other"}]},{"fieldType":"FormField","id":"income","name":"Income","type":"integer","value":null,"required":true,"readOnly":false,"overrideId":false,"placeholder":"Total current income...","layout":null}],"outcomes":[]}
--------------------------------------------------------------------------------
/blog/2022-11-ms-exchange-online-modern-auth/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
5 | 4.0.0
6 |
7 | org.flowable.example.blog
8 | 2022-11-ms-exchange-online-modern-auth-testtool
9 | 0.1.0-SNAPSHOT
10 |
11 | ms-exchange-online-modern-auth
12 | https://www.flowable.com/blog/office-365-exchange-oauth2-imap-authentication?slug=blog/office-365-exchange-oauth2-imap-authentication
13 |
14 |
15 | UTF-8
16 | 11
17 | 11
18 |
19 |
20 |
21 |
22 | info.picocli
23 | picocli
24 | 4.6.3
25 |
26 |
27 | com.microsoft.azure
28 | msal4j
29 | 1.13.2
30 |
31 |
32 | com.sun.mail
33 | jakarta.mail
34 | 1.6.7
35 |
36 |
37 | org.slf4j
38 | slf4j-simple
39 | 1.7.36
40 |
41 |
42 |
43 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/stationMapForm.scss:
--------------------------------------------------------------------------------
1 | .flw-stationMap-form {
2 | position: absolute;
3 | z-index: 99999;
4 | bottom: 50px;
5 | right: 35px;
6 | width: 390px;
7 | background: #fff;
8 | border-radius: 10px;
9 | overflow: hidden;
10 | padding: 20px;
11 | box-shadow: 0 5px 10px 0 rgba(0,0,0,.1);
12 | color: #555;
13 | .flw-rating {
14 | .flw-star {
15 | margin-right: 5px;
16 | width: 30px;
17 | height: 30px;
18 | }
19 | }
20 | &__title {
21 | width: 100%;
22 | display: block;
23 | font-size: 25px;
24 | line-height: 1.2;
25 | text-align: center;
26 | }
27 | &__label {
28 | font-size: 15px;
29 | line-height: 1.5;
30 | padding: 13px 0 9px 0;
31 | }
32 | &__input {
33 | width: 100%;
34 | position: relative;
35 | background-color: #f7f7f7;
36 | border: 1px solid #e6e6e6;
37 | border-radius: 10px;
38 | display: flex;
39 | input, textarea {
40 | width: 100%;
41 | color: #333;
42 | line-height: 1.2;
43 | font-size: 18px;
44 | display: block;
45 | outline: none;
46 | border: none;
47 | background: 0 0;
48 | height: 40px;
49 | padding: 0px 20px;
50 | }
51 | textarea {
52 | height: 100px;
53 | padding: 10px 20px;
54 | }
55 | }
56 | button {
57 | margin-top: 17px;
58 | cursor: pointer;
59 | display: flex;
60 | justify-content: center;
61 | align-items: center;
62 | padding: 0 20px;
63 | width: 100%;
64 | height: 50px;
65 | background-color: #333;
66 | border-radius: 10px;
67 | font-size: 16px;
68 | color: #fff;
69 | line-height: 1.2;
70 | &:disabled {
71 | opacity: 0.4;
72 | }
73 | }
74 | }
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-decision-analysis/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 | 4.0.0
5 |
6 | demo-decision-analysis
7 | 1.0-SNAPSHOT
8 | jar
9 |
10 |
11 | org.springframework.boot
12 | spring-boot-starter-parent
13 | 2.0.5.RELEASE
14 |
15 |
16 |
17 |
18 | 1.8
19 | 1.8
20 | 3.8.2
21 |
22 |
23 |
24 |
25 |
26 | org.springframework.boot
27 | spring-boot-starter-web
28 |
29 |
30 |
31 | org.flowable
32 | flowable-process-engine-mongodb
33 | 6.4.0.alpha2-SNAPSHOT
34 |
35 |
36 |
37 |
38 | org.apache.spark
39 | spark-launcher_2.10
40 | 2.2.0
41 |
42 |
43 |
44 |
45 |
46 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "citybikes",
3 | "version": "0.1.0",
4 | "private": true,
5 | "dependencies": {
6 | "@types/classnames": "^2.2.9",
7 | "@types/faker": "^4.1.7",
8 | "@types/jest": "24.0.18",
9 | "@types/node": "12.7.11",
10 | "@types/react": "16.9.5",
11 | "@types/react-dom": "16.9.1",
12 | "@types/react-router-dom": "^5.1.1",
13 | "apexcharts": "^3.10.1",
14 | "classnames": "^2.2.6",
15 | "faker": "^4.1.0",
16 | "keycode": "^2.2.0",
17 | "mapbox-gl": "^1.4.0",
18 | "moment": "^2.24.0",
19 | "node-sass": "^4.13.0",
20 | "react": "^16.10.2",
21 | "react-apexcharts": "^1.3.3",
22 | "react-chartjs-2": "^2.8.0",
23 | "react-dom": "^16.10.2",
24 | "react-mapbox-gl": "^4.6.1",
25 | "react-router-dom": "^5.1.2",
26 | "react-scripts": "3.2.0",
27 | "styled-components": "^4.4.1",
28 | "typescript": "3.6.3",
29 | "xml2js": "^0.4.22"
30 | },
31 | "scripts": {
32 | "start": "react-scripts start",
33 | "build": "react-scripts build",
34 | "test": "react-scripts test",
35 | "eject": "react-scripts eject"
36 | },
37 | "eslintConfig": {
38 | "extends": "react-app"
39 | },
40 | "browserslist": {
41 | "production": [
42 | ">0.2%",
43 | "not dead",
44 | "not op_mini all"
45 | ],
46 | "development": [
47 | "last 1 chrome version",
48 | "last 1 firefox version",
49 | "last 1 safari version"
50 | ]
51 | },
52 | "devDependencies": {
53 | "@types/es6-promisify": "^6.0.0",
54 | "@types/mapbox-gl": "^0.54.4",
55 | "@types/styled-components": "^4.1.19",
56 | "@types/xml2js": "^0.4.5",
57 | "es6-promisify": "^6.0.2"
58 | },
59 | "proxy": "http://localhost:8090"
60 | }
61 |
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/README.md:
--------------------------------------------------------------------------------
1 | ## Build your own Flowable Spring Boot Application
2 |
3 | This application is a demo application showcasing how one can build their own custom Flowable Spring Boot application.
4 |
5 |
6 | Steps to create the demo application
7 |
8 | 1. Go to [start.spring.io](https://start.spring.io)
9 | 1. Pick the dependencies you need (web, h2, actuator, security, devtools)
10 |
11 | With these steps you will have a full fledged Spring Boot application
12 |
13 | See the [`application.properties`](src/main/resources/application.properties) for some customizations.
14 |
15 | Convert this application to a Flowable Spring Boot application:
16 |
17 | 1. Add `flowable-spring-boot-starter` or `flowable-spring-boot-starter-rest` (the second one exposes the Flowable REST API)
18 | 1. Add some custom endpoints that use the Flowable services
19 | 1. `HelloController` - Example controller that says hello
20 | 1. `DefinitionsController` - Get a list of the latest deployed process keys
21 | 1. Customize the security of the application (`SecurityConfiguration`)
22 | 1. Add `UserCreatorCommandLineRunner` - creates users in the Flowable IDM engine so you can login
23 | 1. Customize the engine through defining bean `EngineConfigurationConfigurer`
24 | 1. Add some DMN and BPMN resources (they will be auto deployed when they are in the appropriate folder)
25 | 1. Add `spring-cloud-starter-function-web` for exposing Spring Cloud functions and using Flowable Services
26 | 1. Add Function for calculating risk (see [risk](src/main/java/com/example/demoflowfest/risk) package for classes)
27 | 1. Add Consumer for consuming vacation request (see [vacation](src/main/java/com/example/demoflowfest/vacation) package for classes)
28 | 1. Add test for showing that everything works bundled togehter
--------------------------------------------------------------------------------
/async-history/async-history-rabbitmq-springboot-listener/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 | 4.0.0
5 |
6 | Flowable Examples - Async History RabbitMQ (AMPQ) Spring Boot Listener
7 | flowable-async-history-rabbitmq-springboot-listener
8 | jar
9 |
10 |
11 | org.springframework.boot
12 | spring-boot-starter-parent
13 | 1.5.4.RELEASE
14 |
15 |
16 |
17 | 1.8
18 | 1.8
19 | 6.1.1
20 |
21 |
22 |
23 |
24 | org.springframework.boot
25 | spring-boot-starter-amqp
26 |
27 |
28 |
29 | org.flowable
30 | flowable-engine
31 | ${flowable.version}
32 |
33 |
34 | org.flowable
35 | flowable-spring
36 | ${flowable.version}
37 |
38 |
39 |
40 | mysql
41 | mysql-connector-java
42 |
43 |
44 |
45 | com.zaxxer
46 | HikariCP
47 |
48 |
49 |
50 |
51 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-sentiment-analysis-app/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 | org.springframework.boot
7 | spring-boot-starter-parent
8 | 2.2.0.RELEASE
9 |
10 |
11 | 4.0.0
12 |
13 | event-demo-sentiment-analysis-app
14 |
15 |
16 | 1.8
17 |
18 |
19 |
20 |
21 | com.h2database
22 | h2
23 |
24 |
25 | org.springframework.boot
26 | spring-boot-starter
27 |
28 |
29 | com.amazonaws
30 | aws-java-sdk
31 | 1.11.661
32 |
33 |
34 | org.flowable
35 | event-demo-common
36 | 0.0.1-SNAPSHOT
37 |
38 |
39 |
40 |
41 |
42 |
43 | org.springframework.boot
44 | spring-boot-maven-plugin
45 |
46 |
47 |
48 |
49 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-hello-world/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 | 4.0.0
6 |
7 | org.flowable
8 | demo-hello-world
9 | 1.0-SNAPSHOT
10 |
11 |
12 | org.springframework.boot
13 | spring-boot-starter-parent
14 | 2.0.5.RELEASE
15 |
16 |
17 |
18 |
19 | UTF-8
20 | UTF-8
21 | 1.8
22 |
23 |
24 |
25 |
26 | org.springframework.boot
27 | spring-boot-starter-web
28 |
29 |
30 | com.h2database
31 | h2
32 |
33 |
34 | org.flowable
35 | flowable-spring-boot-starter
36 | 6.4.0
37 |
38 |
39 |
40 |
41 |
42 |
43 | org.springframework.boot
44 | spring-boot-maven-plugin
45 |
46 |
47 |
48 |
49 |
--------------------------------------------------------------------------------
/async-history/async-history-rabbitmq-cfg/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 | 4.0.0
5 |
6 | Flowable Examples - Async History RabbitMQ (AMPQ) Configuration
7 | flowable-async-history-rabbitmq-cfg
8 | jar
9 |
10 |
11 | org.flowable.examples
12 | flowable-async-history-examples
13 | 1.0
14 |
15 |
16 |
17 | 1.8
18 | 1.8
19 |
20 |
21 |
22 |
23 |
24 | org.flowable
25 | flowable-engine
26 | ${flowable.version}
27 |
28 |
29 | org.flowable
30 | flowable-spring
31 | ${flowable.version}
32 |
33 |
34 |
35 | mysql
36 | mysql-connector-java
37 | 5.1.42
38 |
39 |
40 |
41 | com.zaxxer
42 | HikariCP
43 | 2.6.3
44 |
45 |
46 |
47 |
48 | org.springframework.amqp
49 | spring-rabbit
50 | 1.7.3.RELEASE
51 |
52 |
53 |
54 |
55 |
56 |
--------------------------------------------------------------------------------
/flowable-kafka/frontend/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
12 |
13 |
17 |
18 |
27 | Flowable Demo
28 |
29 |
30 |
31 |
32 |
42 |
43 |
44 |
--------------------------------------------------------------------------------
/demo/demo-introducing-machine-learning/demo-decision-analysis/src/main/java/org/flowable/decision/SuggestionRestController.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.decision;
14 |
15 | import org.springframework.beans.factory.annotation.Autowired;
16 | import org.springframework.dao.IncorrectResultSizeDataAccessException;
17 | import org.springframework.jdbc.core.JdbcTemplate;
18 | import org.springframework.web.bind.annotation.GetMapping;
19 | import org.springframework.web.bind.annotation.PathVariable;
20 | import org.springframework.web.bind.annotation.RestController;
21 |
22 | /**
23 | * (Very) Quick-n-Dirty controller for exposing the results of the decision analysis.
24 | */
25 | @RestController
26 | public class SuggestionRestController {
27 |
28 | @Autowired
29 | private JdbcTemplate jdbcTemplate;
30 |
31 | @GetMapping("/suggestions/{taskKey}")
32 | public String getSuggestions(@PathVariable String taskKey) {
33 | try {
34 | return jdbcTemplate.queryForObject("SELECT RULES_ from RULES where TASK_KEY_ = ? order by TIME_STAMP_ desc LIMIT 1", new String[] { taskKey}, String.class);
35 | } catch (IncorrectResultSizeDataAccessException ire) {
36 | // ignore
37 | } catch (Exception e) {
38 | e.printStackTrace();
39 | }
40 | return "";
41 | }
42 |
43 | }
44 |
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/src/test/java/com/example/demoflowfest/risk/RiskCalculatorTest.java:
--------------------------------------------------------------------------------
1 | package com.example.demoflowfest.risk;
2 |
3 | import static net.javacrumbs.jsonunit.assertj.JsonAssertions.assertThatJson;
4 | import static org.assertj.core.api.Assertions.assertThat;
5 |
6 | import org.junit.jupiter.api.Test;
7 | import org.springframework.beans.factory.annotation.Autowired;
8 | import org.springframework.boot.test.context.SpringBootTest;
9 | import org.springframework.boot.test.web.client.TestRestTemplate;
10 | import org.springframework.http.HttpStatus;
11 | import org.springframework.http.ResponseEntity;
12 | import org.springframework.test.context.ActiveProfiles;
13 |
14 | import com.fasterxml.jackson.databind.ObjectMapper;
15 | import com.fasterxml.jackson.databind.node.ObjectNode;
16 |
17 | /**
18 | * @author Filip Hrisafov
19 | */
20 | @ActiveProfiles("test")
21 | @SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
22 | class RiskCalculatorTest {
23 |
24 | @Autowired
25 | private TestRestTemplate restTemplate;
26 |
27 | @Autowired
28 | private ObjectMapper objectMapper;
29 |
30 | @Test
31 | void calculateRisk() {
32 | ObjectNode request = objectMapper.createObjectNode();
33 |
34 | request.put("age", 18);
35 | request.put("category", "HIGH");
36 | request.put("debtReview", false);
37 |
38 | ResponseEntity response = restTemplate
39 | .withBasicAuth("flowfest", "test")
40 | .postForEntity("/riskCalculator", request, String.class);
41 |
42 | assertThat(response.getStatusCode()).as(response.toString()).isEqualTo(HttpStatus.OK);
43 |
44 | assertThatJson(response.getBody())
45 | .isEqualTo("{"
46 | + "reason:'High risk application',"
47 | + "reviewLevel:'LEVEL 1',"
48 | + "routing:'REFER'"
49 | + "}");
50 | }
51 | }
52 |
--------------------------------------------------------------------------------
/spring-boot-example/src/main/resources/forms/adjust-vacation-request.form:
--------------------------------------------------------------------------------
1 | {
2 | "name": "Adjust vacation request",
3 | "key": "adjust-vacation-request",
4 | "version": 0,
5 | "fields": [
6 | {
7 | "fieldType": "FormField",
8 | "id": "numberOfDays",
9 | "name": "Number of days",
10 | "type": "integer",
11 | "value": null,
12 | "required": true,
13 | "readOnly": false,
14 | "overrideId": true,
15 | "placeholder": null,
16 | "params": {
17 | "mask": ""
18 | },
19 | "layout": null
20 | },
21 | {
22 | "fieldType": "FormField",
23 | "id": "startDate",
24 | "name": "First day of holiday (dd-MM-yyy)",
25 | "type": "date",
26 | "value": null,
27 | "required": true,
28 | "readOnly": false,
29 | "overrideId": true,
30 | "placeholder": null,
31 | "layout": null
32 | },
33 | {
34 | "fieldType": "FormField",
35 | "id": "vacationMotivation",
36 | "name": "Motivation",
37 | "type": "multi-line-text",
38 | "value": null,
39 | "required": false,
40 | "readOnly": false,
41 | "overrideId": true,
42 | "placeholder": null,
43 | "layout": null
44 | },
45 | {
46 | "fieldType": "OptionFormField",
47 | "id": "resendRequest",
48 | "name": "Resend vacation request to manager?",
49 | "type": "radio-buttons",
50 | "value": "Yes",
51 | "required": true,
52 | "readOnly": false,
53 | "overrideId": true,
54 | "placeholder": null,
55 | "layout": null,
56 | "optionType": null,
57 | "hasEmptyValue": null,
58 | "options": [
59 | {
60 | "id": null,
61 | "name": "Yes"
62 | },
63 | {
64 | "id": null,
65 | "name": "No"
66 | }
67 | ],
68 | "optionsExpression": null
69 | }
70 | ],
71 | "outcomes": []
72 | }
73 |
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/src/main/java/com/example/demoflowfest/UserCreatorCommandLineRunner.java:
--------------------------------------------------------------------------------
1 | package com.example.demoflowfest;
2 |
3 | import org.flowable.idm.api.IdmIdentityService;
4 | import org.flowable.idm.api.Privilege;
5 | import org.flowable.idm.api.User;
6 | import org.springframework.boot.CommandLineRunner;
7 | import org.springframework.stereotype.Component;
8 |
9 | /**
10 | * @author Filip Hrisafov
11 | */
12 | @Component
13 | public class UserCreatorCommandLineRunner implements CommandLineRunner {
14 |
15 | protected final IdmIdentityService idmIdentityService;
16 |
17 | public UserCreatorCommandLineRunner(IdmIdentityService idmIdentityService) {
18 | this.idmIdentityService = idmIdentityService;
19 | }
20 |
21 | @Override
22 | public void run(String... args) {
23 | createUserIfNotExists("flowfest");
24 | createUserIfNotExists("flowfest-actuator");
25 | createUserIfNotExists("flowfest-rest");
26 |
27 | if (idmIdentityService.createPrivilegeQuery().privilegeName("ROLE_REST").count() == 0) {
28 | Privilege restPrivilege = idmIdentityService.createPrivilege("ROLE_REST");
29 | idmIdentityService.addUserPrivilegeMapping(restPrivilege.getId(), "flowfest-rest");
30 | }
31 |
32 | if (idmIdentityService.createPrivilegeQuery().privilegeName("ROLE_ACTUATOR").count() == 0) {
33 | Privilege restPrivilege = idmIdentityService.createPrivilege("ROLE_ACTUATOR");
34 | idmIdentityService.addUserPrivilegeMapping(restPrivilege.getId(), "flowfest-actuator");
35 | }
36 | }
37 |
38 | protected void createUserIfNotExists(String username) {
39 | if (idmIdentityService.createUserQuery().userId(username).count() == 0) {
40 | User user = idmIdentityService.newUser(username);
41 | user.setPassword("test");
42 | idmIdentityService.saveUser(user);
43 | }
44 | }
45 | }
46 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-customer-case-app/src/main/java/org/flowable/eventdemo/controller/ReviewEventCounter.java:
--------------------------------------------------------------------------------
1 | package org.flowable.eventdemo.controller;
2 |
3 | import java.util.Objects;
4 | import java.util.concurrent.atomic.AtomicLong;
5 |
6 | import org.flowable.common.engine.api.FlowableIllegalArgumentException;
7 | import org.flowable.eventregistry.api.EventRegistryEvent;
8 | import org.flowable.eventregistry.api.EventRegistryEventConsumer;
9 | import org.flowable.eventregistry.api.runtime.EventInstance;
10 | import org.flowable.eventregistry.model.EventModel;
11 | import org.springframework.stereotype.Service;
12 |
13 | /**
14 | * @author Filip Hrisafov
15 | */
16 | @Service
17 | public class ReviewEventCounter implements EventRegistryEventConsumer {
18 |
19 | private final AtomicLong eventCounter = new AtomicLong(0);
20 |
21 | public long getEventCount() {
22 | return eventCounter.get();
23 | }
24 |
25 | protected void eventReceived(EventInstance eventInstance) {
26 | EventModel eventModel = eventInstance.getEventModel();
27 | if (Objects.equals("reviewEvent", eventModel.getKey())) {
28 | eventCounter.incrementAndGet();
29 | }
30 | }
31 |
32 | @Override
33 | public void eventReceived(EventRegistryEvent event) {
34 | if (event.getEventObject() != null && event.getEventObject() instanceof EventInstance) {
35 | eventReceived((EventInstance) event.getEventObject());
36 | } else {
37 | if (event.getEventObject() == null) {
38 | throw new FlowableIllegalArgumentException("No event object was passed to the consumer");
39 | } else {
40 | throw new FlowableIllegalArgumentException("Unsupported event object type: " + event.getEventObject().getClass());
41 | }
42 | }
43 | }
44 |
45 | @Override
46 | public String getConsumerKey() {
47 | return "reviewEventConsumer";
48 | }
49 | }
50 |
--------------------------------------------------------------------------------
/blog/2022-02-flowable-spring-native/src/main/java/com/example/demo/ProcessEngineCustomConfiguration.java:
--------------------------------------------------------------------------------
1 | package com.example.demo;
2 |
3 | import java.util.ArrayList;
4 | import java.util.Collections;
5 | import java.util.List;
6 |
7 | import org.flowable.spring.SpringProcessEngineConfiguration;
8 | import org.flowable.spring.boot.EngineConfigurationConfigurer;
9 | import org.flowable.spring.boot.FlowableProperties;
10 | import org.flowable.spring.boot.process.FlowableProcessProperties;
11 | import org.springframework.context.annotation.Bean;
12 | import org.springframework.context.annotation.Configuration;
13 | import org.springframework.core.io.ClassPathResource;
14 | import org.springframework.core.io.Resource;
15 |
16 | /**
17 | * @author Filip Hrisafov
18 | * @author Joram Barrez
19 | */
20 | @Configuration(proxyBeanMethods = false)
21 | public class ProcessEngineCustomConfiguration {
22 |
23 | @Bean
24 | public EngineConfigurationConfigurer processEngineConfigurationConfigurer(FlowableProperties processProperties) {
25 | return engineConfiguration -> {
26 | // For some reason the auto deployment is not working, so we manually do it.
27 | if (processProperties.isCheckProcessDefinitions()) {
28 | Resource[] resources = engineConfiguration.getDeploymentResources();
29 | List resourceList = new ArrayList<>();
30 | Collections.addAll(resourceList, resources);
31 | resourceList.add(new ClassPathResource("processes/oneTaskProcess.bpmn20.xml"));
32 | resourceList.add(new ClassPathResource("processes/oneServiceTaskDelegateProcess.bpmn20.xml"));
33 | engineConfiguration.setDeploymentResources(resourceList.toArray(new Resource[0]));
34 | }
35 |
36 | engineConfiguration.setValidateFlowable5EntitiesEnabled(false);
37 | engineConfiguration.setEnableConfiguratorServiceLoader(false);
38 | };
39 | }
40 |
41 | }
42 |
--------------------------------------------------------------------------------
/async-history/async-history-jms-cfg/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 | 4.0.0
5 |
6 | Flowable Examples - Async History JMS Configuration
7 | flowable-async-history-jms-cfg
8 | jar
9 |
10 |
11 | org.flowable.examples
12 | flowable-async-history-examples
13 | 1.0
14 |
15 |
16 |
17 | 1.8
18 | 1.8
19 |
20 |
21 |
22 |
23 |
24 | org.flowable
25 | flowable-engine
26 | ${flowable.version}
27 |
28 |
29 | org.flowable
30 | flowable-spring
31 | ${flowable.version}
32 |
33 |
34 |
35 | com.h2database
36 | h2
37 | 1.3.176
38 |
39 |
40 |
41 | com.zaxxer
42 | HikariCP
43 | 2.6.3
44 |
45 |
46 |
47 |
48 | org.flowable
49 | flowable-jms-spring-executor
50 | ${flowable.version}
51 |
52 |
53 | org.apache.activemq
54 | activemq-broker
55 | 5.13.3
56 |
57 |
58 |
59 |
60 |
--------------------------------------------------------------------------------
/flowable-intro/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 | 4.0.0
5 |
6 | Flowable Intro
7 | org.flowable.examples
8 | flowable-intro
9 | jar
10 | 1.0
11 |
12 |
13 | 6.1.1
14 |
15 |
16 |
17 |
18 |
19 | org.flowable
20 | flowable-engine
21 | ${flowable.version}
22 |
23 |
24 | org.flowable
25 | flowable5-compatibility
26 | ${flowable.version}
27 |
28 |
29 | org.flowable
30 | flowable-dmn-engine
31 | ${flowable.version}
32 |
33 |
34 | org.flowable
35 | flowable-dmn-engine-configurator
36 | ${flowable.version}
37 |
38 |
39 | com.h2database
40 | h2
41 | 1.3.176
42 |
43 |
44 | org.slf4j
45 | slf4j-api
46 | 1.7.6
47 |
48 |
49 | org.slf4j
50 | slf4j-log4j12
51 | 1.7.6
52 |
53 |
54 | junit
55 | junit
56 | 4.12
57 | test
58 |
59 |
60 |
61 |
62 |
63 |
--------------------------------------------------------------------------------
/flowable-kafka/README.md:
--------------------------------------------------------------------------------
1 | # Flowable Kafka Event Example
2 |
3 | This is an example project that demonstrates how the Flowable Event Registry works with Kafka.
4 | It shows how one can create an architecture as in the video [Flowable business processing from Kafka events](https://www.youtube.com/watch?v=nX0dRiPqOmk) from Devoxx 2019
5 |
6 | ## Setup
7 |
8 | Download and run Kafka.
9 | Create the following topics: sentiment-analysis, sentiment-analysis-results and reviews
10 |
11 | Create a postgres database named `eventdemo` with user and pass as flowable.
12 |
13 | This is needed for the `CustomerCaseApplication`.
14 | If you want to use another database then change the `spring.datasource.url` in the [application.properties](event-demo-customer-case-app/src/main/resources/application.properties).
15 |
16 | ## Architecture
17 |
18 | There are 4 applications:
19 |
20 | * [`ApiGatewayApplication`](event-demo-api-gateway/src/main/java/org/flowable/eventdemo/ApiGatewayApplication.java) - A Spring Cloud Gateway for redirecting the API calls
21 | * [`CustomerCaseApplication`](event-demo-customer-case-app/src/main/java/org/flowable/eventdemo/CustomerCaseApplication.java) - An embedded Flowable Application for customer review management. Uses postgres as a database
22 | * [`SentimentAnalysisApplication`](event-demo-sentiment-analysis-app/src/main/java/org/flowable/eventdemo/sentiment/SentimentAnalysisApplication.java) - An embedded Flowable Application which performs Sentiment Analysis (different than the `CustomerCaseApplication`). Uses in memory h2 as a database
23 | * [`ReviewApplication`](event-demo-review-app/src/main/java/org/flowable/eventdemo/review/ReviewApplication.java) - Reactive Review application responsible for streaming the reviews to Kafka
24 |
25 | ## Frontend
26 |
27 | There is a small frontend in the [frontend](frontend) directory.
28 |
29 | Run the following commands to start it:
30 |
31 | ```sh
32 | cd frontend
33 | yarn install
34 | yarn start
35 | ```
36 |
37 | This starts a UI on [localhost:3000](http://localhost:3000) and a dashboard at [localhost:3000/#dashboard](http://localhost:3000/#dashboard)
38 |
--------------------------------------------------------------------------------
/spring-boot-example/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 | 4.0.0
5 |
6 | org.flowable.examples
7 | flowable-spring-boot-example
8 | 0.0.1-SNAPSHOT
9 | jar
10 |
11 | flowable-spring-boot-example
12 | Flowable example for Spring Boot
13 |
14 |
15 | org.springframework.boot
16 | spring-boot-starter-parent
17 | 2.0.0.RELEASE
18 |
19 |
20 |
21 |
22 | UTF-8
23 | UTF-8
24 | 1.8
25 |
26 |
27 |
28 |
29 | org.springframework.boot
30 | spring-boot-starter-actuator
31 |
32 |
33 | org.springframework.boot
34 | spring-boot-starter-web
35 |
36 |
37 |
38 | com.h2database
39 | h2
40 |
41 |
42 |
43 | org.flowable
44 | flowable-spring-boot-starter-rest
45 | 6.3.1
46 |
47 |
48 |
49 | org.springframework.boot
50 | spring-boot-starter-test
51 | test
52 |
53 |
54 |
55 |
56 |
57 |
58 | org.springframework.boot
59 | spring-boot-maven-plugin
60 |
61 |
62 |
63 |
64 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-process-mongo/src/main/java/org/flowable/ProcessApplication.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable;
14 |
15 | import org.flowable.common.engine.impl.history.HistoryLevel;
16 | import org.flowable.engine.ProcessEngine;
17 | import org.flowable.engine.ProcessEngineConfiguration;
18 | import org.flowable.mongodb.cfg.MongoDbProcessEngineConfiguration;
19 | import org.springframework.boot.SpringApplication;
20 | import org.springframework.boot.autoconfigure.SpringBootApplication;
21 | import org.springframework.context.annotation.Bean;
22 | import org.springframework.context.annotation.ComponentScan;
23 | import org.springframework.scheduling.annotation.EnableAsync;
24 |
25 | /**
26 | * @author Joram Barrez
27 | */
28 | @SpringBootApplication
29 | @EnableAsync
30 | @ComponentScan("org.flowable.demo")
31 | public class ProcessApplication {
32 |
33 | @Bean
34 | public ProcessEngineConfiguration processEngineConfiguration() {
35 | return new MongoDbProcessEngineConfiguration()
36 | .setConnectionUrl("localhost:27017")
37 | .setDisableIdmEngine(true)
38 | .setDatabaseSchemaUpdate(MongoDbProcessEngineConfiguration.DB_SCHEMA_UPDATE_TRUE)
39 | .setHistoryLevel(HistoryLevel.AUDIT);
40 | }
41 |
42 | @Bean
43 | public ProcessEngine processEngine() {
44 | return processEngineConfiguration().buildProcessEngine();
45 | }
46 |
47 | public static void main(String[] args) throws InterruptedException {
48 | SpringApplication.run(ProcessApplication.class, args);
49 | }
50 |
51 | }
52 |
--------------------------------------------------------------------------------
/blog/migration-bpmn/src/main/java/com/example/reservation/app/migration/MigrationReservationServiceImpl.java:
--------------------------------------------------------------------------------
1 | package com.example.reservation.app.migration;
2 |
3 | import java.util.List;
4 |
5 | import org.flowable.engine.RepositoryService;
6 | import org.flowable.engine.RuntimeService;
7 | import org.flowable.engine.migration.ActivityMigrationMapping;
8 | import org.flowable.engine.repository.ProcessDefinition;
9 | import org.flowable.engine.runtime.ProcessInstance;
10 | import org.springframework.stereotype.Service;
11 |
12 | /**
13 | * @author Simon Amport
14 | */
15 | @Service("migrationReservationService")
16 | public class MigrationReservationServiceImpl implements MigrationReservationService {
17 |
18 | private final String PROCESS_DEFINITION_KEY = "P001-tableReservation";
19 |
20 | private final RepositoryService repositoryService;
21 | private final RuntimeService runtimeService;
22 |
23 | public MigrationReservationServiceImpl(RepositoryService repositoryService, RuntimeService runtimeService) {
24 | this.repositoryService = repositoryService;
25 | this.runtimeService = runtimeService;
26 | }
27 |
28 | @Override
29 | public void migrateProcessInstancesToLatestDefinition() {
30 | List processInstances = runtimeService.createProcessInstanceQuery().processDefinitionKey(PROCESS_DEFINITION_KEY).list();
31 |
32 | // Get the latest process definition
33 | ProcessDefinition latestProcessDefinition = repositoryService.createProcessDefinitionQuery()
34 | .processDefinitionKey(PROCESS_DEFINITION_KEY)
35 | .latestVersion()
36 | .singleResult();
37 |
38 | // Do migration
39 | for (ProcessInstance processInstance : processInstances) {
40 | runtimeService.createProcessInstanceMigrationBuilder()
41 | .migrateToProcessDefinition(latestProcessDefinition.getId())
42 | .withProcessInstanceVariable("customerEmail", "customer@email.com")
43 | .addActivityMigrationMapping(ActivityMigrationMapping.createMappingFor("intermediatetimereventcatching1", "emailtask1"))
44 | .migrate(processInstance.getId());
45 | }
46 |
47 | }
48 | }
49 |
--------------------------------------------------------------------------------
/async-history/async-history-jms-jta-cfg/src/main/java/org/flowable/JmsAsyncHistoryListener.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable;
14 |
15 | import java.util.List;
16 |
17 | import javax.jms.JMSException;
18 | import javax.jms.Message;
19 | import javax.jms.Session;
20 |
21 | import org.flowable.engine.impl.history.async.AsyncHistoryListener;
22 | import org.springframework.jms.core.JmsTemplate;
23 | import org.springframework.jms.core.MessageCreator;
24 |
25 | import com.fasterxml.jackson.core.JsonProcessingException;
26 | import com.fasterxml.jackson.databind.ObjectMapper;
27 | import com.fasterxml.jackson.databind.node.ObjectNode;
28 |
29 | public class JmsAsyncHistoryListener implements AsyncHistoryListener {
30 |
31 | protected JmsTemplate jmsTemplate;
32 |
33 | protected ObjectMapper objectMapper = new ObjectMapper();
34 |
35 | @Override
36 | public void historyDataGenerated(List historyObjectNodes) {
37 | try {
38 | final String msg = objectMapper.writeValueAsString(historyObjectNodes);
39 | jmsTemplate.send(new MessageCreator() {
40 |
41 | @Override
42 | public Message createMessage(Session session) throws JMSException {
43 | return session.createTextMessage(msg);
44 | }
45 |
46 | });
47 | } catch (JsonProcessingException e) {
48 | e.printStackTrace();
49 | }
50 | }
51 |
52 | public JmsTemplate getJmsTemplate() {
53 | return jmsTemplate;
54 | }
55 |
56 | public void setJmsTemplate(JmsTemplate jmsTemplate) {
57 | this.jmsTemplate = jmsTemplate;
58 | }
59 |
60 | }
61 |
--------------------------------------------------------------------------------
/blog/2022-02-flowable-spring-native/src/main/java/com/example/demo/DemoApplication.java:
--------------------------------------------------------------------------------
1 | package com.example.demo;
2 |
3 | import org.flowable.engine.ProcessEngine;
4 | import org.flowable.engine.RepositoryService;
5 | import org.flowable.engine.RuntimeService;
6 | import org.flowable.engine.TaskService;
7 | import org.flowable.engine.runtime.ProcessInstance;
8 | import org.slf4j.Logger;
9 | import org.slf4j.LoggerFactory;
10 | import org.springframework.boot.CommandLineRunner;
11 | import org.springframework.boot.SpringApplication;
12 | import org.springframework.boot.autoconfigure.SpringBootApplication;
13 | import org.springframework.context.annotation.Bean;
14 |
15 | @SpringBootApplication
16 | public class DemoApplication {
17 |
18 | public static final Logger LOGGER = LoggerFactory.getLogger(DemoApplication.class);
19 |
20 | public static void main(String[] args) {
21 | SpringApplication.run(DemoApplication.class, args);
22 | }
23 |
24 | @Bean
25 | public DemoDelegate demoDelegate() {
26 | return new DemoDelegate();
27 | }
28 |
29 | @Bean
30 | public CommandLineRunner commandLineRunner(RepositoryService repositoryService, RuntimeService runtimeService, TaskService taskService,
31 | ProcessEngine processEngine) {
32 | return args -> {
33 |
34 | repositoryService.createDeployment()
35 | .name("Native manual deployment")
36 | .addClasspathResource("processes/oneTaskProcess.bpmn20.xml")
37 | .addClasspathResource("processes/oneServiceTaskDelegateProcess.bpmn20.xml")
38 | .deploy();
39 | ProcessInstance processInstance = runtimeService.createProcessInstanceBuilder()
40 | .processDefinitionKey("oneTaskProcess")
41 | .start();
42 |
43 | LOGGER.info("Started process {}", processInstance.getProcessDefinitionKey());
44 |
45 | processInstance = runtimeService.createProcessInstanceBuilder()
46 | .processDefinitionKey("oneServiceTaskDelegateProcess")
47 | .variable("user", "Test")
48 | .start();
49 |
50 | LOGGER.info("There are {} tasks", taskService.createTaskQuery().count());
51 | };
52 | }
53 |
54 | }
55 |
--------------------------------------------------------------------------------
/flowfest-2018/demo-own-application/src/main/java/com/example/demoflowfest/SecurityConfiguration.java:
--------------------------------------------------------------------------------
1 | package com.example.demoflowfest;
2 |
3 | import org.springframework.boot.actuate.autoconfigure.security.servlet.EndpointRequest;
4 | import org.springframework.boot.actuate.health.HealthEndpoint;
5 | import org.springframework.boot.actuate.info.InfoEndpoint;
6 | import org.springframework.context.annotation.Bean;
7 | import org.springframework.context.annotation.Configuration;
8 | import org.springframework.security.config.annotation.web.builders.HttpSecurity;
9 | import org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter;
10 | import org.springframework.security.config.http.SessionCreationPolicy;
11 | import org.springframework.security.core.userdetails.User;
12 | import org.springframework.security.core.userdetails.UserDetails;
13 | import org.springframework.security.core.userdetails.UserDetailsService;
14 | import org.springframework.security.provisioning.InMemoryUserDetailsManager;
15 |
16 | /**
17 | * @author Filip Hrisafov
18 | */
19 | @Configuration
20 | public class SecurityConfiguration extends WebSecurityConfigurerAdapter {
21 |
22 | @Override
23 | protected void configure(HttpSecurity http) throws Exception {
24 | http
25 | .authorizeRequests()
26 | .requestMatchers(EndpointRequest.to(InfoEndpoint.class, HealthEndpoint.class)).permitAll()
27 | .requestMatchers(EndpointRequest.toAnyEndpoint()).hasRole("ACTUATOR")
28 | .antMatchers("/*-api/**").hasRole("REST")
29 | .anyRequest().authenticated()
30 | .and()
31 | .sessionManagement().sessionCreationPolicy(SessionCreationPolicy.NEVER).and()
32 | .csrf().disable()
33 | .httpBasic();
34 | }
35 |
36 | //@Bean
37 | public UserDetailsService customUserDetailsService() {
38 | UserDetails user1 = User.withUsername("custom-actuator")
39 | .password("{noop}test")
40 | .roles("ACTUATOR")
41 | .build();
42 |
43 | UserDetails user2 = User.withUsername("custom-rest")
44 | .password("{noop}test")
45 | .roles("REST")
46 | .build();
47 | return new InMemoryUserDetailsManager(user1, user2);
48 | }
49 | }
50 |
--------------------------------------------------------------------------------
/blog/04-2021-jobs/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 | 4.0.0
5 |
6 | org.springframework.boot
7 | spring-boot-starter-parent
8 | 2.4.2
9 |
10 |
11 | org.flowable
12 | jobapplication
13 | 0.0.1-SNAPSHOT
14 |
15 |
16 | 11
17 |
18 |
19 |
20 | org.springframework.boot
21 | spring-boot-starter
22 |
23 |
24 |
25 | org.postgresql
26 | postgresql
27 | runtime
28 |
29 |
30 |
31 | org.flowable
32 | flowable-spring-boot-starter-process
33 | 6.6.1-SNAPSHOT
34 |
35 |
36 |
37 | org.springframework.boot
38 | spring-boot-starter-test
39 | test
40 |
41 |
42 |
43 | com.oracle.database.jdbc
44 | ojdbc8
45 | 19.9.0.0
46 |
47 |
48 |
49 |
50 |
51 |
52 | org.springframework.boot
53 | spring-boot-maven-plugin
54 |
55 | org.flowable.jobs.JobsApplication
56 |
57 |
58 |
59 |
60 |
61 |
62 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-decision-analysis/src/main/java/org/flowable/DecisionAnalysisApplication.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable;
14 |
15 | import org.flowable.bpmn.model.BpmnModel;
16 | import org.flowable.common.engine.impl.history.HistoryLevel;
17 | import org.flowable.engine.ProcessEngine;
18 | import org.flowable.engine.ProcessEngineConfiguration;
19 | import org.flowable.mongodb.cfg.MongoDbProcessEngineConfiguration;
20 | import org.springframework.boot.SpringApplication;
21 | import org.springframework.boot.autoconfigure.SpringBootApplication;
22 | import org.springframework.context.annotation.Bean;
23 | import org.springframework.context.annotation.ComponentScan;
24 | import org.springframework.scheduling.annotation.EnableScheduling;
25 |
26 | /**
27 | * Decision Analysis Service: periodically analysis a {@link BpmnModel} and starts a Spark job to
28 | * determine the decision tree for a human task + form and outcomes.
29 | *
30 | * @author Joram Barrez
31 | */
32 | @SpringBootApplication
33 | @EnableScheduling
34 | @ComponentScan("org.flowable.decision")
35 | public class DecisionAnalysisApplication {
36 |
37 | @Bean
38 | public ProcessEngineConfiguration processEngineConfiguration() {
39 | return new MongoDbProcessEngineConfiguration()
40 | .setConnectionUrl("localhost:27017")
41 | .setDisableIdmEngine(true)
42 | .setDatabaseSchemaUpdate(MongoDbProcessEngineConfiguration.DB_SCHEMA_UPDATE_TRUE)
43 | .setHistoryLevel(HistoryLevel.AUDIT);
44 | }
45 |
46 | @Bean
47 | public ProcessEngine processEngine() {
48 | return processEngineConfiguration().buildProcessEngine();
49 | }
50 |
51 | public static void main(String[] args) {
52 | SpringApplication.run(DecisionAnalysisApplication.class, args);
53 | }
54 |
55 | }
56 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-spark/src/main/java/org/flowable/dto/Rule.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.dto;
14 |
15 | import java.util.LinkedList;
16 |
17 | /**
18 | * @author Joram Barrez
19 | */
20 | public class Rule {
21 |
22 | private LinkedList conditions = new LinkedList<>();
23 | private Object outcome;
24 | private double probability;
25 |
26 | public Rule() {
27 | }
28 |
29 | public void addConditionAsFirst(Condition condition) {
30 | conditions.addFirst(condition);
31 | }
32 |
33 | public LinkedList getConditions() {
34 | return conditions;
35 | }
36 |
37 | public void setConditions(LinkedList conditions) {
38 | this.conditions = conditions;
39 | }
40 |
41 | public Object getOutcome() {
42 | return outcome;
43 | }
44 |
45 | public void setOutcome(Object outcome) {
46 | this.outcome = outcome;
47 | }
48 |
49 | public double getProbability() {
50 | return probability;
51 | }
52 |
53 | public void setProbability(double probability) {
54 | this.probability = probability;
55 | }
56 |
57 | @Override
58 | public String toString() {
59 | StringBuilder stringBuilder = new StringBuilder();
60 | for (int i = 0; i < conditions.size(); i++) {
61 | stringBuilder.append(conditions.get(i).toString());
62 | if (i != conditions.size() - 1) {
63 | stringBuilder.append(" AND ");
64 | }
65 | }
66 | stringBuilder.append(" -> ");
67 | stringBuilder.append(outcome);
68 | stringBuilder.append(" (with probablity ");
69 | stringBuilder.append(String.format("%.2f", probability * 100) + "%");
70 | stringBuilder.append(")");
71 | return stringBuilder.toString();
72 | }
73 |
74 | }
--------------------------------------------------------------------------------
/demo/demo-introducing-machine-learning/demo-spark/src/main/java/org/flowable/dto/Rule.java:
--------------------------------------------------------------------------------
1 | /* Licensed under the Apache License, Version 2.0 (the "License");
2 | * you may not use this file except in compliance with the License.
3 | * You may obtain a copy of the License at
4 | *
5 | * http://www.apache.org/licenses/LICENSE-2.0
6 | *
7 | * Unless required by applicable law or agreed to in writing, software
8 | * distributed under the License is distributed on an "AS IS" BASIS,
9 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 | * See the License for the specific language governing permissions and
11 | * limitations under the License.
12 | */
13 | package org.flowable.dto;
14 |
15 | import java.util.LinkedList;
16 |
17 | /**
18 | * @author Joram Barrez
19 | */
20 | public class Rule {
21 |
22 | private LinkedList conditions = new LinkedList<>();
23 | private Object outcome;
24 | private double probability;
25 |
26 | public Rule() {
27 | }
28 |
29 | public void addConditionAsFirst(Condition condition) {
30 | conditions.addFirst(condition);
31 | }
32 |
33 | public LinkedList getConditions() {
34 | return conditions;
35 | }
36 |
37 | public void setConditions(LinkedList conditions) {
38 | this.conditions = conditions;
39 | }
40 |
41 | public Object getOutcome() {
42 | return outcome;
43 | }
44 |
45 | public void setOutcome(Object outcome) {
46 | this.outcome = outcome;
47 | }
48 |
49 | public double getProbability() {
50 | return probability;
51 | }
52 |
53 | public void setProbability(double probability) {
54 | this.probability = probability;
55 | }
56 |
57 | @Override
58 | public String toString() {
59 | StringBuilder stringBuilder = new StringBuilder();
60 | for (int i = 0; i < conditions.size(); i++) {
61 | stringBuilder.append(conditions.get(i).toString());
62 | if (i != conditions.size() - 1) {
63 | stringBuilder.append(" AND ");
64 | }
65 | }
66 | stringBuilder.append(" -> ");
67 | stringBuilder.append(outcome);
68 | stringBuilder.append(" (with probablity ");
69 | stringBuilder.append(String.format("%.2f", probability * 100) + "%");
70 | stringBuilder.append(")");
71 | return stringBuilder.toString();
72 | }
73 |
74 | }
--------------------------------------------------------------------------------
/flowable-kafka/frontend/src/DashBoard.tsx:
--------------------------------------------------------------------------------
1 | import React, { useState, useEffect } from 'react';
2 | import { ThemeProvider } from 'styled-components';
3 | import { getDashBoardData } from './api';
4 | import { LineChart } from './LineChart';
5 | import { GlobalStyles } from './GlobalStyle';
6 | import { Switch } from './Switch';
7 |
8 | import './dashBoard.scss';
9 |
10 | const lightTheme = {
11 | bodyBackground: '#fff',
12 | bodyColor: '#000'
13 | };
14 |
15 | const darkTheme = {
16 | bodyBackground: '#152642',
17 | bodyColor: '#777'
18 | };
19 |
20 | type DashBoardSerie = {
21 | [key: string]: number[][];
22 | };
23 |
24 | type DashBoardRes = {
25 | [key: string]: number;
26 | };
27 |
28 | type DashBoardProps = {};
29 |
30 | const titles: {
31 | [key: string]: string;
32 | } = {
33 | caseInstanceCount: 'Case Instance Count',
34 | processInstanceCount: 'Process Instance Count',
35 | taskCount: 'Tasks Count',
36 | reviewEventCount: 'Review Event Count'
37 | };
38 | export const DashBoard = (props: DashBoardProps) => {
39 | let [data, setFormData] = useState({
40 | caseInstanceCount: [],
41 | processInstanceCount: [],
42 | taskCount: [],
43 | reviewEventCount: []
44 | });
45 | let [count, setCount] = useState(0);
46 |
47 | const [theme, setTheme] = useState('dark');
48 | const toggleTheme = () => {
49 | if (theme === 'light') {
50 | setTheme('dark');
51 | } else {
52 | setTheme('light');
53 | }
54 | };
55 |
56 | useEffect(() => {
57 | let timeout = 2000;
58 |
59 | var timerID = setInterval(() => {
60 | setCount(count + 1);
61 | }, timeout);
62 |
63 | return function cleanup() {
64 | clearInterval(timerID);
65 | };
66 | });
67 |
68 | useEffect(() => {
69 | getDashBoardData().then((res: DashBoardRes) => {
70 | let newData = data;
71 | const date = new Date().getTime();
72 | Object.keys(data).forEach(v => newData[v].push([date, res[v]]));
73 | setFormData(newData);
74 | });
75 | }, [count]);
76 |
77 | return (
78 |
79 | <>
80 |
81 |
82 |
83 | {Object.keys(data).map(v => (
84 |
85 | ))}
86 |
87 | >
88 |
89 | );
90 | };
91 |
--------------------------------------------------------------------------------
/demo/demo-introducing-machine-learning/demo-listener/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 | 4.0.0
5 |
6 | demo-listener
7 | jar
8 |
9 |
10 | org.springframework.boot
11 | spring-boot-starter-parent
12 | 1.5.8.RELEASE
13 |
14 |
15 |
16 | 1.8
17 | 1.8
18 | 6.2.0
19 |
20 |
21 |
22 |
23 | org.springframework.boot
24 | spring-boot-starter-amqp
25 |
26 |
27 |
28 |
29 | org.flowable
30 | flowable-spring-boot-starter-basic
31 | ${flowable.version}
32 |
33 |
34 |
35 |
36 | mysql
37 | mysql-connector-java
38 |
39 |
40 |
41 |
42 |
43 | com.zaxxer
44 | HikariCP
45 |
46 |
47 |
48 |
49 | org.elasticsearch
50 | elasticsearch
51 | 5.6.3
52 |
53 |
54 | org.elasticsearch.client
55 | transport
56 | 5.6.3
57 |
58 |
59 |
60 |
61 | de.codecentric
62 | spring-boot-admin-starter-client
63 | 1.5.4
64 |
65 |
66 | org.springframework.boot
67 | spring-boot-starter-actuator
68 |
69 |
70 |
71 |
72 |
--------------------------------------------------------------------------------
/demo/demo-jax-2018/demo-process-mongo/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 | 4.0.0
6 |
7 | org.flowable
8 | demo-process-mongo
9 | 1.0-SNAPSHOT
10 |
11 |
12 | org.springframework.boot
13 | spring-boot-starter-parent
14 | 2.0.5.RELEASE
15 |
16 |
17 |
18 |
19 | UTF-8
20 | UTF-8
21 | 1.8
22 | 3.8.2
23 |
24 |
25 |
26 |
27 |
28 | org.springframework.boot
29 | spring-boot-starter
30 |
31 |
32 | org.mongodb
33 | mongodb-driver
34 |
35 |
36 |
37 |
38 | org.springframework.boot
39 | spring-boot-starter-web
40 |
41 |
42 |
43 | org.flowable
44 | flowable-process-engine-mongodb
45 | 6.4.0.alpha2-SNAPSHOT
46 |
47 |
48 |
49 | org.springframework.boot
50 | spring-boot-starter-test
51 | test
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 | org.springframework.boot
65 | spring-boot-maven-plugin
66 |
67 |
68 |
69 |
70 |
--------------------------------------------------------------------------------
/blog/migration-bpmn/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 | 4.0.0
6 |
7 |
8 | org.springframework.boot
9 | spring-boot-starter-parent
10 | 2.1.6.RELEASE
11 |
12 |
13 |
14 | com.example
15 | blog-bpmn-migration
16 | 1.0-SNAPSHOT
17 |
18 |
19 | 1.8
20 | 6.4.1
21 | 5.3.2
22 |
23 |
24 |
25 |
26 | org.flowable
27 | flowable-spring-boot-starter-process
28 | ${org.flowable.version}
29 |
30 |
31 | com.h2database
32 | h2
33 |
34 |
35 |
36 |
37 | org.springframework.boot
38 | spring-boot-starter-test
39 | test
40 |
41 |
42 | junit
43 | junit
44 |
45 |
46 |
47 |
48 | org.junit.jupiter
49 | junit-jupiter-engine
50 | ${org.junit.jupiter.version}
51 | test
52 |
53 |
54 | org.junit.jupiter
55 | junit-jupiter-params
56 | ${org.junit.jupiter.version}
57 | test
58 |
59 |
60 |
61 |
62 |
63 |
64 | org.springframework.boot
65 | spring-boot-maven-plugin
66 |
67 |
68 |
69 |
70 |
71 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-customer-case-app/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 | org.springframework.boot
7 | spring-boot-starter-parent
8 | 2.2.0.RELEASE
9 |
10 |
11 | 4.0.0
12 |
13 | event-demo-customer-case-app
14 |
15 |
16 | 1.8
17 |
18 |
19 |
20 |
21 | com.h2database
22 | h2
23 |
24 |
25 | org.postgresql
26 | postgresql
27 |
28 |
29 | org.springframework.boot
30 | spring-boot-starter-web
31 |
32 |
33 | org.springframework.boot
34 | spring-boot-starter-actuator
35 |
36 |
37 | org.flowable
38 | event-demo-common
39 | 0.0.1-SNAPSHOT
40 |
41 |
42 |
43 |
44 | org.springframework.boot
45 | spring-boot-starter-test
46 | test
47 |
48 |
49 | org.junit.vintage
50 | junit-vintage-engine
51 |
52 |
53 |
54 |
55 | org.springframework.kafka
56 | spring-kafka-test
57 | test
58 |
59 |
60 |
61 |
62 |
63 |
64 | org.springframework.boot
65 | spring-boot-maven-plugin
66 |
67 |
68 |
69 |
70 |
71 |
--------------------------------------------------------------------------------
/flowable-kafka/event-demo-api-gateway/pom.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 | org.springframework.boot
7 | spring-boot-starter-parent
8 | 2.2.0.RELEASE
9 |
10 |
11 | 4.0.0
12 |
13 | event-demo-api-gateway
14 |
15 |
16 | Hoxton.RC1
17 |
18 |
19 |
20 |
21 |
22 | org.springframework.cloud
23 | spring-cloud-dependencies
24 | ${spring.cloud.version}
25 | pom
26 | import
27 |
28 |
29 |
30 |
31 |
32 |
33 | org.springframework.cloud
34 | spring-cloud-starter-gateway
35 |
36 |
37 | org.springframework.cloud
38 | spring-cloud-starter-netflix-hystrix
39 |
40 |
41 | org.springframework.boot
42 | spring-boot-starter-actuator
43 | true
44 |
45 |
46 | org.springframework.boot
47 | spring-boot-devtools
48 | runtime
49 |
50 |
51 |
52 | org.springframework.boot
53 | spring-boot-configuration-processor
54 | true
55 |
56 |
57 |
58 | org.springframework.boot
59 | spring-boot-starter-test
60 | test
61 |
62 |
63 |
64 |
65 |
66 |
67 | org.springframework.boot
68 | spring-boot-maven-plugin
69 |
70 |
71 |
72 |
73 |
--------------------------------------------------------------------------------