Hi Maciek,

Thanks a lot for your answer. The first step which I did was that I am able
execute flink job through flink REST API. Until flink job runs flowable
process instance checks the status of the process through the flink rest
API. Process instance continues further when the process ins finished.
I am working now on the example in which flink job at the end sends a
signal to the process instance (trough flowable REST API) and process
instance will continue in execution (I do not expect any issue there). In
that case flink job needs some additional code to send signal to flowable.

What I want to achieve is that there will be something like jobWrapper,
which will at the end of wrapped flink job execution send a signal to
flowable and process instance will continue. So original flink job does not
need any modification and can be easily integrated into process execution.


FlinkJobWrapper
______
|    OriginalFlinkJob
|  ____
|  |
|  |
|  |
|  L___
|  Send signal
L_____


Question is How to do that?

And that's all. (simulations are the next step)

Thank you in advance for your answer.
Regards
Martin

On 18 January 2018 at 19:30, Maciek Próchniak <m...@touk.pl> wrote:

> Hi Martin,
>
>
> I did some activiti development so your mail caught my attention :)
>
> I don't think I understand what are you trying to achieve - where is
> process you're simulating, where is simulation running and where is place
> for Flink. Do you want to invoke Flink (batch job I suppose?) from Flowable
> process? Or do you want to run simulations of BPMN process as Flink job?
>
> thanks,
>
> maciek
>
>
> On 16/01/2018 22:29, Martin Grofčík wrote:
>
> Hi,
>
> I want to implement flowable (BPMN platform  - www.flowable.org) <->
> flink integration module. The motivation is to execute process simulations
> with flink (simple simulation experiment example
> https://gromar01.wordpress.com/2017/11/07/will-we-meet-our-kpis/). I was
> able to create
>
>
> Flink provides REST API through which I can easily create a job and
> monitor its execution.
> wordCountProcess.PNG
> (15K)
>
> <https://mail.google.com/mail/ca/u/0/?ui=2&ik=b95e673dbd&view=att&th=16100d25b4542764&attid=0.1&disp=safe&realattid=f_jci4ya9t0&zw>
>
>
> at the end I can encapsulate whole process into one task (e.g. Execute
> flink job) which will do the same in java code.
> In fact I have no experience with flink that's why I can imagine only
> process steps to:
> 1. create flink job
> 2. monitor its state
>
> Question 1:
> Can you propose another useful process steps? (e.g.  to download results,
> upload datasets, .....)
> (Provide me a link how I can proceed with their implementation, please)
>
> Question 2:
> The problem with the process is that it is always checking job state. I
> would prefer to add a hook at the end of flink job execution to call
> flowable rest API to notify process instance about the job finished
> (failed....) events.
> The way which I have found is to implement rest end point org.apache.flink.
> runtime.webmonitor.handlers.JarPlanHandler which calls flowable rest api
> at the end of flink job execution.
> What I would prefer is to make something like wrapper around the main
> class to execute flowable rest call at the end.
> Can you provide me a hint how to implement this wrapper please?
>
> Thank you in advance for the answer.
>
> Regards
> Martin
>
>
>

Reply via email to