Skip to content

Commit

Permalink
squash commits for utils, server, fast_forward
Browse files Browse the repository at this point in the history
utils: replace GetMsgBufFor with PackBuffer

server: tweak shutdown procedure

fast_forward: replace cpool with transport
  • Loading branch information
IrineSistiana committed Feb 8, 2021
1 parent cba7a29 commit 9b117ef
Show file tree
Hide file tree
Showing 14 changed files with 691 additions and 583 deletions.
8 changes: 1 addition & 7 deletions dispatcher/plugin/cache/redis_cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,16 +63,10 @@ func (r *redisCache) get(ctx context.Context, key string) (v *dns.Msg, ttl time.
}

func (r *redisCache) store(ctx context.Context, key string, v *dns.Msg, ttl time.Duration) (err error) {
buf, err := utils.GetMsgBufFor(v)
wireMsg, buf, err := utils.PackBuffer(v)
if err != nil {
return err
}
defer utils.ReleaseMsgBuf(buf)

wireMsg, err := v.PackBuffer(buf)
if err != nil {
return err
}

return r.client.Set(ctx, key, wireMsg, ttl).Err()
}
182 changes: 0 additions & 182 deletions dispatcher/plugin/executable/fast_forward/cpool/pool.go

This file was deleted.

73 changes: 0 additions & 73 deletions dispatcher/plugin/executable/fast_forward/cpool/pool_test.go

This file was deleted.

Loading

0 comments on commit 9b117ef

Please sign in to comment.