You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
WARNING: Internal server error
io.helidon.http.RequestException: Failed to map interface io.helidon.dbclient.DbRow to interface jakarta.json.JsonObject: Failed to map source of class 'io.helidon.dbclient.jdbc.JdbcRow'
at io.helidon.http.RequestException$Builder.build(RequestException.java:139)
at io.helidon.webserver.http.ErrorHandlers.unhandledError(ErrorHandlers.java:202)
at io.helidon.webserver.http.ErrorHandlers.lambda$handleError$1(ErrorHandlers.java:182)
at java.base/java.util.Optional.ifPresentOrElse(Optional.java:198)
at io.helidon.webserver.http.ErrorHandlers.handleError(ErrorHandlers.java:181)
at io.helidon.webserver.http.ErrorHandlers.runWithErrorHandling(ErrorHandlers.java:118)
at io.helidon.webserver.http.Filters$FilterChainImpl.proceed(Filters.java:121)
at io.helidon.webserver.observe.metrics.MetricsFeature.lambda$configureVendorMetrics$1(MetricsFeature.java:90)
at io.helidon.webserver.http.Filters$FilterChainImpl.proceed(Filters.java:119)
at io.helidon.webserver.http.Filters.executeFilters(Filters.java:87)
at io.helidon.webserver.http.Filters.lambda$filter$0(Filters.java:83)
at io.helidon.webserver.http.ErrorHandlers.runWithErrorHandling(ErrorHandlers.java:75)
at io.helidon.webserver.http.Filters.filter(Filters.java:83)
at io.helidon.webserver.http.HttpRouting.route(HttpRouting.java:109)
at io.helidon.webserver.http1.Http1Connection.route(Http1Connection.java:332)
at io.helidon.webserver.http1.Http1Connection.handle(Http1Connection.java:169)
at io.helidon.webserver.ConnectionHandler.run(ConnectionHandler.java:155)
at io.helidon.common.task.InterruptableTask.call(InterruptableTask.java:47)
at io.helidon.webserver.ThreadPerTaskExecutor$ThreadBoundFuture.run(ThreadPerTaskExecutor.java:239)
at java.base/java.lang.VirtualThread.run(VirtualThread.java:311)
Caused by: io.helidon.common.mapper.MapperException: Failed to map interface io.helidon.dbclient.DbRow to interface jakarta.json.JsonObject: Failed to map source of class 'io.helidon.dbclient.jdbc.JdbcRow'
at io.helidon.dbclient.DbMapperManagerImpl.createMapperException(DbMapperManagerImpl.java:130)
at io.helidon.dbclient.DbMapperManagerImpl.executeMapping(DbMapperManagerImpl.java:82)
at io.helidon.dbclient.DbMapperManagerImpl.read(DbMapperManagerImpl.java:45)
at io.helidon.dbclient.DbRowBase.as(DbRowBase.java:68)
at io.helidon.examples.dbclient.pokemons.PokemonService.lambda$listPokemons$1(PokemonService.java:117)
at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:197)
at io.helidon.dbclient.jdbc.JdbcRow$Spliterator.tryAdvance(JdbcRow.java:100)
at java.base/java.util.Spliterator.forEachRemaining(Spliterator.java:332)
at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:509)
at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:499)
at java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:921)
at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
at java.base/java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:693)
at io.helidon.dbclient.AutoClosingStream.collect(AutoClosingStream.java:132)
at io.helidon.examples.dbclient.pokemons.PokemonService.listPokemons(PokemonService.java:118)
at io.helidon.webserver.http.HttpRouting$RoutingExecutor.doRoute(HttpRouting.java:668)
at io.helidon.webserver.http.HttpRouting$RoutingExecutor.call(HttpRouting.java:627)
at io.helidon.webserver.http.HttpRouting$RoutingExecutor.call(HttpRouting.java:605)
at io.helidon.webserver.http.ErrorHandlers.runWithErrorHandling(ErrorHandlers.java:75)
... 14 more
Caused by: java.lang.ClassCastException: class io.helidon.common.mapper.ValueBacked cannot be cast to class java.lang.Integer (io.helidon.common.mapper.ValueBacked is in unnamed module of loader 'app'; java.lang.Integer is in module java.base of loader 'bootstrap')
at io.helidon.dbclient.jsonp.JsonProcessingMapper.lambda$static$2(JsonProcessingMapper.java:47)
at io.helidon.dbclient.jsonp.JsonProcessingMapper.toJson(JsonProcessingMapper.java:115)
at io.helidon.dbclient.jsonp.JsonProcessingMapper.lambda$read$13(JsonProcessingMapper.java:89)
at java.base/java.util.HashMap$Values.forEach(HashMap.java:1073)
at io.helidon.dbclient.DbRowBase.forEach(DbRowBase.java:63)
at io.helidon.dbclient.jsonp.JsonProcessingMapper.read(JsonProcessingMapper.java:89)
at io.helidon.dbclient.jsonp.JsonProcessingMapper.read(JsonProcessingMapper.java:40)
at io.helidon.dbclient.DbMapperManagerImpl.lambda$read$0(DbMapperManagerImpl.java:45)
at io.helidon.dbclient.DbMapperManagerImpl.executeMapping(DbMapperManagerImpl.java:78)
... 31 more
This can be reproduced on examples/dbclient/pokemon:
curl http://localhost:51054/db/pokemon
Failed to map interface io.helidon.dbclient.DbRow to interface jakarta.json.JsonObject: Failed to map source of class 'io.helidon.dbclient.jdbc.JdbcRow'
The text was updated successfully, but these errors were encountered:
- DbColumn.get() overrides Value.get() using as() instead of as().get() thus it returns an instance of Value instead of the raw value.
- Add a unit test in dbclient/jsonp
Fixeshelidon-io#7842
- DbColumn.get() overrides Value.get() using as() instead of as().get() thus it returns an instance of Value instead of the raw value.
- Add a unit test in dbclient/jsonp
Fixes#7842
Environment Details
Problem Description
Steps to reproduce
This can be reproduced on
examples/dbclient/pokemon
:The text was updated successfully, but these errors were encountered: