http

package
v0.0.0-...-3b29460 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 29, 2020 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package http provides a set of HTTP Cloud Functions samples.

Package http provides a set of HTTP Cloud Functions samples.

Package http provides a set of HTTP Cloud Functions samples.

Package http provides a set of HTTP Cloud Functions samples.

Package http provides a set of HTTP Cloud Functions samples.

Package http provides a set of HTTP Cloud Functions samples.

Package http provides a set of HTTP Cloud Functions samples.

Package http provides a set of HTTP Cloud Functions samples.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CORSEnabledFunction

func CORSEnabledFunction(w http.ResponseWriter, r *http.Request)

CORSEnabledFunction is an example of setting CORS headers. For more information about CORS and CORS preflight requests, see https://developer.mozilla.org/en-US/docs/Glossary/Preflight_request.

func CORSEnabledFunctionAuth

func CORSEnabledFunctionAuth(w http.ResponseWriter, r *http.Request)

CORSEnabledFunctionAuth is an example of setting CORS headers with authentication enabled. For more information about CORS and CORS preflight requests, see https://developer.mozilla.org/en-US/docs/Glossary/Preflight_request.

func ExecutionCount

func ExecutionCount(w http.ResponseWriter, r *http.Request)

ExecutionCount is an HTTP Cloud Function that counts how many times it is executed within a specific instance.

func HelloContentType

func HelloContentType(w http.ResponseWriter, r *http.Request)

HelloContentType is an HTTP Cloud function. It uses the Content-Type header to identify the request payload format.

func HelloHTTPMethod

func HelloHTTPMethod(w http.ResponseWriter, r *http.Request)

HelloHTTPMethod is an HTTP Cloud function. It uses the request method to differentiate the response.

func MakeRequest

func MakeRequest(w http.ResponseWriter, r *http.Request)

MakeRequest is an example of making an HTTP request. MakeRequest uses a single http.Client for all requests to take advantage of connection pooling and caching. See https://godoc.org/net/http#Client.

func ParseXML

func ParseXML(w http.ResponseWriter, r *http.Request)

ParseXML is an example of parsing a text/xml request.

func UploadFile

func UploadFile(w http.ResponseWriter, r *http.Request)

UploadFile processes a 'multipart/form-data' upload request.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL