Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client struct
func MakePhaulClient ¶
MakePhaulClient function Main entry point. Caller should create the client object by passing here local, remote and comm. See comment in corresponding interfaces/structs for explanation.
Then call client.Migrate() and enjoy :)
type Config ¶
Config is the configuration which is passed around
Pid is what we migrate Memfd is the file descriptor via which criu can transfer memory pages. Wdir is the directory where phaul can put images and other stuff
type Local ¶
type Local interface {
DumpCopyRestore(criu *criu.Criu, c Config, lastClientImagesPath string) error
}
Local interface Interface to local classes. Client calls them when it needs something on the source node.
Methods:
- DumpCopyRestore() is called on client side when the pre-iterations are over and it's time to do full dump, copy images and restore them on the server side. All the time this method is executed victim tree is frozen on client. Returning nil kills the tree, error unfreezes it and resumes. The criu argument is the pointer on created criu.Criu object on which client may call Dump(). The requirement on opts passed are: set Ps.Fd to comm.Memfd set ParentImg to lastClientImagesPath set TrackMem to true
type Remote ¶
Remote interface Rpc between PhaulClient and PhaulServer. When client calls anything on this one, the corresponding method should be called on PhaulServer object.
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server struct
func MakePhaulServer ¶
MakePhaulServer function Main entry point. Make the server with comm and call PhaulRemote methods on it upon client requests.