You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@flink.apache.org by wangziyu <23...@qq.com> on 2018/10/19 06:43:51 UTC

Monitoring/rest_api,The "/jobs" how to use?

Hi,
     I am learning Monitorong restful api [1]. I want to know how to use the
"/jobs"/Post. The request body need to enter some parameters.Like
"jobGraphFileName" ,"jobArtifactFileNames","jobJarFileNames".The three
parameters how to get them?
[1]:"https://ci.apache.org/projects/flink/flink-docs-release-1.6/monitoring/rest_api.html"
You can search "Submits a job. This call is primarily intended to be used by
the Flink client. This call expects amultipart/form-data request that
consists of file uploads for the serialized JobGraph, jars anddistributed
cache artifacts and an attribute named "request"for the JSON payload." to
know which api.
    Thanks !



--
Sent from: http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/

Re: Monitoring/rest_api,The "/jobs" how to use?

Posted by Chesnay Schepler <ch...@apache.org>.
Then I would suggest to use the FlinkClusterClient to submit jobs.

On 19.10.2018 11:02, Flavio Pompermaier wrote:
> Many times we had the need to have a special job (driver) that 
> orchestrate the other jobs.
> The problem in that is that it's not possible to create something like 
> a Flink context/session that allows to monitor its sub-jobs.
> I think that this thing would be extremely useful..an alternative 
> would be to use Oozie, Airflow or simliar but this would be more 
> straightforward IMHO.
>
> Best,
> Flavio
>
> On Fri, Oct 19, 2018 at 10:29 AM Chesnay Schepler <chesnay@apache.org 
> <ma...@apache.org>> wrote:
>
>     As the documentation states this is an effectively internal REST call
>     used by the CLI.
>
>     To submit jobs via REST I would suggest to check out the jar
>     submission
>     routine.
>
>     https://ci.apache.org/projects/flink/flink-docs-master/monitoring/rest_api.html#jars-upload
>     https://ci.apache.org/projects/flink/flink-docs-master/monitoring/rest_api.html#jars-jarid-run
>
>     On 19.10.2018 08:43, wangziyu wrote:
>     > Hi,
>     >       I am learning Monitorong restful api [1]. I want to know
>     how to use the
>     > "/jobs"/Post. The request body need to enter some parameters.Like
>     > "jobGraphFileName" ,"jobArtifactFileNames","jobJarFileNames".The
>     three
>     > parameters how to get them?
>     >
>     [1]:"https://ci.apache.org/projects/flink/flink-docs-release-1.6/monitoring/rest_api.html"
>     > You can search "Submits a job. This call is primarily intended
>     to be used by
>     > the Flink client. This call expects amultipart/form-data request
>     that
>     > consists of file uploads for the serialized JobGraph, jars
>     anddistributed
>     > cache artifacts and an attribute named "request"for the JSON
>     payload." to
>     > know which api.
>     >      Thanks !
>     >
>     >
>     >
>     > --
>     > Sent from:
>     http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/
>     >
>
>


Re: Monitoring/rest_api,The "/jobs" how to use?

Posted by Flavio Pompermaier <po...@okkam.it>.
Many times we had the need to have a special job (driver) that orchestrate
the other jobs.
The problem in that is that it's not possible to create something like a
Flink context/session that allows to monitor its sub-jobs.
I think that this thing would be extremely useful..an alternative would be
to use Oozie, Airflow or simliar but this would be more straightforward
IMHO.

Best,
Flavio

On Fri, Oct 19, 2018 at 10:29 AM Chesnay Schepler <ch...@apache.org>
wrote:

> As the documentation states this is an effectively internal REST call
> used by the CLI.
>
> To submit jobs via REST I would suggest to check out the jar submission
> routine.
>
>
> https://ci.apache.org/projects/flink/flink-docs-master/monitoring/rest_api.html#jars-upload
>
> https://ci.apache.org/projects/flink/flink-docs-master/monitoring/rest_api.html#jars-jarid-run
>
> On 19.10.2018 08:43, wangziyu wrote:
> > Hi,
> >       I am learning Monitorong restful api [1]. I want to know how to
> use the
> > "/jobs"/Post. The request body need to enter some parameters.Like
> > "jobGraphFileName" ,"jobArtifactFileNames","jobJarFileNames".The three
> > parameters how to get them?
> > [1]:"
> https://ci.apache.org/projects/flink/flink-docs-release-1.6/monitoring/rest_api.html
> "
> > You can search "Submits a job. This call is primarily intended to be
> used by
> > the Flink client. This call expects amultipart/form-data request that
> > consists of file uploads for the serialized JobGraph, jars anddistributed
> > cache artifacts and an attribute named "request"for the JSON payload." to
> > know which api.
> >      Thanks !
> >
> >
> >
> > --
> > Sent from:
> http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/
> >
>
>

Re: Monitoring/rest_api,The "/jobs" how to use?

Posted by Chesnay Schepler <ch...@apache.org>.
As the documentation states this is an effectively internal REST call 
used by the CLI.

To submit jobs via REST I would suggest to check out the jar submission 
routine.

https://ci.apache.org/projects/flink/flink-docs-master/monitoring/rest_api.html#jars-upload
https://ci.apache.org/projects/flink/flink-docs-master/monitoring/rest_api.html#jars-jarid-run

On 19.10.2018 08:43, wangziyu wrote:
> Hi,
>       I am learning Monitorong restful api [1]. I want to know how to use the
> "/jobs"/Post. The request body need to enter some parameters.Like
> "jobGraphFileName" ,"jobArtifactFileNames","jobJarFileNames".The three
> parameters how to get them?
> [1]:"https://ci.apache.org/projects/flink/flink-docs-release-1.6/monitoring/rest_api.html"
> You can search "Submits a job. This call is primarily intended to be used by
> the Flink client. This call expects amultipart/form-data request that
> consists of file uploads for the serialized JobGraph, jars anddistributed
> cache artifacts and an attribute named "request"for the JSON payload." to
> know which api.
>      Thanks !
>
>
>
> --
> Sent from: http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/
>