api

package
v0.2.3 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2025 License: MIT Imports: 21 Imported by: 0

Documentation

Overview

Package api is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

View Source
const (
	Hellomicro_Ping_FullMethodName         = "/api.hellomicro.v1.Hellomicro/Ping"
	Hellomicro_Crash_FullMethodName        = "/api.hellomicro.v1.Hellomicro/Crash"
	Hellomicro_Panic_FullMethodName        = "/api.hellomicro.v1.Hellomicro/Panic"
	Hellomicro_Exit_FullMethodName         = "/api.hellomicro.v1.Hellomicro/Exit"
	Hellomicro_Log_FullMethodName          = "/api.hellomicro.v1.Hellomicro/Log"
	Hellomicro_Latency_FullMethodName      = "/api.hellomicro.v1.Hellomicro/Latency"
	Hellomicro_Info_FullMethodName         = "/api.hellomicro.v1.Hellomicro/Info"
	Hellomicro_Environments_FullMethodName = "/api.hellomicro.v1.Hellomicro/Environments"
	Hellomicro_Echo_FullMethodName         = "/api.hellomicro.v1.Hellomicro/Echo"
	Hellomicro_Request_FullMethodName      = "/api.hellomicro.v1.Hellomicro/Request"
	Hellomicro_ListFiles_FullMethodName    = "/api.hellomicro.v1.Hellomicro/ListFiles"
	Hellomicro_ReadFile_FullMethodName     = "/api.hellomicro.v1.Hellomicro/ReadFile"
	Hellomicro_WriteFile_FullMethodName    = "/api.hellomicro.v1.Hellomicro/WriteFile"
	Hellomicro_DeleteFile_FullMethodName   = "/api.hellomicro.v1.Hellomicro/DeleteFile"
)

Variables

View Source
var (
	Cookie_SameSite_name = map[int32]string{
		0: "TYPE_UNSPECIFIED",
		1: "DEFAULT_MODE",
		2: "LAX_MODE",
		3: "STRICT_MODE",
		4: "NONE_MODE",
	}
	Cookie_SameSite_value = map[string]int32{
		"TYPE_UNSPECIFIED": 0,
		"DEFAULT_MODE":     1,
		"LAX_MODE":         2,
		"STRICT_MODE":      3,
		"NONE_MODE":        4,
	}
)

Enum value maps for Cookie_SameSite.

View Source
var File_proto_service_proto protoreflect.FileDescriptor
View Source
var Hellomicro_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "api.hellomicro.v1.Hellomicro",
	HandlerType: (*HellomicroServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Ping",
			Handler:    _Hellomicro_Ping_Handler,
		},
		{
			MethodName: "Crash",
			Handler:    _Hellomicro_Crash_Handler,
		},
		{
			MethodName: "Panic",
			Handler:    _Hellomicro_Panic_Handler,
		},
		{
			MethodName: "Exit",
			Handler:    _Hellomicro_Exit_Handler,
		},
		{
			MethodName: "Log",
			Handler:    _Hellomicro_Log_Handler,
		},
		{
			MethodName: "Latency",
			Handler:    _Hellomicro_Latency_Handler,
		},
		{
			MethodName: "Info",
			Handler:    _Hellomicro_Info_Handler,
		},
		{
			MethodName: "Environments",
			Handler:    _Hellomicro_Environments_Handler,
		},
		{
			MethodName: "Echo",
			Handler:    _Hellomicro_Echo_Handler,
		},
		{
			MethodName: "Request",
			Handler:    _Hellomicro_Request_Handler,
		},
		{
			MethodName: "ListFiles",
			Handler:    _Hellomicro_ListFiles_Handler,
		},
		{
			MethodName: "ReadFile",
			Handler:    _Hellomicro_ReadFile_Handler,
		},
		{
			MethodName: "WriteFile",
			Handler:    _Hellomicro_WriteFile_Handler,
		},
		{
			MethodName: "DeleteFile",
			Handler:    _Hellomicro_DeleteFile_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "proto/service.proto",
}

Hellomicro_ServiceDesc is the grpc.ServiceDesc for Hellomicro service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterHellomicroHandler

func RegisterHellomicroHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterHellomicroHandler registers the http handlers for service Hellomicro to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterHellomicroHandlerClient

