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.

def get_shard_num_by_key(self, key):
        """
        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.
        """
        key_id = self._get_key_id_from_key(key)
        return self.get_shard_num_by_key_id(key_id)