camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Antoine DESSAIGNE <antoine.dessai...@gmail.com>
Subject Stream the result of a database query
Date Mon, 19 May 2014 16:59:53 GMT
Hi everyone,

I've looked into the source code and it doesn't seem like its possible to
stream the result of an SQL query in camel using either the SqlComponent or
the JdbcComponent. This would be really useful when reading a large DataSet.

If you confirm that it's not the case right now, I would gladly fill a JIRA
issue and submit a pull request. I think I'm going to use another option in
SqlOutputType named StreamList and return an Iterator that wraps the
ResultSet in this case

That way it would look like
from("direct:streamDB")
.to("sql:select * from actors?outputType=StreamList")
.split(body())
    .to("direct:processSingleActor")

What do you think ?

Antoine.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message