func (g *IDGenerator) NewBranchID() string {
	if g.branchID >= 99 {
		panic(fmt.Errorf("branch id is larger than 99"))
	}
	if len(g.parentID) >= 20 {
		panic(fmt.Errorf("total branch id is longer than 20"))
	}
	g.branchID = g.branchID + 1
	return g.CurrentBranchID()
}
NewBranchID generate a branch id
package dtmcli
import (
	"errors"
	"fmt"
	"net/url"
)
type M = map[string]interface{}
type MS = map[string]string
func MustGenGid(server string) string {
	res := MS{}
	resp, err := RestyClient.R().SetResult(&res).Get(server + "/newGid")
	if err != nil || res["gid"] == "" {
		panic(fmt.Errorf("newGid error: %v, resp: %s", err, resp))
	}
	return res["gid"]
}
type IDGenerator struct {
	parentID string
	branchID int
}