Welcome! Please see the About page for a little more info on how this works.

+2 votes
in Ions by

API Gateway supports this via MultiValueHeaders. Consideration should be given to how best to support multi-value parameters in ions.

https://aws.amazon.com/blogs/compute/support-for-multi-value-parameters-in-amazon-api-gateway/

https://docs.aws.amazon.com/apigateway/latest/developerguide/set-up-lambda-proxy-integrations.html#apigateway-multivalue-headers-and-parameters

Related issues in Pedestal.ion, "Duplicate header support (applicable to the set-cookie header)."

1 Answer

0 votes
by

I was just bitten by this too.

I reduced my problem to defining a [:http-direct :handler-fn], like this:

  (constantly
    {:status  200
     :headers {"x" ["1" "2"]}
     :body    ""})

the response I get is just

HTTP/2 500 
date: Mon, 31 Oct 2022 22:34:23 GMT
content-type: text/plain
content-length: 12
server: Jetty(9.4.44.v20210927)
apigw-requestid: a5EJajRaSQ0EMtQ=

Server Error

and the error in the datomic-{SystemName} log group is simply:

{
    "Msg": "http-endpoint respond failed: http://<custom-api-gw-domain>:8184/",
    "Ex": {
        "Via": [
            {
                "Type": "java.lang.ClassCastException"
            }
        ],
        "Trace": []
    },
    "Type": "Alert",
    "Tid": 18,
    "Timestamp": 1667255663263
}

without any stack trace, so it took awhile to narrow down to this minimal repro-case :(

I think it would be really helpful to mention this limitation in the documentation, at least.

Maybe adding a note about "Server Error" to https://docs.datomic.com/cloud/troubleshooting.html would help too.

Welcome to the Datomic Knowledgebase, where you can make features requests, ask questions and receive answers from other members of the community.
...