Replies: 2 comments 15 replies
-
|
Beta Was this translation helpful? Give feedback.
3 replies
-
Another issue I founds is that it seems |
Beta Was this translation helpful? Give feedback.
12 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
While looking at the new gun_pool implementation I had some questions / feedback:
Host
+Port
but APIs likeinfo/1
take an argumentAuthority
instead. How is one supposed to compute this if you want to e.g. start a pool and then get its info (without having to store the pid somewhere)?Authority
is calculated internally, it seems that the same authority will be created for bothHost
+ 80 andHost
+ 443, e.g.start_pool("example.com", 80)
andstart_pool("example.com", 443)
will both generate a value of"example.com"
. Is this correct? Does Gun start a pool that can handle both TCP and TLS requests, or will it break if called with the type which it wasn't started with?<<"host">>
header, but an HTTP header can have any case so this fails if the user supplies e.g.<<"Host">>
. Probably some case conversion has to be done here?Host
argument when creating a pool (which has to be an inet string) and the<<"host">>
header which can be a binary. As a user it feels odd when they have an implicit connection but they're different types. In my option, a better API would allow binaries for theHost
argument and internally make it a list if needed by inet.Beta Was this translation helpful? Give feedback.
All reactions