Closed karthik2804 closed 4 months ago
I tested this only with the incomingHandler
annotation but the above is a good catch. Let me go do some more testing/digging and report back.
It might be that name
is just the interface name and so that the check should be using name_world_key
against the interface world key for the full wasi:incoming-handler@2.0.0
case.
Ahh, name
is shadowing the outer name, so it should be renamed to Some(iface_name) =
I think.
To confirm my understanding the allowed exports are incomingHandler
and "wasi:http/incoming-handler@0.2.0"
correct? or is the explicit notation supposed to be wasiHttpIncomingHandler020
?
Yes exactly, so checking iface_name.toCamelCase()
and name
which are separate originating values.
I believe we are already doing both the checks on line 388 (fully qualified name) and line 392 (sugared name) unless I am missing something but will rename it to iface_name
edit: I may have misunderstood the original comment but have renamed the variable.
@guybedford let me know if there is anything else to address for this PR.
@guybedford would it be possible to get a release with this PR? Thanks!
Sure, I've published a 0.10.1.
This PR adds the ability to use the
fetchEvent
from StarlingMonkey to handle incoming HTTP requests. This needs thehttp
feature to be enabled explicitly.