package session
import "github.com/moby/buildkit/session"
Index ¶
- func AllSessionIDs(g Group) (out []string)
- func MethodURL(s, m string) string
- type Attachable
- type Caller
- type Dialer
- type Group
- type Iterator
- type Manager
- func NewManager() (*Manager, error)
- func (sm *Manager) Any(ctx context.Context, g Group, f func(context.Context, string, Caller) error) error
- func (sm *Manager) Get(ctx context.Context, id string, noWait bool) (Caller, error)
- func (sm *Manager) HandleConn(ctx context.Context, conn net.Conn, opts map[string][]string) error
- func (sm *Manager) HandleHTTPRequest(ctx context.Context, w http.ResponseWriter, r *http.Request) error
- type Session
Functions ¶
func AllSessionIDs ¶
func MethodURL ¶
MethodURL returns a gRPC method URL for service and method name
Types ¶
type Attachable ¶
Attachable defines a feature that can be exposed on a session
type Caller ¶
type Caller interface { Context() context.Context Supports(method string) bool Conn() *grpc.ClientConn () string }
Caller can invoke requests on the session
type Dialer ¶
Dialer returns a connection that can be used by the session
type Group ¶
type Group interface { SessionIterator() Iterator }
func NewGroup ¶
type Iterator ¶
type Iterator interface { NextSession() string }
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
Manager is a controller for accessing currently active sessions
func NewManager ¶
NewManager returns a new Manager
func (*Manager) Any ¶
func (sm *Manager) Any(ctx context.Context, g Group, f func(context.Context, string, Caller) error) error
func (*Manager) Get ¶
Get returns a session by ID
func (*Manager) HandleConn ¶
HandleConn handles an incoming raw connection
func (*Manager) HandleHTTPRequest ¶
func (sm *Manager) HandleHTTPRequest(ctx context.Context, w http.ResponseWriter, r *http.Request) error
HandleHTTPRequest handles an incoming HTTP request
type Session ¶
type Session struct {
// contains filtered or unexported fields
}
Session is a long running connection between client and a daemon
func NewSession ¶
NewSession returns a new long running session
func (*Session) Allow ¶
func (s *Session) Allow(a Attachable)
Allow enables a given service to be reachable through the grpc session
func (*Session) Close ¶
Close closes the session
func (*Session) ID ¶
ID returns unique identifier for the session
func (*Session) Run ¶
Run activates the session
Source Files ¶
group.go grpc.go manager.go session.go
Directories ¶
- Version
- v0.21.0 (latest)
- Published
- Apr 11, 2025
- Platform
- linux/amd64
- Imports
- 23 packages
- Last checked
- 11 hours ago –
Tools for package owners.