blob: 8e70b61a1614882b5593ab0da4aadeb57d8fe7ca [file] [log] [blame]
<html><body>
<style>
body, h1, h2, h3, div, span, p, pre, a {
margin: 0;
padding: 0;
border: 0;
font-weight: inherit;
font-style: inherit;
font-size: 100%;
font-family: inherit;
vertical-align: baseline;
}
body {
font-size: 13px;
padding: 1em;
}
h1 {
font-size: 26px;
margin-bottom: 1em;
}
h2 {
font-size: 24px;
margin-bottom: 1em;
}
h3 {
font-size: 20px;
margin-bottom: 1em;
margin-top: 1em;
}
pre, code {
line-height: 1.5;
font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
}
pre {
margin-top: 0.5em;
}
h1, h2, h3, p {
font-family: Arial, sans serif;
}
h1, h2, h3 {
border-bottom: solid #CCC 1px;
}
.toc_element {
margin-top: 0.5em;
}
.firstline {
margin-left: 2 em;
}
.method {
margin-top: 1em;
border: solid 1px #CCC;
padding: 1em;
background: #EEE;
}
.details {
font-weight: bold;
font-size: 14px;
}
</style>
<h1><a href="dataflow_v1beta3.html">Google Dataflow API</a> . <a href="dataflow_v1beta3.v1b3.html">v1b3</a> . <a href="dataflow_v1beta3.v1b3.projects.html">projects</a> . <a href="dataflow_v1beta3.v1b3.projects.jobs.html">jobs</a> . <a href="dataflow_v1beta3.v1b3.projects.jobs.workItems.html">workItems</a></h1>
<h2>Instance Methods</h2>
<p class="toc_element">
<code><a href="#lease">lease(projectId, jobId, body)</a></code></p>
<p class="firstline">Leases a dataflow WorkItem to run.</p>
<p class="toc_element">
<code><a href="#reportStatus">reportStatus(projectId, jobId, body)</a></code></p>
<p class="firstline">Reports the status of dataflow WorkItems leased by a worker.</p>
<h3>Method Details</h3>
<div class="method">
<code class="details" id="lease">lease(projectId, jobId, body)</code>
<pre>Leases a dataflow WorkItem to run.
Args:
projectId: string, A parameter (required)
jobId: string, A parameter (required)
body: object, The request body. (required)
The object takes the form of:
{
"requestedLeaseDuration": "A String",
"workItemTypes": [
"A String",
],
"workerCapabilities": [
"A String",
],
"currentWorkerTime": "A String",
"workerId": "A String",
}
Returns:
An object of the form:
{
"workItems": [
{
"configuration": "A String",
"leaseExpireTime": "A String",
"seqMapTask": {
"inputs": [
{
"sources": [
{
"codec": {
"a_key": "",
},
"baseSpecs": [
{
"a_key": "",
},
],
"spec": {
"a_key": "",
},
"doesNotNeedSplitting": True or False,
"metadata": {
"infinite": True or False,
"estimatedSizeBytes": "A String",
"producesSortedKeys": True or False,
},
},
],
"kind": {
"a_key": "",
},
"tag": "A String",
},
],
"name": "A String",
"stageName": "A String",
"systemName": "A String",
"userFn": {
"a_key": "",
},
"outputInfos": [
{
"tag": "A String",
"sink": {
"codec": {
"a_key": "",
},
"spec": {
"a_key": "",
},
},
},
],
},
"projectId": "A String",
"sourceOperationTask": {
"getMetadata": {
"source": {
"codec": {
"a_key": "",
},
"baseSpecs": [
{
"a_key": "",
},
],
"spec": {
"a_key": "",
},
"doesNotNeedSplitting": True or False,
"metadata": {
"infinite": True or False,
"estimatedSizeBytes": "A String",
"producesSortedKeys": True or False,
},
},
},
"split": {
"source": {
"codec": {
"a_key": "",
},
"baseSpecs": [
{
"a_key": "",
},
],
"spec": {
"a_key": "",
},
"doesNotNeedSplitting": True or False,
"metadata": {
"infinite": True or False,
"estimatedSizeBytes": "A String",
"producesSortedKeys": True or False,
},
},
"options": {
"desiredShardSizeBytes": "A String",
},
},
},
"mapTask": {
"systemName": "A String",
"stageName": "A String",
"instructions": [
{
"name": "A String",
"read": {
"source": {
"codec": {
"a_key": "",
},
"baseSpecs": [
{
"a_key": "",
},
],
"spec": {
"a_key": "",
},
"doesNotNeedSplitting": True or False,
"metadata": {
"infinite": True or False,
"estimatedSizeBytes": "A String",
"producesSortedKeys": True or False,
},
},
},
"outputs": [
{
"codec": {
"a_key": "",
},
"name": "A String",
},
],
"partialGroupByKey": {
"input": {
"outputNum": 42,
"producerInstructionIndex": 42,
},
"inputElementCodec": {
"a_key": "",
},
},
"write": {
"input": {
"outputNum": 42,
"producerInstructionIndex": 42,
},
"sink": {
"codec": {
"a_key": "",
},
"spec": {
"a_key": "",
},
},
},
"systemName": "A String",
"flatten": {
"inputs": [
{
"outputNum": 42,
"producerInstructionIndex": 42,
},
],
},
"parDo": {
"sideInputs": [
{
"sources": [
{
"codec": {
"a_key": "",
},
"baseSpecs": [
{
"a_key": "",
},
],
"spec": {
"a_key": "",
},
"doesNotNeedSplitting": True or False,
"metadata": {
"infinite": True or False,
"estimatedSizeBytes": "A String",
"producesSortedKeys": True or False,
},
},
],
"kind": {
"a_key": "",
},
"tag": "A String",
},
],
"input": {
"outputNum": 42,
"producerInstructionIndex": 42,
},
"multiOutputInfos": [
{
"tag": "A String",
},
],
"numOutputs": 42,
"userFn": {
"a_key": "",
},
},
},
],
},
"jobId": "A String",
"reportStatusInterval": "A String",
"streamingSetupTask": {
"workerHarnessPort": 42,
"streamingComputationTopology": {
"computations": [
{
"inputs": [
{
"streamingStageLocation": {
"streamId": "A String",
},
"pubsubLocation": {
"idLabel": "A String",
"topic": "A String",
"subscription": "A String",
"timestampLabel": "A String",
"dropLateData": True or False,
},
},
],
"computationId": "A String",
"keyRanges": [
{
"start": "A String",
"deliveryEndpoint": "A String",
"end": "A String",
"persistentDirectory": "A String",
"dataDisk": "A String",
},
],
"outputs": [
{
"streamingStageLocation": {
"streamId": "A String",
},
"pubsubLocation": {
"idLabel": "A String",
"topic": "A String",
"subscription": "A String",
"timestampLabel": "A String",
"dropLateData": True or False,
},
},
],
},
],
"dataDiskAssignments": [
{
"vmInstance": "A String",
"dataDisks": [
"A String",
],
},
],
},
"receiveWorkPort": 42,
},
"packages": [
{
"location": "A String",
"name": "A String",
},
],
"shellTask": {
"command": "A String",
"exitCode": 42,
},
"id": "A String",
},
],
}</pre>
</div>
<div class="method">
<code class="details" id="reportStatus">reportStatus(projectId, jobId, body)</code>
<pre>Reports the status of dataflow WorkItems leased by a worker.
Args:
projectId: string, A parameter (required)
jobId: string, A parameter (required)
body: object, The request body. (required)
The object takes the form of:
{
"workerId": "A String",
"currentWorkerTime": "A String",
"workItemStatuses": [
{
"reportIndex": "A String",
"errors": [
{
"message": "A String",
"code": 42,
"details": [
{
"a_key": "",
},
],
},
],
"sourceOperationResponse": {
"getMetadata": {
"metadata": {
"infinite": True or False,
"estimatedSizeBytes": "A String",
"producesSortedKeys": True or False,
},
},
"split": {
"outcome": "A String",
"shards": [
{
"derivationMode": "A String",
"source": {
"codec": {
"a_key": "",
},
"baseSpecs": [
{
"a_key": "",
},
],
"spec": {
"a_key": "",
},
"doesNotNeedSplitting": True or False,
"metadata": {
"infinite": True or False,
"estimatedSizeBytes": "A String",
"producesSortedKeys": True or False,
},
},
},
],
},
},
"stopPosition": {
"recordIndex": "A String",
"end": True or False,
"byteOffset": "A String",
"key": "A String",
"shufflePosition": "A String",
},
"sourceFork": {
"primary": {
"derivationMode": "A String",
"source": {
"codec": {
"a_key": "",
},
"baseSpecs": [
{
"a_key": "",
},
],
"spec": {
"a_key": "",
},
"doesNotNeedSplitting": True or False,
"metadata": {
"infinite": True or False,
"estimatedSizeBytes": "A String",
"producesSortedKeys": True or False,
},
},
},
"residual": {
"derivationMode": "A String",
"source": {
"codec": {
"a_key": "",
},
"baseSpecs": [
{
"a_key": "",
},
],
"spec": {
"a_key": "",
},
"doesNotNeedSplitting": True or False,
"metadata": {
"infinite": True or False,
"estimatedSizeBytes": "A String",
"producesSortedKeys": True or False,
},
},
},
},
"requestedLeaseDuration": "A String",
"completed": True or False,
"workItemId": "A String",
"progress": {
"position": {
"recordIndex": "A String",
"end": True or False,
"byteOffset": "A String",
"key": "A String",
"shufflePosition": "A String",
},
"remainingTime": "A String",
"percentComplete": 3.14,
},
"metricUpdates": [
{
"meanCount": "",
"kind": "A String",
"set": "",
"name": {
"origin": "A String",
"name": "A String",
"context": {
"a_key": "A String",
},
},
"meanSum": "",
"cumulative": True or False,
"updateTime": "A String",
"scalar": "",
"internal": "",
},
],
},
],
}
Returns:
An object of the form:
{
"workItemServiceStates": [
{
"suggestedStopPoint": {
"position": {
"recordIndex": "A String",
"end": True or False,
"byteOffset": "A String",
"key": "A String",
"shufflePosition": "A String",
},
"remainingTime": "A String",
"percentComplete": 3.14,
},
"leaseExpireTime": "A String",
"suggestedStopPosition": {
"recordIndex": "A String",
"end": True or False,
"byteOffset": "A String",
"key": "A String",
"shufflePosition": "A String",
},
"reportStatusInterval": "A String",
"harnessData": {
"a_key": "",
},
},
],
}</pre>
</div>
</body></html>