From 0d4a1982bb51240606c33521fa438e4317553794 Mon Sep 17 00:00:00 2001 From: Alexander Ignatov Date: Thu, 14 Nov 2013 17:50:09 +0400 Subject: [PATCH] Added json REST samples for edp * Added data_source_create.json * Added job_binary_create.json * Added job_create.json * Added job_execute.json Change-Id: I2dc8ec4f1316c564d9d05374a153c11fd574f7d6 --- .../edp/data_source_create.json | 10 ++++++++++ .../edp/job_binary_create.json | 9 +++++++++ etc/rest-api-samples/edp/job_create.json | 7 +++++++ etc/rest-api-samples/edp/job_execute.json | 19 +++++++++++++++++++ 4 files changed, 45 insertions(+) create mode 100644 etc/rest-api-samples/edp/data_source_create.json create mode 100644 etc/rest-api-samples/edp/job_binary_create.json create mode 100644 etc/rest-api-samples/edp/job_create.json create mode 100644 etc/rest-api-samples/edp/job_execute.json diff --git a/etc/rest-api-samples/edp/data_source_create.json b/etc/rest-api-samples/edp/data_source_create.json new file mode 100644 index 00000000..bbb629e4 --- /dev/null +++ b/etc/rest-api-samples/edp/data_source_create.json @@ -0,0 +1,10 @@ +{ + "description": "This is input", + "url": "swift://container.savanna/text", + "credentials": { + "password": "swordfish", + "user": "admin" + }, + "type": "swift", + "name": "text" +} \ No newline at end of file diff --git a/etc/rest-api-samples/edp/job_binary_create.json b/etc/rest-api-samples/edp/job_binary_create.json new file mode 100644 index 00000000..582f7b42 --- /dev/null +++ b/etc/rest-api-samples/edp/job_binary_create.json @@ -0,0 +1,9 @@ +{ + "url": "swift-internal://container/jar-example.jar", + "name": "jar-example.jar", + "description": "This is job binary", + "extra": { + "password": "swordfish", + "user": "admin" + } +} \ No newline at end of file diff --git a/etc/rest-api-samples/edp/job_create.json b/etc/rest-api-samples/edp/job_create.json new file mode 100644 index 00000000..313bb7f3 --- /dev/null +++ b/etc/rest-api-samples/edp/job_create.json @@ -0,0 +1,7 @@ +{ + "description": "This is pig job example", + "mains": ["84248975-3c82-4206-a58d-6e7fb3a563fd"], + "libs": ["508fc62d-1d58-4412-b603-bdab307bb926"], + "type": "Pig", + "name": "pig-job-example" +} \ No newline at end of file diff --git a/etc/rest-api-samples/edp/job_execute.json b/etc/rest-api-samples/edp/job_execute.json new file mode 100644 index 00000000..5de3832e --- /dev/null +++ b/etc/rest-api-samples/edp/job_execute.json @@ -0,0 +1,19 @@ +{ + "cluster_id": "776e441b-5816-4d47-9e07-7ded58f9a5f6", + "input_id": "af7dc864-6331-4c30-80f5-63d74b667eaf", + "output_id": "b63780f3-13d7-4286-b731-88270fb204de", + "job_configs": { + "configs": { + "mapred.map.tasks": "1", + "mapred.reduce.tasks": "1" + }, + "args": { + "arg1": "val1", + "arg2": "val2" + }, + "params": { + "param2": "value2", + "param1": "value1" + } + } +} \ No newline at end of file