so i have a weird issue.. i am using ktor with tom...
# ktor
n
so i have a weird issue.. i am using ktor with tomcat and am running it with ./gradlew tomcatRun and i also have a nginx reverse proxy set up for ssl a single endpoint where i am building html and link to a stylesheet gives a empty response
d
Have you tried to run standalone instead of with tomcat? Since you have a nginx doing reverse-proxy you probably won’t need tomcat at all
n
actually everywhere where i use
call.respondHtml
breaks on me.. i just did not notice
d
do you have a stacktrace?
n
thats the thing its just a empty reponse and the server is not complaining at all
d
and I would try Netty if you can, since it is the most tested backend, to see if it works there and reduce the issue
n
i think it sends the data and the browser does not accept it
i will go back to standalone netty
d
well, try to curl/wget it to see the full response including headers
n
Copy code
⌁74% [nikky:~] % curl <https://curse.nikky.moe/api/widget/233564>     
curl: (52) Empty reply from server
okay so at least the brwoser did not lie to me
d
🙂
that’s with tomcat, right?
or with Netty?
n
that was still using tomcat
now i am trying to get tomcat to shut down on my dev laptop so i can test if netty will work
👌 1
the damn thing just hogs the port.. kill -9 it is then
so yes it works in netty
and in tomcat all html builder responses are just empty
d
other responses work fine?
n
other reponses i use are redirect and JSON
and they work
well i use this a lot
ApplicationCall.respond(message: Any)
d
and that one works fine?
So maybe it is an issue with tomcat + respondText with writter?
does it fail without nginx as reverse proxy?
though it should because nginx acts as a normal http client
n
it seems to work fine.. there was one stacktrace like that but it was in my idea run dialog and i forgot to save it.. cannot reproduce either
it does not fail when i connect directly to :8080 using tomcat
i first suspected i hat the ports set up incorrectly or so.. but it seems to work fine with netty
d
uhm, that’s strange then
n
i am using stylesheetLink in my html builder code .. so i thought it might just try to use a css thats on a different port and my browser complains.. but thats not what happened.. there was no response at all and no errors being logged for it
and not all my html builders had stylesheets either
in my code it errors on
Copy code
> call.respondHtml {
   widget(id, version)
}
that is with
tomcatRunWar
d
Nice. Can you create a bug report at github?
n
d
thanks!