Class AppEngineHttpTarget.Builder (2.45.0)

public static final class AppEngineHttpTarget.Builder extends GeneratedMessageV3.Builder<AppEngineHttpTarget.Builder> implements AppEngineHttpTargetOrBuilder

App Engine target. The job will be pushed to a job handler by means of an HTTP request via an http_method such as HTTP POST, HTTP GET, etc. The job is acknowledged by means of an HTTP response code in the range [200 - 299]. Error 503 is considered an App Engine system error instead of an application error. Requests returning error 503 will be retried regardless of retry configuration and not counted against retry counts. Any other response code, or a failure to receive a response before the deadline, constitutes a failed attempt.

Protobuf type google.cloud.scheduler.v1beta1.AppEngineHttpTarget

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public AppEngineHttpTarget.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
AppEngineHttpTarget.Builder
Overrides

build()

public AppEngineHttpTarget build()
Returns
Type Description
AppEngineHttpTarget

buildPartial()

public AppEngineHttpTarget buildPartial()
Returns
Type Description
AppEngineHttpTarget

clear()

public AppEngineHttpTarget.Builder clear()
Returns
Type Description
AppEngineHttpTarget.Builder
Overrides

clearAppEngineRouting()

public AppEngineHttpTarget.Builder clearAppEngineRouting()

App Engine Routing setting for the job.

.google.cloud.scheduler.v1beta1.AppEngineRouting app_engine_routing = 2;

Returns
Type Description
AppEngineHttpTarget.Builder

clearBody()

public AppEngineHttpTarget.Builder clearBody()

Body.

HTTP request body. A request body is allowed only if the HTTP method is POST or PUT. It will result in invalid argument error to set a body on a job with an incompatible HttpMethod.

bytes body = 5;

Returns
Type Description
AppEngineHttpTarget.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public AppEngineHttpTarget.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
AppEngineHttpTarget.Builder
Overrides

clearHeaders()

public AppEngineHttpTarget.Builder clearHeaders()
Returns
Type Description
AppEngineHttpTarget.Builder

clearHttpMethod()

public AppEngineHttpTarget.Builder clearHttpMethod()

The HTTP method to use for the request. PATCH and OPTIONS are not permitted.

.google.cloud.scheduler.v1beta1.HttpMethod http_method = 1;

Returns
Type Description
AppEngineHttpTarget.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public AppEngineHttpTarget.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
AppEngineHttpTarget.Builder
Overrides

clearRelativeUri()

public AppEngineHttpTarget.Builder clearRelativeUri()

The relative URI.

The relative URL must begin with "/" and must be a valid HTTP relative URL. It can contain a path, query string arguments, and # fragments. If the relative URL is empty, then the root path "/" will be used. No spaces are allowed, and the maximum length allowed is 2083 characters.

string relative_uri = 3;

Returns
Type Description
AppEngineHttpTarget.Builder

This builder for chaining.

clone()

public AppEngineHttpTarget.Builder clone()
Returns
Type Description
AppEngineHttpTarget.Builder
Overrides

containsHeaders(String key)

public boolean containsHeaders(String key)

HTTP request headers.

This map contains the header field names and values. Headers can be set when the job is created.

Cloud Scheduler sets some headers to default values:

  • User-Agent: By default, this header is "AppEngine-Google; (+http://code.google.com/appengine)". This header can be modified, but Cloud Scheduler will append "AppEngine-Google; (+http://code.google.com/appengine)" to the modified User-Agent.
  • X-CloudScheduler: This header will be set to true.
  • X-CloudScheduler-JobName: This header will contain the job name.
  • X-CloudScheduler-ScheduleTime: For Cloud Scheduler jobs specified in the unix-cron format, this header will contain the job schedule as an offset of UTC parsed according to RFC3339.

    If the job has an body, Cloud Scheduler sets the following headers:

  • Content-Type: By default, the Content-Type header is set to "application/octet-stream". The default can be overridden by explictly setting Content-Type to a particular media type when the job is created. For example, Content-Type can be set to "application/json".

  • Content-Length: This is computed by Cloud Scheduler. This value is output only. It cannot be changed.

    The headers below are output only. They cannot be set or overridden:

  • X-Google-*: For Google internal use only.

  • X-AppEngine-*: For Google internal use only.

    In addition, some App Engine headers, which contain job-specific information, are also be sent to the job handler.

map<string, string> headers = 4;

Parameter
Name Description
key String
Returns
Type Description
boolean

getAppEngineRouting()

