def encode_request(name, permits):
    client_message = ClientMessage(payload_size=calculate_size(name, permits))
    client_message.set_message_type(REQUEST_TYPE)
    client_message.set_retryable(RETRYABLE)
    client_message.append_str(name)
    client_message.append_int(permits)
    client_message.update_frame_length()
    return client_message


# Empty decode_response(client_message), this message has no parameters to decode
Encode request into client_message
dataset/ETHPy150Open hazelcast/hazelcast-python-client/hazelcast/protocol/codec/semaphore_acquire_codec.py/encode_request