basehttp

package module
v0.0.0-...-3fa335c Latest Latest
Warning

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

Go to latest
Published: Mar 12, 2025 License: Apache-2.0 Imports: 15 Imported by: 3

Documentation

Overview

Package basehttp contains the base http transport for the orb client, every http transport uses this as base.!

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewTransport

func NewTransport(
	name string, logger log.Logger, scheme string, hclient *http.Client,
) (orb.TransportType, error)

NewTransport creates a Transport with a custom http.Client.

Types

type Transport

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

Transport is a go-orb/plugins/client/orb compatible transport.

func (*Transport) Name

func (t *Transport) Name() string

Name returns the name of this transport.

func (*Transport) Request

func (t *Transport) Request(ctx context.Context, req *client.Req[any, any], result any, opts *client.CallOptions) error

Request does the actual rpc call to the server.

func (*Transport) Start

func (t *Transport) Start() error

Start starts the transport.

func (*Transport) Stop

func (t *Transport) Stop(_ context.Context) error

Stop stop the transport.

Jump to

Keyboard shortcuts

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