public AppEngineRouting getAppEngineRouting()

App Engine Routing setting for the job.

.google.cloud.scheduler.v1beta1.AppEngineRouting app_engine_routing = 2;

Returns
Type Description
AppEngineRouting

The appEngineRouting.

getAppEngineRoutingBuilder()

public AppEngineRouting.Builder getAppEngineRoutingBuilder()

App Engine Routing setting for the job.

.google.cloud.scheduler.v1beta1.AppEngineRouting app_engine_routing = 2;

Returns
Type Description
AppEngineRouting.Builder

getAppEngineRoutingOrBuilder()

public AppEngineRoutingOrBuilder getAppEngineRoutingOrBuilder()

App Engine Routing setting for the job.

.google.cloud.scheduler.v1beta1.AppEngineRouting app_engine_routing = 2;

Returns
Type Description
AppEngineRoutingOrBuilder

getBody()

public ByteString getBody()

Body.

HTTP request body. A request body is allowed only if the HTTP method is POST or PUT. It will result in invalid argument error to set a body on a job with an incompatible HttpMethod.

bytes body = 5;

Returns
Type Description
ByteString

The body.

getDefaultInstanceForType()

public AppEngineHttpTarget getDefaultInstanceForType()
Returns
Type Description
AppEngineHttpTarget

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getHeaders() (deprecated)

public Map<String,String> getHeaders()

Use #getHeadersMap() instead.

Returns
Type Description
Map<String,String>

getHeadersCount()

public int getHeadersCount()

HTTP request headers.

This map contains the header field names and values. Headers can be set when the job is created.

Cloud Scheduler sets some headers to default values:

  • User-Agent: By default, this header is "AppEngine-Google; (+http://code.google.com/appengine)". This header can be modified, but Cloud Scheduler will append "AppEngine-Google; (+http://code.google.com/appengine)" to the modified User-Agent.
  • X-CloudScheduler: This header will be set to true.
  • X-CloudScheduler-JobName: This header will contain the job name.
  • X-CloudScheduler-ScheduleTime: For Cloud Scheduler jobs specified in the unix-cron format, this header will contain the job schedule as an offset of UTC parsed according to RFC3339.

    If the job has an body, Cloud Scheduler sets the following headers:

  • Content-Type: By default, the Content-Type header is set to "application/octet-stream". The default can be overridden by explictly setting Content-Type to a particular media type when the job is created. For example, Content-Type can be set to "application/json".

  • Content-Length: This is computed by Cloud Scheduler. This value is output only. It cannot be changed.

    The headers below are output only. They cannot be set or overridden:

  • X-Google-*: For Google internal use only.

  • X-AppEngine-*: For Google internal use only.

    In addition, some App Engine headers, which contain job-specific information, are also be sent to the job handler.

map<string, string> headers = 4;

Returns
Type Description
int

getHeadersMap()

public Map<String,String> getHeadersMap()

HTTP request headers.

This map contains the header field names and values. Headers can be set when the job is created.

Cloud Scheduler sets some headers to default values:

  • User-Agent: By default, this header is "AppEngine-Google; (+http://code.google.com/appengine)". This header can be modified, but Cloud Scheduler will append "AppEngine-Google; (+http://code.google.com/appengine)" to the modified User-Agent.
  • X-CloudScheduler: This header will be set to true.
  • X-CloudScheduler-JobName: This header will contain the job name.
  • X-CloudScheduler-ScheduleTime: For Cloud Scheduler jobs specified in the unix-cron format, this header will contain the job schedule as an offset of UTC parsed according to RFC3339.

    If the job has an body, Cloud Scheduler sets the following headers:

  • Content-Type: By default, the Content-Type header is set to "application/octet-stream". The default can be overridden by explictly setting Content-Type to a particular media type when the job is created. For example, Content-Type can be set to "application/json".

  • Content-Length: This is computed by Cloud Scheduler. This value is output only. It cannot be changed.

    The headers below are output only. They cannot be set or overridden:

  • X-Google-*: For Google internal use only.

  • X-AppEngine-*: For Google internal use only.

    In addition, some App Engine headers, which contain job-specific information, are also be sent to the job handler.

map<string, string> headers = 4;

Returns
Type Description
Map<String,String>

getHeadersOrDefault(String key, String defaultValue)

public String getHeadersOrDefault(String key, String defaultValue)

HTTP request headers.

This map contains the header field names and values. Headers can be set when the job is created.