func RegisterHellomicroHandlerClient(ctx context.Context, mux *runtime.ServeMux, client HellomicroClient) error

RegisterHellomicroHandlerClient registers the http handlers for service Hellomicro to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "HellomicroClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "HellomicroClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "HellomicroClient" to call the correct interceptors. This client ignores the HTTP middlewares.

func RegisterHellomicroHandlerFromEndpoint

func RegisterHellomicroHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterHellomicroHandlerFromEndpoint is same as RegisterHellomicroHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterHellomicroHandlerServer

func RegisterHellomicroHandlerServer(ctx context.Context, mux *runtime.ServeMux, server HellomicroServer) error

RegisterHellomicroHandlerServer registers the http handlers for service Hellomicro to "mux". UnaryRPC :call HellomicroServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterHellomicroHandlerFromEndpoint instead. GRPC interceptors will not work for this type of registration. To use interceptors, you must use the "runtime.WithMiddlewares" option in the "runtime.NewServeMux" call.

func RegisterHellomicroServer

func RegisterHellomicroServer(s grpc.ServiceRegistrar, srv HellomicroServer)

Types

type Cookie struct {
	Name       string                 `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Value      string                 `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
	Path       string                 `protobuf:"bytes,3,opt,name=path,proto3" json:"path,omitempty"`
	Domain     string                 `protobuf:"bytes,4,opt,name=domain,proto3" json:"domain,omitempty"`
	Expires    *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=expires,proto3" json:"expires,omitempty"`
	RawExpires string                 `protobuf:"bytes,6,opt,name=raw_expires,json=rawExpires,proto3" json:"raw_expires,omitempty"`
	MaxAge     int32                  `protobuf:"varint,7,opt,name=max_age,json=maxAge,proto3" json:"max_age,omitempty"`
	Secure     bool                   `protobuf:"varint,8,opt,name=secure,proto3" json:"secure,omitempty"`
	HttpOnly   bool                   `protobuf:"varint,9,opt,name=http_only,json=httpOnly,proto3" json:"http_only,omitempty"`
	SameSite   Cookie_SameSite        `` /* 126-byte string literal not displayed */
	Raw        string                 `protobuf:"bytes,11,opt,name=raw,proto3" json:"raw,omitempty"`
	Unparsed   []string               `protobuf:"bytes,12,rep,name=unparsed,proto3" json:"unparsed,omitempty"`
	// contains filtered or unexported fields
}

func (*Cookie) Descriptor deprecated

func (*Cookie) Descriptor() ([]byte, []int)

Deprecated: Use Cookie.ProtoReflect.Descriptor instead.

func (*Cookie) GetDomain

func (x *Cookie) GetDomain() string

func (*Cookie) GetExpires

func (x *Cookie) GetExpires() *timestamppb.Timestamp

func (*Cookie) GetHttpOnly

func (x *Cookie) GetHttpOnly() bool

func (*Cookie) GetMaxAge

func (x *Cookie) GetMaxAge() int32

func (*Cookie) GetName

func (x *Cookie) GetName() string

func (*Cookie) GetPath

func (x *Cookie) GetPath() string

func (*Cookie) GetRaw

func (x *Cookie) GetRaw() string

func (*Cookie) GetRawExpires

func (x *Cookie) GetRawExpires() string

func (*Cookie) GetSameSite

func (x *Cookie) GetSameSite() Cookie_SameSite

func (*Cookie) GetSecure

func (x *Cookie) GetSecure() bool

func (*Cookie) GetUnparsed

func (x *Cookie) GetUnparsed() []string

func (*Cookie) GetValue

func (x *Cookie) GetValue() string

func (*Cookie) ProtoMessage

func (*Cookie) ProtoMessage()

func (*Cookie) ProtoReflect

func (x *Cookie) ProtoReflect() protoreflect.Message

func (*Cookie) Reset

func (x *Cookie) Reset()

func (*Cookie) String

func (x *Cookie) String() string
type Cookie_SameSite int32
const (
	Cookie_TYPE_UNSPECIFIED Cookie_SameSite = 0
	Cookie_DEFAULT_MODE     Cookie_SameSite = 1
	Cookie_LAX_MODE         Cookie_SameSite = 2
	Cookie_STRICT_MODE      Cookie_SameSite = 3
	Cookie_NONE_MODE        Cookie_SameSite = 4
)
func (x Cookie_SameSite) Enum() *Cookie_SameSite
func (Cookie_SameSite) EnumDescriptor() ([]byte, []int)

