Hey, I'm working on moving to using the Resource p...
# ktor
r
Hey, I'm working on moving to using the Resource plugin on the server for type-safe requests, however it seems like those endpoints aren't picked up by the intellij plugin. Is this intended or is there something I am missing?
a
Do you mean that they aren’t present in a generated OpenAPI specification?
r
Sorry I mean they aren't present in the endpoints panel on the side (as shown in this screenshot) I have a resource with routes along the lines of
Copy code
@Resource("/sites")
class Sites() {}

routing {
    get<Sites>() { ... }
    post<Sites>() { ... }
}
a
Unfortunately, I cannot reproduce this problem with the latest EAP version (IU-232.4421) of IDEA. The problem might be already fixed in a newer version of IntelliJ IDEA.
r
I'll switch to EAP and see if I can reproduce
Hmm strange, I have the exact same issue on EAP still. Other potentially useful pieces of info • It is a multimodule project • I'm using an extension function for the routes • The @Resource declaration isn't in the same file
a
Can you file an issue with a sample project attached?
r
Sure thing, will take me a bit to recreate it so may not see the issue till tomorrow
Ah I found the root of the issue, I was using the Resources themselves from another module that is a multiplatform module (so I can share the resource classes between my client and server for end-to-end type safety). Moving them into the server module itself solved the issue instantly. Would an issue with a sample project still be useful for resolving this?