Browse Source

fix comments

pull/443/head
yedf2 3 years ago
parent
commit
fef6436759
  1. 1
      dtmsvr/cron.go
  2. 1
      dtmsvr/storage/boltdb/boltdb.go
  3. 1
      dtmsvr/storage/redis/redis.go
  4. 2
      dtmsvr/storage/sql/sql.go

1
dtmsvr/cron.go

@ -57,6 +57,7 @@ func CronUpdateTopicsMap() {
}
}
// CronUpdateTopicsMap cron updates topics map once
func CronUpdateTopicsMapOnce() {
defer handlePanic(nil)
updateTopicsMap()

1
dtmsvr/storage/boltdb/boltdb.go

@ -483,6 +483,7 @@ func (s *Store) ResetCronTime(after time.Duration, limit int64) (succeedCount in
return
}
// ResetTransGlobalCronTime reset nextCronTime of one global trans.
func (s *Store) ResetTransGlobalCronTime(g *storage.TransGlobalStore) error {
old := g.UpdateTime
err := s.boltDb.Update(func(t *bolt.Tx) error {

1
dtmsvr/storage/redis/redis.go

@ -330,6 +330,7 @@ return tostring(i)
return
}
// ResetTransGlobalCronTime reset nextCronTime of one global trans.
func (s *Store) ResetTransGlobalCronTime(global *storage.TransGlobalStore) error {
now := dtmutil.GetNextTime(0)
global.NextCronTime = now

2
dtmsvr/storage/sql/sql.go

@ -204,7 +204,7 @@ func (s *Store) ResetCronTime(after time.Duration, limit int64) (succeedCount in
return affected, affected == limit, err
}
// reset nextCronTime of one global trans.
// ResetTransGlobalCronTime reset nextCronTime of one global trans.
func (s *Store) ResetTransGlobalCronTime(global *storage.TransGlobalStore) error {
now := getTimeStr(0)
where := map[string]string{

Loading…
Cancel
Save