Fix bug: blocking call to receive()

Response/Request static method to get the type (and set constructors as private)

Multiple optimizations