I was using the old manners, which allowed custom built listeners to be passed to the HTTP serving func.
The new API /almost/ allows you to do that, except I can't create a GracefulListener struct from outside of manners because it has private fields.
This would be solved if you either make those public, or if you can add NewListener func:
// this...
type GracefulListener struct {
net.Listener
Open bool
Server *GracefulServer
}
// or this...
func NewLisneter(listener net.Listener, s *GracefulServer) {
return &GracefulListener { listener, true, s }
}
I was using the old manners, which allowed custom built listeners to be passed to the HTTP serving func.
The new API /almost/ allows you to do that, except I can't create a GracefulListener struct from outside of manners because it has private fields.
This would be solved if you either make those public, or if you can add NewListener func: