MCPcopy Create free account
hub / github.com/SeeFlowerX/stackplz / Run

Method Run

user/module/imodule.go:113–138  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

111}
112
113func (this *Module) Run() error {
114 // this.logger.Printf("%s\tModule.Run()", this.Name())
115 // 加载全部eBPF程序
116 err := this.child.Start()
117 if err != nil {
118 return err
119 }
120
121 // 不断检查是否有外部导致的终止,有则停止加载的模块并退出
122 go func() {
123 this.run()
124 }()
125
126 // 在一端不断接收readEvents所传递的数据 或许这样可以避免阻塞
127 go func() {
128 this.processor.Serve()
129 }()
130
131 // 不断读取内核传递过来的事件
132 err = this.readEvents()
133 if err != nil {
134 return err
135 }
136
137 return nil
138}
139func (this *Module) Stop() error {
140 return nil
141}

Callers

nothing calls this directly

Calls 4

runMethod · 0.95
readEventsMethod · 0.95
ServeMethod · 0.80
StartMethod · 0.65

Tested by

no test coverage detected