Initializes a new instance of the ProxySocketHandler
class.
The proxy socket used for communication.
The subdomain associated with the connection.
Processes the write queue for a specific connection name. Writes data in chunks to the proxy socket while ensuring the order of operations is maintained.
The name of the connection whose queue is being processed.
A promise that resolves when the queue is fully processed.
write
callback.Adds data to the write queue for a specific connection name and ensures it is written in order. If the queue is not already being processed, it starts processing immediately.
The data to be written to the proxy socket.
The name of the connection associated with the data.
A promise that resolves when the data is successfully written or rejects if an error occurs.
A class for handling ordered data writes to a proxy socket. This class manages write queues for multiple connections and ensures data is sent in the correct order.
Features:
Usage:
writeDataInOrder
to enqueue data for a specific connection name.