code: def get_shard_num_by_key(self, key):
          
          key_id = self._get_key_id_from_key(key)
          return self.get_shard_num_by_key_id(key_id)
docs: get_shard_num_by_key returns the Redis shard number givne a key.
          Keyword arguments:
          key -- the key (e.g. 'friend_request:{12345}')
  
          See get_shard_by_key for more details as this method behaves the same
          way.