You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: servanthandle.go
    path of file: ./repos/TarsGo/tars
    
    the code of the file until where you have to start completion: package tars

import (
	"errors"
	"fmt"
	"net/http"
	"strconv"
	"strings"

	"github.com/TarsCloud/TarsGo/tars/transport"
)

// AddServant add dispatch and interface for object.
func AddServant(v dispatch, f interface{}, obj string) {
	defaultApp.AddServant(v, f, obj)
}

// AddServantWi
    
func (a *application) AddServantWithProtocol(proto transport.ServerProtocol, obj string) {
	a.objRunList = append(a.objRunList, obj)
	cfg, ok := a.tarsConfig[obj]
	if !ok {
		msg := fmt.Sprintf("custom protocol servant obj name not found: %s", obj)
		ReportNotifyInfo(NotifyError, msg)
		TLOG.Debug(msg)
		panic(errors.New(msg))
	}
	TLOG.Debugf("add custom protocol server: %+v", cfg)
	s := transport.NewTarsServer(proto, cfg)
	a.goSvrs[obj] = s
}