Documentation ¶
Index ¶
Constants ¶
const (
// DomainSocketFile is the file name of unix domain socket server that saptune daemon listens on.
DomainSocketFile = "/var/run/saptune"
)
Variables ¶
var RPCObjNameFmt = reflect.TypeOf(FunctionHost{}).Name() + ".%s"
RPCObjNameFmt is a format string that helps client to construct RPC call function name.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct { }
Client connects to RPC server via domain socket in order to call RPC functions.
func (*Client) SetForceLatency ¶
SetForceLatency instructs RPC server to maintain a new value for cpu_dma_latency.
func (*Client) StopForceLatency ¶
StopForceLatency instructs RPC server to stop background loop that maintains cpu_dma_latency value.
type DummyAttr ¶
type DummyAttr bool // DummyAttr is a placeholder receiver's type in an RPC function
type FunctionHost ¶
type FunctionHost struct {
// contains filtered or unexported fields
}
FunctionHost hosts saptune daemon's RPC functions that are invoked by RPC client.
func NewFunctionHost ¶
func NewFunctionHost() *FunctionHost
NewFunctionHost returns an initialised function host.
func (*FunctionHost) SetForceLatency ¶
func (host *FunctionHost) SetForceLatency(newValue int, _ *DummyAttr) error
SetForceLatency starts a loop that manipulates cpu_dma_latency to match input value. If the loop is already started, the loop will be informed about the new value via a channel.
func (*FunctionHost) StopForceLatency ¶
func (host *FunctionHost) StopForceLatency(_ DummyAttr, _ *DummyAttr) error
StopForceLatency stops the background loop that maintains cpu_dma_latency by closing its channel.
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server is run by saptune system service to handle certain tuning parameters that require long-term maintenance.