Deprecated: Use Cookie_SameSite.Descriptor instead.

func (x Cookie_SameSite) String() string

type DeleteFileReq

type DeleteFileReq struct {
	// contains filtered or unexported fields
}

func (*DeleteFileReq) Descriptor deprecated

func (*DeleteFileReq) Descriptor() ([]byte, []int)

Deprecated: Use DeleteFileReq.ProtoReflect.Descriptor instead.

func (*DeleteFileReq) ProtoMessage

func (*DeleteFileReq) ProtoMessage()

func (*DeleteFileReq) ProtoReflect

func (x *DeleteFileReq) ProtoReflect() protoreflect.Message

func (*DeleteFileReq) Reset

func (x *DeleteFileReq) Reset()

func (*DeleteFileReq) String

func (x *DeleteFileReq) String() string

type DeleteFileRes

type DeleteFileRes struct {
	// contains filtered or unexported fields
}

func (*DeleteFileRes) Descriptor deprecated

func (*DeleteFileRes) Descriptor() ([]byte, []int)

Deprecated: Use DeleteFileRes.ProtoReflect.Descriptor instead.

func (*DeleteFileRes) ProtoMessage

func (*DeleteFileRes) ProtoMessage()

func (*DeleteFileRes) ProtoReflect

func (x *DeleteFileRes) ProtoReflect() protoreflect.Message

func (*DeleteFileRes) Reset

func (x *DeleteFileRes) Reset()

func (*DeleteFileRes) String

func (x *DeleteFileRes) String() string

type EchoRes

type EchoRes struct {
	Method        string                  `protobuf:"bytes,1,opt,name=method,proto3" json:"method,omitempty"`
	Proto         string                  `protobuf:"bytes,2,opt,name=proto,proto3" json:"proto,omitempty"`
	ContentLength int64                   `protobuf:"varint,3,opt,name=content_length,json=contentLength,proto3" json:"content_length,omitempty"`
	RemoteAddr    string                  `protobuf:"bytes,4,opt,name=remote_addr,json=remoteAddr,proto3" json:"remote_addr,omitempty"`
	RequestUri    string                  `protobuf:"bytes,5,opt,name=request_uri,json=requestUri,proto3" json:"request_uri,omitempty"`
	Host          string                  `protobuf:"bytes,6,opt,name=host,proto3" json:"host,omitempty"`
	UserAgent     string                  `protobuf:"bytes,7,opt,name=user_agent,json=userAgent,proto3" json:"user_agent,omitempty"`
	Body          string                  `protobuf:"bytes,8,opt,name=body,proto3" json:"body,omitempty"`
	Headers       map[string]*StringArray `` /* 155-byte string literal not displayed */
	Params        map[string]*StringArray `` /* 154-byte string literal not displayed */
	Url           *URL                    `protobuf:"bytes,11,opt,name=url,proto3" json:"url,omitempty"`
	Cookies       []*Cookie               `protobuf:"bytes,12,rep,name=cookies,proto3" json:"cookies,omitempty"`
	// contains filtered or unexported fields
}

func (*EchoRes) Descriptor deprecated

func (*EchoRes) Descriptor() ([]byte, []int)

Deprecated: Use EchoRes.ProtoReflect.Descriptor instead.

func (*EchoRes) GetBody

func (x *EchoRes) GetBody() string

func (*EchoRes) GetContentLength

func (x *EchoRes) GetContentLength() int64

func (*EchoRes) GetCookies

func (x *EchoRes) GetCookies() []*Cookie

func (*EchoRes) GetHeaders

func (x *EchoRes) GetHeaders() map[string]*StringArray

func (*EchoRes) GetHost

func (x *EchoRes) GetHost() string

func (*EchoRes) GetMethod

func (x *EchoRes) GetMethod() string

func (*EchoRes) GetParams

func (x *EchoRes) GetParams() map[string]*StringArray

func (*EchoRes) GetProto

func (x *EchoRes) GetProto() string

func (*EchoRes) GetRemoteAddr

func (x *EchoRes) GetRemoteAddr() string

func (*EchoRes) GetRequestUri

func (x *EchoRes) GetRequestUri() string

func (*EchoRes) GetUrl