Cloud Scheduler sets some headers to default values:

  • User-Agent: By default, this header is "AppEngine-Google; (+http://code.google.com/appengine)". This header can be modified, but Cloud Scheduler will append "AppEngine-Google; (+http://code.google.com/appengine)" to the modified User-Agent.
  • X-CloudScheduler: This header will be set to true.
  • X-CloudScheduler-JobName: This header will contain the job name.
  • X-CloudScheduler-ScheduleTime: For Cloud Scheduler jobs specified in the unix-cron format, this header will contain the job schedule as an offset of UTC parsed according to RFC3339.

    If the job has an body, Cloud Scheduler sets the following headers:

  • Content-Type: By default, the Content-Type header is set to "application/octet-stream". The default can be overridden by explictly setting Content-Type to a particular media type when the job is created. For example, Content-Type can be set to "application/json".

  • Content-Length: This is computed by Cloud Scheduler. This value is output only. It cannot be changed.

    The headers below are output only. They cannot be set or overridden:

  • X-Google-*: For Google internal use only.

  • X-AppEngine-*: For Google internal use only.

    In addition, some App Engine headers, which contain job-specific information, are also be sent to the job handler.

map<string, string> headers = 4;

Parameters
Name Description
key String
defaultValue String
Returns
Type Description
String

getHeadersOrThrow(String key)

public String getHeadersOrThrow(String key)

HTTP request headers.

This map contains the header field names and values. Headers can be set when the job is created.

Cloud Scheduler sets some headers to default values:

  • User-Agent: By default, this header is "AppEngine-Google; (+http://code.google.com/appengine)". This header can be modified, but Cloud Scheduler will append "AppEngine-Google; (+http://code.google.com/appengine)" to the modified User-Agent.
  • X-CloudScheduler: This header will be set to true.
  • X-CloudScheduler-JobName: This header will contain the job name.
  • X-CloudScheduler-ScheduleTime: For Cloud Scheduler jobs specified in the unix-cron format, this header will contain the job schedule as an offset of UTC parsed according to RFC3339.

    If the job has an body, Cloud Scheduler sets the following headers:

  • Content-Type: By default, the Content-Type header is set to "application/octet-stream". The default can be overridden by explictly setting Content-Type to a particular media type when the job is created. For example, Content-Type can be set to "application/json".

  • Content-Length: This is computed by Cloud Scheduler. This value is output only. It cannot be changed.

    The headers below are output only. They cannot be set or overridden:

  • X-Google-*: For Google internal use only.

  • X-AppEngine-*: For Google internal use only.

    In addition, some App Engine headers, which contain job-specific information, are also be sent to the job handler.

map<string, string> headers = 4;

Parameter
Name Description
key String
Returns
Type Description
String

getHttpMethod()

public HttpMethod getHttpMethod()

The HTTP method to use for the request. PATCH and OPTIONS are not permitted.

.google.cloud.scheduler.v1beta1.HttpMethod http_method = 1;

Returns
Type Description
HttpMethod

The httpMethod.

getHttpMethodValue()

public int getHttpMethodValue()

The HTTP method to use for the request. PATCH and OPTIONS are not permitted.

.google.cloud.scheduler.v1beta1.HttpMethod http_method = 1;

Returns
Type Description
int

The enum numeric value on the wire for httpMethod.

getMutableHeaders() (deprecated)

public Map<String,String> getMutableHeaders()

Use alternate mutation accessors instead.

Returns
Type Description
Map<String,String>

getRelativeUri()

public String getRelativeUri()

The relative URI.

The relative URL must begin with "/" and must be a valid HTTP relative URL. It can contain a path, query string arguments, and # fragments. If the relative URL is empty, then the root path "/" will be used. No spaces are allowed, and the maximum length allowed is 2083 characters.

string relative_uri = 3;

Returns
Type Description
String

The relativeUri.

getRelativeUriBytes()

public ByteString getRelativeUriBytes()

The relative URI.

The relative URL must begin with "/" and must be a valid HTTP relative URL. It can contain a path, query string arguments, and # fragments. If the relative URL is empty, then the root path "/" will be used. No spaces are allowed, and the maximum length allowed is 2083 characters.

string relative_uri = 3;

Returns
Type Description
ByteString

The bytes for relativeUri.

hasAppEngineRouting()

public boolean hasAppEngineRouting()

App Engine Routing setting for the job.

.google.cloud.scheduler.v1beta1.AppEngineRouting app_engine_routing = 2;

Returns
Type Description
boolean

Whether the appEngineRouting field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

internalGetMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int)

internalGetMutableMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMutableMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int)

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeAppEngineRouting(AppEngineRouting value)

public AppEngineHttpTarget.Builder mergeAppEngineRouting(AppEngineRouting value)

App Engine Routing setting for the job.

.google.cloud.scheduler.v1beta1.AppEngineRouting app_engine_routing = 2;

Parameter
Name Description
value AppEngineRouting
Returns
Type Description
AppEngineHttpTarget.Builder

mergeFrom(AppEngineHttpTarget other)

public AppEngineHttpTarget.Builder mergeFrom(AppEngineHttpTarget other)
Parameter
Name Description
other AppEngineHttpTarget
Returns
Type Description
AppEngineHttpTarget.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public AppEngineHttpTarget.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
AppEngineHttpTarget.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public AppEngineHttpTarget.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
AppEngineHttpTarget.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final AppEngineHttpTarget.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
AppEngineHttpTarget.Builder
Overrides

putAllHeaders(Map<String,String> values)

public AppEngineHttpTarget.Builder putAllHeaders(Map<String,String> values)

HTTP request headers.

This map contains the header field names and values. Headers can be set when the job is created.

Cloud Scheduler sets some headers to default values:

  • User-Agent: By default, this header is "AppEngine-Google; (+http://code.google.com/appengine)". This header can be modified, but Cloud Scheduler will append "AppEngine-Google; (+http://code.google.com/appengine)" to the modified User-Agent.
  • X-CloudScheduler: This header will be set to true.
  • X-CloudScheduler-JobName: This header will contain the job name.
  • X-CloudScheduler-ScheduleTime: For Cloud Scheduler jobs specified in the unix-cron format, this header will contain the job schedule as an offset of UTC parsed according to RFC3339.

    If the job has an body, Cloud Scheduler sets the following headers:

  • Content-Type: By default, the Content-Type header is set to "application/octet-stream". The default can be overridden by explictly setting Content-Type to a particular media type when the job is created. For example, Content-Type can be set to "application/json".

  • Content-Length: This is computed by Cloud Scheduler. This value is output only. It cannot be changed.

    The headers below are output only. They cannot be set or overridden:

  • X-Google-*: For Google internal use only.

  • X-AppEngine-*: For Google internal use only.

    In addition, some App Engine headers, which contain job-specific information, are also be sent to the job handler.

map<string, string> headers = 4;

Parameter
Name Description
values Map<String,String>
Returns
Type Description
AppEngineHttpTarget.Builder

putHeaders(String key, String value)

public AppEngineHttpTarget.Builder putHeaders(String key, String value)

HTTP request headers.

This map contains the header field names and values. Headers can be set when the job is created.

Cloud Scheduler sets some headers to default values:

  • User-Agent: By default, this header is "AppEngine-Google; (+http://code.google.com/appengine)". This header can be modified, but Cloud Scheduler will append "AppEngine-Google; (+http://code.google.com/appengine)" to the modified User-Agent.
  • X-CloudScheduler: This header will be set to true.
  • X-CloudScheduler-JobName: This header will contain the job name.
  • X-CloudScheduler-ScheduleTime: For Cloud Scheduler jobs specified in the unix-cron format, this header will contain the job schedule as an offset of UTC parsed according to RFC3339.

    If the job has an body, Cloud Scheduler sets the following headers:

  • Content-Type: By default, the Content-Type header is set to "application/octet-stream". The default can be overridden by explictly setting Content-Type to a particular media type when the job is created. For example, Content-Type can be set to "application/json".

  • Content-Length: This is computed by Cloud Scheduler. This value is output only. It cannot be changed.

    The headers below are output only. They cannot be set or overridden:

  • X-Google-*: For Google internal use only.

  • X-AppEngine-*: For Google internal use only.

    In addition, some App Engine headers, which contain job-specific information, are also be sent to the job handler.

map<string, string> headers = 4;

Parameters
Name Description
key String
value String
Returns
Type Description
AppEngineHttpTarget.Builder

removeHeaders(String key)

public AppEngineHttpTarget.Builder removeHeaders(String key)

HTTP request headers.

This map contains the header field names and values. Headers can be set when the job is created.

