func newSTNServer() *stnServer {
	return &stnServer{
		stolenInterfaces: map[string]*interfaceData{},
	}
}
newSTNServer returns a new instance of the STN GRPC server.
package main
import (
	"flag"
	"fmt"
	"log"
	"net"
	"os"
	"os/signal"
	"sync"
	"syscall"
	"time"
	"github.com/safchain/ethtool"
	"github.com/vishvananda/netlink"
	"golang.org/x/net/context"
	"google.golang.org/grpc"
	"github.com/contiv/vpp/cmd/contiv-stn/model/stn"
	"github.com/contiv/vpp/pkg/pci"
	"path/filepath"
)
const (
	defaultGRPCServerSocket = "/var/run/contiv/stn.sock"  
	defaultStatusCheckPort  = 9999                        
	initStatusCheckTimeout = 30 * time.Second  
	statusCheckInterval    = 1 * time.Second   
	linkCheckTimeout       = 3 * time.Second   
	configRetryCount = 20                      
	configRetrySleep = 200 * time.Millisecond  
	vppTapInterfaceName = "vpp1"  
	preferredVPPDriver = "vfio-pci"  
)
var (
	BuildVersion string
	BuildDate string
	grpcServerSocket = flag.String("grpc", defaultGRPCServerSocket, "socket file where the GRPC STN server listens for client connections")
	statusCheckPort  = flag.Int("statuscheck", defaultStatusCheckPort, "port that STN server is checking to determine contive-agent liveness")
)
type stnServer struct {
	ethTool            *ethtool.Ethtool
	stolenInterfaces   map[string]*interfaceData
	statusCheckStarted bool
	statusCheckEnabled bool
	sync.Mutex
}
type interfaceData struct {
	name        string
	PCIAddress  string
	driver      string
	linkIndex   int
	addresses   []netlink.Addr
	routes      []netlink.Route
	dhcpEnabled bool
}