func (x *EchoRes) GetUrl() *URL

func (*EchoRes) GetUserAgent

func (x *EchoRes) GetUserAgent() string

func (*EchoRes) ProtoMessage

func (*EchoRes) ProtoMessage()

func (*EchoRes) ProtoReflect

func (x *EchoRes) ProtoReflect() protoreflect.Message

func (*EchoRes) Reset

func (x *EchoRes) Reset()

func (*EchoRes) String

func (x *EchoRes) String() string

type EnvironmentsRes

type EnvironmentsRes struct {
	Environments map[string]string `` /* 165-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*EnvironmentsRes) Descriptor deprecated

func (*EnvironmentsRes) Descriptor() ([]byte, []int)

Deprecated: Use EnvironmentsRes.ProtoReflect.Descriptor instead.

func (*EnvironmentsRes) GetEnvironments

func (x *EnvironmentsRes) GetEnvironments() map[string]string

func (*EnvironmentsRes) ProtoMessage

func (*EnvironmentsRes) ProtoMessage()

func (*EnvironmentsRes) ProtoReflect

func (x *EnvironmentsRes) ProtoReflect() protoreflect.Message

func (*EnvironmentsRes) Reset

func (x *EnvironmentsRes) Reset()

func (*EnvironmentsRes) String

func (x *EnvironmentsRes) String() string

type ExitReq

type ExitReq struct {
	Code int32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"`
	// contains filtered or unexported fields
}

* Requests

func (*ExitReq) Descriptor deprecated

func (*ExitReq) Descriptor() ([]byte, []int)

Deprecated: Use ExitReq.ProtoReflect.Descriptor instead.

func (*ExitReq) GetCode

func (x *ExitReq) GetCode() int32

func (*ExitReq) ProtoMessage

func (*ExitReq) ProtoMessage()

func (*ExitReq) ProtoReflect

func (x *ExitReq) ProtoReflect() protoreflect.Message

func (*ExitReq) Reset

func (x *ExitReq) Reset()

func (*ExitReq) String

func (x *ExitReq) String() string

type FileInfo

type FileInfo struct {
	Path    string                 `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"`
	Size    int64                  `protobuf:"varint,2,opt,name=size,proto3" json:"size,omitempty"`
	Mode    string                 `protobuf:"bytes,3,opt,name=mode,proto3" json:"mode,omitempty"`
	ModTime *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=modTime,proto3" json:"modTime,omitempty"`
	// contains filtered or unexported fields
}

func (*FileInfo) Descriptor deprecated

func (*FileInfo) Descriptor() ([]byte, []int)

Deprecated: Use FileInfo.ProtoReflect.Descriptor instead.

func (*FileInfo) GetModTime

func (x *FileInfo) GetModTime() *timestamppb.Timestamp

func (*FileInfo) GetMode

func (x *FileInfo) GetMode() string

func (*FileInfo) GetPath

func (x *FileInfo) GetPath() string

func (*FileInfo) GetSize

func (x *FileInfo) GetSize() int64

func (*FileInfo) ProtoMessage

func (*FileInfo) ProtoMessage()

func (*FileInfo) ProtoReflect

func (x *FileInfo) ProtoReflect() protoreflect.Message

func (*FileInfo) Reset

func (x *FileInfo) Reset()

func (*FileInfo) String

func (x *FileInfo) String() string

type HellomicroClient

type HellomicroClient interface {
	Ping(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*emptypb.Empty, error)
	Crash(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*emptypb.Empty, error)
	Panic(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*emptypb.Empty, error)
	Exit(ctx context.Context, in *ExitReq, opts ...grpc.CallOption) (*emptypb.Empty, error)
	Log(ctx context.Context, in *LogReq, opts ...grpc.CallOption) (*emptypb.Empty, error)
	Latency(ctx context.Context, in *LatencyReq, opts ...grpc.CallOption) (*emptypb.Empty, error)
	Info(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*InfoRes, error)
	Environments(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*EnvironmentsRes, error)
	Echo(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*EchoRes, error)
	Request(ctx context.Context, in *RequestReq, opts ...grpc.CallOption) (*RequestRes, error)
	ListFiles(ctx context.Context, in *ListFilesReq, opts ...grpc.CallOption) (*ListFilesRes, error)
	ReadFile(ctx context.Context, in *ReadFileReq, opts ...grpc.CallOption) (*ReadFileRes, error)
	WriteFile(ctx context.Context, in *WriteFileReq, opts ...grpc.CallOption) (*emptypb.Empty, error)
	DeleteFile(ctx context.Context, in *DeleteFileReq, opts ...grpc.CallOption) (*DeleteFileRes, error)
}

HellomicroClient is the client API for Hellomicro service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewHellomicroClient

func NewHellomicroClient(cc grpc.ClientConnInterface) HellomicroClient

type HellomicroServer

HellomicroServer is the server API for Hellomicro service. All implementations should embed UnimplementedHellomicroServer for forward compatibility.

type InfoRes

type InfoRes struct {
	Os           string          `protobuf:"bytes,1,opt,name=os,proto3" json:"os,omitempty"`
	Version      string          `protobuf:"bytes,2,opt,name=version,proto3" json:"version,omitempty"`
	NumCpu       int32           `protobuf:"varint,3,opt,name=num_cpu,json=numCpu,proto3" json:"num_cpu,omitempty"`
	NumGoRoutine int32           `protobuf:"varint,4,opt,name=num_go_routine,json=numGoRoutine,proto3" json:"num_go_routine,omitempty"`
	NumCgoCall   int64           `protobuf:"varint,5,opt,name=num_cgo_call,json=numCgoCall,proto3" json:"num_cgo_call,omitempty"`
	Memory       *InfoRes_Memory `protobuf:"bytes,6,opt,name=memory,proto3" json:"memory,omitempty"`
	// contains filtered or unexported fields
}

func (*InfoRes) Descriptor deprecated

func (*InfoRes) Descriptor() ([]byte, []int)

Deprecated: Use InfoRes.ProtoReflect.Descriptor instead.

func (*InfoRes) GetMemory

func (x *InfoRes) GetMemory() *InfoRes_Memory

func (*InfoRes) GetNumCgoCall

func (x *InfoRes) GetNumCgoCall() int64

func (*InfoRes) GetNumCpu

func (x *InfoRes) GetNumCpu() int32

func (*InfoRes) GetNumGoRoutine

func (x *InfoRes) GetNumGoRoutine() int32

func (*InfoRes) GetOs

func (x *InfoRes) GetOs() string

func (*InfoRes) GetVersion

func (x *InfoRes) GetVersion() string

func (*InfoRes) ProtoMessage

func (*InfoRes) ProtoMessage()

func (*InfoRes) ProtoReflect

func (x *InfoRes) ProtoReflect() protoreflect.Message

func (*InfoRes) Reset

func (x *InfoRes) Reset()

func (*InfoRes) String

func (x *InfoRes) String() string

type InfoRes_Memory

type InfoRes_Memory struct {
	Alloc      uint64 `protobuf:"varint,1,opt,name=alloc,proto3" json:"alloc,omitempty"`
	TotalAlloc uint64 `protobuf:"varint,2,opt,name=total_alloc,json=totalAlloc,proto3" json:"total_alloc,omitempty"`
	Sys        uint64 `protobuf:"varint,3,opt,name=sys,proto3" json:"sys,omitempty"`
	NumGc      uint32 `protobuf:"varint,4,opt,name=num_gc,json=numGc,proto3" json:"num_gc,omitempty"`
	// contains filtered or unexported fields
}

func (*InfoRes_Memory) Descriptor deprecated

func (*InfoRes_Memory) Descriptor() ([]byte, []int)

Deprecated: Use InfoRes_Memory.ProtoReflect.Descriptor instead.

func (*InfoRes_Memory) GetAlloc

func (x *InfoRes_Memory) GetAlloc() uint64

func (*InfoRes_Memory) GetNumGc

func (x *InfoRes_Memory) GetNumGc() uint32

func (*InfoRes_Memory) GetSys

func (x *InfoRes_Memory) GetSys() uint64

func (*InfoRes_Memory) GetTotalAlloc

func (x *InfoRes_Memory) GetTotalAlloc() uint64

func (*InfoRes_Memory) ProtoMessage

func (*InfoRes_Memory) ProtoMessage()

func (*InfoRes_Memory) ProtoReflect

func (x *InfoRes_Memory) ProtoReflect() protoreflect.Message

func (*InfoRes_Memory) Reset

func (x *InfoRes_Memory) Reset()

func (*InfoRes_Memory) String

func (x *InfoRes_Memory) String() string

type LatencyReq

type LatencyReq struct {
	Duration int32 `protobuf:"varint,1,opt,name=duration,proto3" json:"duration,omitempty"`
	// contains filtered or unexported fields
}

func (*LatencyReq) Descriptor deprecated

func (*LatencyReq) Descriptor() ([]byte, []int)

Deprecated: Use LatencyReq.ProtoReflect.Descriptor instead.

func (*LatencyReq) GetDuration

func (x *LatencyReq) GetDuration() int32

func (*LatencyReq) ProtoMessage

func (*LatencyReq) ProtoMessage()

func (*LatencyReq) ProtoReflect

func (x *LatencyReq) ProtoReflect() protoreflect.Message

func (*LatencyReq) Reset

func (x *LatencyReq) Reset()

func (*LatencyReq) String

func (x *LatencyReq) String() string

type ListFilesReq

type ListFilesReq struct {
	Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"`
	// contains filtered or unexported fields
}

func (*ListFilesReq) Descriptor deprecated

func (*ListFilesReq) Descriptor() ([]byte, []int)

Deprecated: Use ListFilesReq.ProtoReflect.Descriptor instead.

func (*ListFilesReq) GetPath

func (x *ListFilesReq) GetPath() string

func (*ListFilesReq) ProtoMessage

func (*ListFilesReq) ProtoMessage()

func (*ListFilesReq) ProtoReflect

func (x *ListFilesReq) ProtoReflect() protoreflect.Message

func (*ListFilesReq) Reset

func (x *ListFilesReq) Reset()

func (*ListFilesReq) String

func (x *ListFilesReq) String() string

type ListFilesRes

type ListFilesRes struct {
	FileInfos []*FileInfo `protobuf:"bytes,1,rep,name=file_infos,json=fileInfos,proto3" json:"file_infos,omitempty"`
	// contains filtered or unexported fields
}

func (*ListFilesRes) Descriptor deprecated

func (*ListFilesRes) Descriptor() ([]byte, []int)

Deprecated: Use ListFilesRes.ProtoReflect.Descriptor instead.

func (*ListFilesRes) GetFileInfos

func (x *ListFilesRes) GetFileInfos() []*FileInfo

func (*ListFilesRes) ProtoMessage

func (*ListFilesRes) ProtoMessage()

func (*ListFilesRes) ProtoReflect

func (x *ListFilesRes) ProtoReflect() protoreflect.Message

func (*ListFilesRes) Reset

func (x *ListFilesRes) Reset()

func (*ListFilesRes) String

func (x *ListFilesRes) String() string

type LogReq

type LogReq struct {
	Count int32 `protobuf:"varint,1,opt,name=count,proto3" json:"count,omitempty"`
	// contains filtered or unexported fields
}

func (*LogReq) Descriptor deprecated

func (*LogReq) Descriptor() ([]byte, []int)

Deprecated: Use LogReq.ProtoReflect.Descriptor instead.

func (*LogReq) GetCount

func (x *LogReq) GetCount() int32

func (*LogReq) ProtoMessage

func (*LogReq) ProtoMessage()

func (*LogReq) ProtoReflect

func (x *LogReq) ProtoReflect() protoreflect.Message

func (*LogReq) Reset

func (x *LogReq) Reset()

func (*LogReq) String

func (x *LogReq) String() string

type ReadFileReq

type ReadFileReq struct {
	// contains filtered or unexported fields
}

func (*ReadFileReq) Descriptor deprecated

func (*ReadFileReq) Descriptor() ([]byte, []int)

Deprecated: Use ReadFileReq.ProtoReflect.Descriptor instead.

func (*ReadFileReq) ProtoMessage

func (*ReadFileReq) ProtoMessage()

func (*ReadFileReq) ProtoReflect

func (x *ReadFileReq) ProtoReflect() protoreflect.Message

func (*ReadFileReq) Reset

func (x *ReadFileReq) Reset()

func (*ReadFileReq) String

func (x *ReadFileReq) String() string

type ReadFileRes

type ReadFileRes struct {
	// contains filtered or unexported fields
}

func (*ReadFileRes) Descriptor deprecated

func (*ReadFileRes) Descriptor() ([]byte, []int)

Deprecated: Use ReadFileRes.ProtoReflect.Descriptor instead.

func (*ReadFileRes) ProtoMessage

func (*ReadFileRes) ProtoMessage()

func (*ReadFileRes) ProtoReflect

func (x *ReadFileRes) ProtoReflect() protoreflect.Message

func (*ReadFileRes) Reset

func (x *ReadFileRes) Reset()

func (*ReadFileRes) String

func (x *ReadFileRes) String() string

type RequestReq

type RequestReq struct {
	Method string `protobuf:"bytes,1,opt,name=method,proto3" json:"method,omitempty"`
	Url    string `protobuf:"bytes,2,opt,name=url,proto3" json:"url,omitempty"`
	Body   string `protobuf:"bytes,3,opt,name=body,proto3" json:"body,omitempty"`
	// contains filtered or unexported fields
}

func (*RequestReq) Descriptor deprecated

func (*RequestReq) Descriptor() ([]byte, []int)

Deprecated: Use RequestReq.ProtoReflect.Descriptor instead.

func (*RequestReq) GetBody

func (x *RequestReq) GetBody() string

func (*RequestReq) GetMethod

func (x *RequestReq) GetMethod() string

func (*RequestReq) GetUrl

func (x *RequestReq) GetUrl() string

func (*RequestReq) ProtoMessage

func (*RequestReq) ProtoMessage()

func (*RequestReq) ProtoReflect

func (x *RequestReq) ProtoReflect() protoreflect.Message

func (*RequestReq) Reset

func (x *RequestReq) Reset()

func (*RequestReq) String

func (x *RequestReq) String() string

type RequestRes

type RequestRes struct {
	Body       string                  `protobuf:"bytes,1,opt,name=body,proto3" json:"body,omitempty"`
	StatusCode int32                   `protobuf:"varint,2,opt,name=status_code,json=statusCode,proto3" json:"status_code,omitempty"`
	Headers    map[string]*StringArray `` /* 155-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*RequestRes) Descriptor deprecated

func (*RequestRes) Descriptor() ([]byte, []int)

Deprecated: Use RequestRes.ProtoReflect.Descriptor instead.

func (*RequestRes) GetBody

func (x *RequestRes) GetBody() string

func (*RequestRes) GetHeaders

func (x *RequestRes) GetHeaders() map[string]*StringArray

func (*RequestRes) GetStatusCode

func (x *RequestRes) GetStatusCode() int32

func (*RequestRes) ProtoMessage

func (*RequestRes) ProtoMessage()

func (*RequestRes) ProtoReflect

func (x *RequestRes) ProtoReflect() protoreflect.Message

func (*RequestRes) Reset

func (x *RequestRes) Reset()

func (*RequestRes) String

func (x *RequestRes) String() string

type StringArray

type StringArray struct {
	Values []string `protobuf:"bytes,1,rep,name=values,proto3" json:"values,omitempty"`
	// contains filtered or unexported fields
}

func (*StringArray) Descriptor deprecated

func (*StringArray) Descriptor() ([]byte, []int)

Deprecated: Use StringArray.ProtoReflect.Descriptor instead.

func (*StringArray) GetValues

func (x *StringArray) GetValues() []string

func (*StringArray) ProtoMessage

func (*StringArray) ProtoMessage()

func (*StringArray) ProtoReflect

func (x *StringArray) ProtoReflect() protoreflect.Message

func (*StringArray) Reset

func (x *StringArray) Reset()

func (*StringArray) String

func (x *StringArray) String() string

type URL

type URL struct {
	Scheme      string `protobuf:"bytes,1,opt,name=scheme,proto3" json:"scheme,omitempty"`
	Opaque      string `protobuf:"bytes,2,opt,name=opaque,proto3" json:"opaque,omitempty"`
	Username    string `protobuf:"bytes,3,opt,name=username,proto3" json:"username,omitempty"`
	Password    string `protobuf:"bytes,4,opt,name=password,proto3" json:"password,omitempty"`
	Host        string `protobuf:"bytes,5,opt,name=host,proto3" json:"host,omitempty"`
	Path        string `protobuf:"bytes,6,opt,name=path,proto3" json:"path,omitempty"`
	RawPath     string `protobuf:"bytes,7,opt,name=raw_path,json=rawPath,proto3" json:"raw_path,omitempty"`
	RawQuery    string `protobuf:"bytes,8,opt,name=raw_query,json=rawQuery,proto3" json:"raw_query,omitempty"`
	Fragment    string `protobuf:"bytes,9,opt,name=fragment,proto3" json:"fragment,omitempty"`
	RawFragment string `protobuf:"bytes,10,opt,name=raw_fragment,json=rawFragment,proto3" json:"raw_fragment,omitempty"`
	ForceQuery  bool   `protobuf:"varint,11,opt,name=force_query,json=forceQuery,proto3" json:"force_query,omitempty"`
	PasswordSet bool   `protobuf:"varint,12,opt,name=password_set,json=passwordSet,proto3" json:"password_set,omitempty"`
	// contains filtered or unexported fields
}

func (*URL) Descriptor deprecated

func (*URL) Descriptor() ([]byte, []int)

Deprecated: Use URL.ProtoReflect.Descriptor instead.

func (*URL) GetForceQuery

func (x *URL) GetForceQuery() bool

func (*URL) GetFragment

func (x *URL) GetFragment() string

func (*URL) GetHost

func (x *URL) GetHost() string

func (*URL) GetOpaque

func (x *URL) GetOpaque() string

func (*URL) GetPassword

func (x *URL) GetPassword() string

func (*URL) GetPasswordSet

func (x *URL) GetPasswordSet() bool

func (*URL) GetPath

func (x *URL) GetPath() string

func (*URL) GetRawFragment

func (x *URL) GetRawFragment() string

func (*URL) GetRawPath

func (x *URL) GetRawPath() string

func (*URL) GetRawQuery

func (x *URL) GetRawQuery() string

func (*URL) GetScheme

func (x *URL) GetScheme() string

func (*URL) GetUsername

func (x *URL) GetUsername() string

func (*URL) ProtoMessage

func (*URL) ProtoMessage()

func (*URL) ProtoReflect

func (x *URL) ProtoReflect() protoreflect.Message

func (*URL) Reset

func (x *URL) Reset()

func (*URL) String

func (x *URL) String() string

type UnimplementedHellomicroServer

type UnimplementedHellomicroServer struct{}

UnimplementedHellomicroServer should be embedded to have forward compatible implementations.

NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.

func (UnimplementedHellomicroServer) Crash

func (UnimplementedHellomicroServer) DeleteFile

func (UnimplementedHellomicroServer) Echo

func (UnimplementedHellomicroServer) Environments

func (UnimplementedHellomicroServer) Exit

func (UnimplementedHellomicroServer) Info

func (UnimplementedHellomicroServer) Latency

func (UnimplementedHellomicroServer) ListFiles

func (UnimplementedHellomicroServer) Log

func (UnimplementedHellomicroServer) Panic

func (UnimplementedHellomicroServer) Ping

func (UnimplementedHellomicroServer) ReadFile

func (UnimplementedHellomicroServer) Request

func (UnimplementedHellomicroServer) WriteFile

type UnsafeHellomicroServer

type UnsafeHellomicroServer interface {
	// contains filtered or unexported methods
}

UnsafeHellomicroServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to HellomicroServer will result in compilation errors.

type WriteFileReq

type WriteFileReq struct {
	Path    string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"`
	Content []byte `protobuf:"bytes,2,opt,name=content,proto3" json:"content,omitempty"`
	Mode    string `protobuf:"bytes,3,opt,name=mode,proto3" json:"mode,omitempty"`
	// contains filtered or unexported fields
}

func (*WriteFileReq) Descriptor deprecated

func (*WriteFileReq) Descriptor() ([]byte, []int)

Deprecated: Use WriteFileReq.ProtoReflect.Descriptor instead.

func (*WriteFileReq) GetContent

func (x *WriteFileReq) GetContent() []byte

func (*WriteFileReq) GetMode

func (x *WriteFileReq) GetMode() string

func (*WriteFileReq) GetPath

func (x *WriteFileReq) GetPath() string

func (*WriteFileReq) ProtoMessage

func (*WriteFileReq) ProtoMessage()

func (*WriteFileReq) ProtoReflect

func (x *WriteFileReq) ProtoReflect() protoreflect.Message

func (*WriteFileReq) Reset

func (x *WriteFileReq) Reset()

func (*WriteFileReq) String

func (x *WriteFileReq) String() string

Jump to

Keyboard shortcuts

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