Cloud Scheduler sets some headers to default values:

  • User-Agent: By default, this header is "AppEngine-Google; (+http://code.google.com/appengine)". This header can be modified, but Cloud Scheduler will append "AppEngine-Google; (+http://code.google.com/appengine)" to the modified User-Agent.
  • X-CloudScheduler: This header will be set to true.
  • X-CloudScheduler-JobName: This header will contain the job name.
  • X-CloudScheduler-ScheduleTime: For Cloud Scheduler jobs specified in the unix-cron format, this header will contain the job schedule as an offset of UTC parsed according to RFC3339.

    If the job has an body, Cloud Scheduler sets the following headers:

  • Content-Type: By default, the Content-Type header is set to "application/octet-stream". The default can be overridden by explictly setting Content-Type to a particular media type when the job is created. For example, Content-Type can be set to "application/json".

  • Content-Length: This is computed by Cloud Scheduler. This value is output only. It cannot be changed.

    The headers below are output only. They cannot be set or overridden:

  • X-Google-*: For Google internal use only.

  • X-AppEngine-*: For Google internal use only.

    In addition, some App Engine headers, which contain job-specific information, are also be sent to the job handler.

map<string, string> headers = 4;

Parameter
Name Description
key String
Returns
Type Description
AppEngineHttpTarget.Builder

setAppEngineRouting(AppEngineRouting value)

public AppEngineHttpTarget.Builder setAppEngineRouting(AppEngineRouting value)

App Engine Routing setting for the job.

.google.cloud.scheduler.v1beta1.AppEngineRouting app_engine_routing = 2;

Parameter
Name Description
value AppEngineRouting
Returns
Type Description
AppEngineHttpTarget.Builder

setAppEngineRouting(AppEngineRouting.Builder builderForValue)

public AppEngineHttpTarget.Builder setAppEngineRouting(AppEngineRouting.Builder builderForValue)

App Engine Routing setting for the job.

.google.cloud.scheduler.v1beta1.AppEngineRouting app_engine_routing = 2;

Parameter
Name Description
builderForValue AppEngineRouting.Builder
Returns
Type Description
AppEngineHttpTarget.Builder

setBody(ByteString value)

public AppEngineHttpTarget.Builder setBody(ByteString value)

Body.

HTTP request body. A request body is allowed only if the HTTP method is POST or PUT. It will result in invalid argument error to set a body on a job with an incompatible HttpMethod.

bytes body = 5;

Parameter
Name Description
value ByteString

The body to set.

Returns
Type Description
AppEngineHttpTarget.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public AppEngineHttpTarget.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
AppEngineHttpTarget.Builder
Overrides

setHttpMethod(HttpMethod value)

public AppEngineHttpTarget.Builder setHttpMethod(HttpMethod value)

The HTTP method to use for the request. PATCH and OPTIONS are not permitted.

.google.cloud.scheduler.v1beta1.HttpMethod http_method = 1;

Parameter
Name Description
value HttpMethod

The httpMethod to set.

Returns
Type Description
AppEngineHttpTarget.Builder

This builder for chaining.

setHttpMethodValue(int value)

public AppEngineHttpTarget.Builder setHttpMethodValue(int value)

The HTTP method to use for the request. PATCH and OPTIONS are not permitted.

.google.cloud.scheduler.v1beta1.HttpMethod http_method = 1;

Parameter
Name Description
value int

The enum numeric value on the wire for httpMethod to set.

Returns
Type Description
AppEngineHttpTarget.Builder

This builder for chaining.

setRelativeUri(String value)

public AppEngineHttpTarget.Builder setRelativeUri(String value)

The relative URI.

The relative URL must begin with "/" and must be a valid HTTP relative URL. It can contain a path, query string arguments, and # fragments. If the relative URL is empty, then the root path "/" will be used. No spaces are allowed, and the maximum length allowed is 2083 characters.

string relative_uri = 3;

Parameter
Name Description
value String

The relativeUri to set.

Returns
Type Description
AppEngineHttpTarget.Builder

This builder for chaining.

setRelativeUriBytes(ByteString value)

public AppEngineHttpTarget.Builder setRelativeUriBytes(ByteString value)

The relative URI.

The relative URL must begin with "/" and must be a valid HTTP relative URL. It can contain a path, query string arguments, and # fragments. If the relative URL is empty, then the root path "/" will be used. No spaces are allowed, and the maximum length allowed is 2083 characters.

string relative_uri = 3;

Parameter
Name Description
value ByteString

The bytes for relativeUri to set.

Returns
Type Description
AppEngineHttpTarget.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public AppEngineHttpTarget.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
AppEngineHttpTarget.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final AppEngineHttpTarget.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
AppEngineHttpTarget.Builder
Overrides