Documentation ¶
Index ¶
- Constants
- func CurrentMillis() int64
- func DeepCopyMap(params map[string]string) map[string]string
- func GetConfigCacheKey(dataId string, group string, tenant string) string
- func GetDurationWithDefault(metadata map[string]string, key string, defaultDuration time.Duration) time.Duration
- func GetGroupName(serviceName string, groupName string) string
- func GetServiceCacheKey(serviceName string, clusters string) string
- func GetStatusCode(response *http.Response) string
- func GetUrlFormedMap(source map[string]string) (urlEncoded string)
- func JsonToService(result string) *model2.Service
- func LocalIP() string
- func Md5(content string) (md string)
- func ToJsonString(object interface{}) string
- func TransformObject2Param(object interface{}) (params map[string]string)
- func TruncateContent(content string) string
- type Semaphore
Constants ¶
View Source
const SHOW_CONTENT_SIZE = 100
Variables ¶
This section is empty.
Functions ¶
func CurrentMillis ¶
func CurrentMillis() int64
func GetDurationWithDefault ¶
func GetGroupName ¶
func GetServiceCacheKey ¶
func GetStatusCode ¶
get status code by response,default is NA
func GetUrlFormedMap ¶
func JsonToService ¶
func ToJsonString ¶
func ToJsonString(object interface{}) string
func TransformObject2Param ¶
func TruncateContent ¶
Types ¶
type Semaphore ¶
type Semaphore struct {
// contains filtered or unexported fields
}
func NewSemaphore ¶
func (*Semaphore) AvailablePermits ¶
func (*Semaphore) TryAcquire ¶
Click to show internal directories.
Click to hide internal directories.