diff --git a/server/accounts.go b/server/accounts.go index 5539a6d868..8f62104b38 100644 --- a/server/accounts.go +++ b/server/accounts.go @@ -3502,7 +3502,7 @@ func (s *Server) updateAccountClaimsWithRefresh(a *Account, ac *jwt.AccountClaim a.jsLimits = nil } - a.updated = time.Now().UTC() + a.updated = time.Now() clients := a.getClientsLocked() a.mu.Unlock() @@ -3961,7 +3961,7 @@ func removeCb(s *Server, pubKey string) { a.mpay = 0 a.mconns = 0 a.mleafs = 0 - a.updated = time.Now().UTC() + a.updated = time.Now() jsa := a.js a.mu.Unlock() // set the account to be expired and disconnect clients diff --git a/server/gateway.go b/server/gateway.go index 7907b01488..afc7568322 100644 --- a/server/gateway.go +++ b/server/gateway.go @@ -761,7 +761,7 @@ func (s *Server) createGateway(cfg *gatewayCfg, url *url.URL, conn net.Conn) { // Snapshot server options. opts := s.getOpts() - now := time.Now().UTC() + now := time.Now() c := &client{srv: s, nc: conn, start: now, last: now, kind: GATEWAY} // Are we creating the gateway based on the configuration diff --git a/server/monitor.go b/server/monitor.go index 66045cd084..781bfeda32 100644 --- a/server/monitor.go +++ b/server/monitor.go @@ -783,7 +783,7 @@ type RouteInfo struct { // Routez returns a Routez struct containing information about routes. func (s *Server) Routez(routezOpts *RoutezOptions) (*Routez, error) { rs := &Routez{Routes: []*RouteInfo{}} - rs.Now = time.Now().UTC() + rs.Now = time.Now() if routezOpts == nil { routezOpts = &RoutezOptions{} @@ -970,7 +970,7 @@ func (s *Server) Subsz(opts *SubszOptions) (*Subsz, error) { slStats := &SublistStats{} // FIXME(dlc) - Make account aware. - sz := &Subsz{s.info.ID, time.Now().UTC(), slStats, 0, offset, limit, nil} + sz := &Subsz{s.info.ID, time.Now(), slStats, 0, offset, limit, nil} if subdetail { var raw [4096]*subscription @@ -1595,7 +1595,7 @@ func (s *Server) updateVarzConfigReloadableFields(v *Varz) { v.MaxPending = opts.MaxPending v.TLSTimeout = opts.TLSTimeout v.WriteDeadline = opts.WriteDeadline - v.ConfigLoadTime = s.configTime + v.ConfigLoadTime = s.configTime.UTC() // Update route URLs if applicable if s.varzUpdateRouteURLs { v.Cluster.URLs = urlsToStrings(opts.Routes) diff --git a/server/mqtt.go b/server/mqtt.go index 9353563a17..2d214e0118 100644 --- a/server/mqtt.go +++ b/server/mqtt.go @@ -422,7 +422,7 @@ func (s *Server) createMQTTClient(conn net.Conn, ws *websocket) *client { if maxSubs == 0 { maxSubs = -1 } - now := time.Now().UTC() + now := time.Now() c := &client{srv: s, nc: conn, mpay: maxPay, msubs: maxSubs, start: now, last: now, mqtt: &mqtt{}, ws: ws} c.headers = true diff --git a/server/server.go b/server/server.go index 545b4b1cec..33230f1e0b 100644 --- a/server/server.go +++ b/server/server.go @@ -373,7 +373,7 @@ func NewServer(opts *Options) (*Server, error) { info.TLSAvailable = true } - now := time.Now().UTC() + now := time.Now() s := &Server{ kp: kp, @@ -884,7 +884,7 @@ func (s *Server) configureAccounts(reloading bool) (map[string]struct{}, error) s.mu.Lock() acc.mu.Lock() } - acc.updated = time.Now().UTC() + acc.updated = time.Now() acc.mu.Unlock() return true }) @@ -1383,7 +1383,7 @@ func (s *Server) createInternalClient(kind int) *client { if kind != SYSTEM && kind != JETSTREAM && kind != ACCOUNT { return nil } - now := time.Now().UTC() + now := time.Now() c := &client{srv: s, kind: kind, opts: internalOpts, msubs: -1, mpay: -1, start: now, last: now} c.initClient() c.echo = false @@ -1453,7 +1453,7 @@ func (s *Server) registerAccountNoLock(acc *Account) *Account { acc.lqws = make(map[string]int32) } acc.srv = s - acc.updated = time.Now().UTC() + acc.updated = time.Now() accName := acc.Name jsEnabled := len(acc.jsLimits) > 0 acc.mu.Unlock() @@ -2581,7 +2581,7 @@ func (s *Server) createClient(conn net.Conn) *client { if maxSubs == 0 { maxSubs = -1 } - now := time.Now().UTC() + now := time.Now() c := &client{srv: s, nc: conn, opts: defaultOpts, mpay: maxPay, msubs: maxSubs, start: now, last: now} @@ -2748,7 +2748,7 @@ func (s *Server) createClient(conn net.Conn) *client { // This will save off a closed client in a ring buffer such that // /connz can inspect. Useful for debugging, etc. func (s *Server) saveClosedClient(c *client, nc net.Conn, reason ClosedState) { - now := time.Now().UTC() + now := time.Now() s.accountDisconnectEvent(c, now, reason.String())