MCPcopy Create free account
hub / github.com/apache/devlake / CheckNetwork

Function CheckNetwork

backend/core/utils/network_helper.go:40–47  ·  view source on GitHub ↗

CheckNetwork FIXME ...

(host, port string, timeout time.Duration)

Source from the content-addressed store, hash-verified

38
39// CheckNetwork FIXME ...
40func CheckNetwork(host, port string, timeout time.Duration) errors.Error {
41 var target = fmt.Sprintf("%s:%s", host, port)
42 _, err := net.DialTimeout("tcp", target, timeout)
43 if err != nil {
44 return errors.Convert(err)
45 }
46 return nil
47}
48
49// ResolvePort FIXME ...
50func ResolvePort(port string, schema string) (string, errors.Error) {

Callers

nothing calls this directly

Calls 1

ConvertMethod · 0.45

Tested by

no test coverage detected