minghuaw / fe2o3-amqp

A rust implementation of the AMQP1.0 protocol based on serde and tokio.
MIT License
59 stars 7 forks source link

do not override .hostname() or .domain() from builder with parsed URI #263

Closed brandonros closed 1 month ago

brandonros commented 1 month ago

painstakingly addresses #257

minghuaw commented 1 month ago

I think the docs will need to be updated to reflect this change as well

brandonros commented 1 month ago

I think the docs will need to be updated to reflect this change as well

can you help me understand how your vision? for example:

    let connection = Connection::builder()
        .container_id(container_id)
        .domain(relay_domain) // extra -relay
        .hostname(relay_domain) // extra -relay
        .tls_connector(tls_connector)
        .alt_tls_establishment(true)
        //.open_with_stream(ws_stream)
        .open(connection_string.as_str())
        .await
        .unwrap();

.open(connection_string is its own host

in order to do an override, i would've thought .hostname overrides the host for the container

i'm down for a .host() non-breaking (or we can just close this), i just know this is something rhea suppots

https://github.com/search?q=repo%3Aamqp%2Frhea%20host&type=code

brandonros commented 1 month ago

rhea showing it configurable: https://github.com/amqp/rhea/blob/8fa5eb545e52732ee95e4a88597e19b7ec62bf05/lib/frames.js#L142

minghuaw commented 1 month ago

Closing in favor of #276