code: func (s *SQLStore) newSQLSubStore(channelID int64, limits *SubStoreLimits) *SQLSubStore {
  	subStore := &SQLSubStore{
  		sqlStore:  s,
  		channelID: channelID,
  		maxSubID:  &s.maxSubID,
  		limits:    *limits,
  	}
  	subStore.log = s.log
  	if s.opts.NoCaching {
  		subStore.subLastSent = make(map[uint64]uint64)
  	} else {
  		subStore.cache = &sqlSubAcksPendingCache{
  			subs: make(map[uint64]*sqlSubAcksPending),
  		}
  	}
  	return subStore
  }
docs: // creates an instance of SQLSubStore