ktorio / ktor

Framework for quickly creating connected applications in Kotlin with minimal effort
https://ktor.io
Apache License 2.0
13.05k stars 1.07k forks source link

Call router from other router or websocket #1485

Open icode opened 4 years ago

icode commented 4 years ago

Like servlet forward, i want call router from webscoket on custom protocol. It's very useful. This is helpful to construct the realtime application based on websocket and reduce duplicate code, like Meteor. And use for graphql server

oleg-larshin commented 4 years ago

Please check the following ticket on YouTrack for follow-ups to this issue. GitHub issues will be closed in the coming weeks.

Stexxe commented 3 years ago

@icode could you please explain it in more detail? How in your opinion the code should look like?

victororlyk commented 1 year ago

Isn't it something with just call.respondRedirect https://api.ktor.io/ktor-server/ktor-server-core/io.ktor.server.response/respond-redirect.html?_ga=2.58103658.1352441211.1683398500-354363718.1683398500&_gl=1*1mgxe3z*_ga*MzU0MzYzNzE4LjE2ODMzOTg1MDA.*_ga_9J976DJZ68*MTY4MzM5ODUwMC4xLjEuMTY4MzM5ODU4OC40Mi4wLjA.