[hibernate-dev] ScrollableResults and 6.0

Sanne Grinovero sanne at hibernate.org
Tue Jan 3 06:54:32 EST 2017


On 3 January 2017 at 11:39, Gunnar Morling <gunnar at hibernate.org> wrote:
> 2017-01-03 11:57 GMT+01:00 Sanne Grinovero <sanne at hibernate.org>:
>>
>> It sounds great but I'm not sure it's possible?
>
>
> WDYM specifically?
>
>> For example how would this handle projections? I guess it's a similar
>> doubt as the one Gunnar shared, but while he suggests a semi-typesafe
>> solution, I'm not sure how cool it is to give the feeling that types
>> are being checked when they might actually blow at runtime, if the
>> query string doesn't match expectations.
>> Could an Annotation Processor verify the declared return types really
>> match the HQL select?
>
>
> I understand your point, but isn't it the same for createQuery( "from Foo",
> Bar.class )? This also will only be detected at runtime. I.e. I don't see
> how it's worse for the tuple approach?

Yes it's the same problem: I wish we could fix that too.

If only someone here was a expert of annotation processors maybe he
could tell me if I'm dreaming :D


More information about the hibernate-dev mailing list