order caching

This commit is contained in:
shoopea 2020-01-02 23:11:03 +08:00
parent 3c3aa1cbdb
commit 6650f650ae

12
obj.go
View File

@ -29,6 +29,12 @@ var (
func initCache() { func initCache() {
var err error var err error
err = loadObjType()
logOnError(err, "initCache : caching obj_type")
err = loadObjSubType()
logOnError(err, "initCache : caching obj_sub_type")
resetMsgParsingRules() resetMsgParsingRules()
msgParsingRules, err = loadMsgParsingRules() msgParsingRules, err = loadMsgParsingRules()
logOnError(err, "initCache : message parsing rules") logOnError(err, "initCache : message parsing rules")
@ -48,12 +54,6 @@ func initCache() {
err = loadObjMsg() err = loadObjMsg()
logOnError(err, "initCache : caching msgs") logOnError(err, "initCache : caching msgs")
err = loadObjType()
logOnError(err, "initCache : caching obj_type")
err = loadObjSubType()
logOnError(err, "initCache : caching obj_sub_type")
} }
func loadObjType() error { func loadObjType() error {