question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Feature request] Ktor support

See original GitHub issue

Hi! I’m trying to use JTE with Ktor but only only simple examples work. When I’m trying to use custom models - classloader mess happens 😃

Will prepare minimal sample later. Any ideas to overcome this issue with dirty fix on my side now?

Caused by: java.lang.ClassCastException: class app.Model cannot be cast to class app.Model (app.Model is in unnamed module of loader io.ktor.server.engine.OverridingClassLoader$ChildURLClassLoader @4d0d9fe7; app.Model is in unnamed module of loader 'app')
	at gg.jte.generated.JtedashboardGenerated.render(JtedashboardGenerated.java:9)
	at gg.jte.generated.JtedashboardGenerated.renderMap(JtedashboardGenerated.java:26)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at gg.jte.internal.Template.renderMap(Template.java:49)
	at gg.jte.TemplateEngine.render(TemplateEngine.java:153)

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:9 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
dectorcommented, Dec 13, 2020

@casid Thank you, will update! 😃

1reaction
casidcommented, Dec 13, 2020

@dector release 1.5.0 is out and available on maven central. It contains this feature 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Handling requests - Ktor
Ktor allows you to handle incoming requests and send responses inside route handlers. You can perform various actions when handling requests ...
Read more >
Incoming request body validation : KTOR-503
KTOR -2962 KTOR Should Support Request Validation Through Annotations ... This is a core feature of all HTTP servers, most of the incoming...
Read more >
服务器 Requests - Ktor
When using the Routing feature, or when intercepting requests, you can access the call property inside handlers. ... Reverse proxy support: origin and...
Read more >
How to Make HTTP Requests With Ktor-Client in Android
For example, we are setting the Ktor logging feature. This logs all the Ktor requests and responses that help you when debugging our...
Read more >
kotlin - Is there any way to make a fake call from Ktor to itself ...
So the part between I get data from kafka and recieved it at my DB service is a question :) The purpose is...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found