Two Questions, both related to debugging: 1. how c...
# kobweb
j
Two Questions, both related to debugging: 1. how can I attach a debugger to my (jvm) kobweb server? The only gradle task I see to run the server is
kobwebStart
but that detaches the actual server process. 2. can I get an instance of
Logger
outside of a request context? e.g. to log some things on server initialization?
d
For 2, you can get a logger inside an
InitApi
method: https://github.com/varabyte/kobweb#initapi-methods-and-initializing-services Would that be enough for you?
j
Ah nice! Missed that, sorry.
d
It's all good! The README is massive.
j
InitApi
should work, let me try it
👍 1
d
You asking questions like this actually helps the community be aware of stuff like this so I appreciate it
🎉 1
j
Forgot to follow up but yes, InitApi was perfect. 🎉
d
Thanks for the follow-up. Glad to hear it worked!