Thanks for your feedback! Actually it's not silly, and I think it might even be working fine. We'd have to create the repository beans slightly different (using the type closure) to enable this kind of injection. Might be useful for e.g. a base class handling CRUD UI pages similar to the Seam 2 EntityHome feature.
-----Original Message----- From: Juliano Marques [mailto:[email protected]] Sent: Donnerstag, 17. Juli 2014 15:29 To: [email protected] Subject: RE: Null QueryInvocationContext in DS Data Module Hi Thomas, Your suggestion works perfectly. How silly of me, this is a pretty obvious thing... :-) Thanks a lot. Deltaspike is great, I'm really liking it. Keep up the good work! Regards, Juliano De: Thomas Hug <[email protected]> Para: "[email protected]" <[email protected]>, Data: 17/07/2014 09:51 Assunto: RE: Null QueryInvocationContext in DS Data Module Hi Juliano Please inject a PersonRepository. EntityRepository<Person, Long> ends up in a different bean and is not what you expect - actually it’s an internal bean which is will be called underneath, but as it misses a bunch of initialization steps done by the Data extension you’ll get the NullPointerException. Hope that helps… From: Thomas Hug [mailto:[email protected]] Sent: Donnerstag, 17. Juli 2014 14:33 To: [email protected] Subject: RE: Null QueryInvocationContext in DS Data Module Hi Juliano Sorry, missed your message. Will have a look at your sample. From: Juliano Marques [mailto:[email protected]] Sent: Donnerstag, 17. Juli 2014 14:17 To: [email protected] Subject: Re: Null QueryInvocationContext in DS Data Module Sorry, but does anyone could look at this example [1]? Am I missing something? Apparently I configured the application with all the requirements needed to run the data module correctly, but I keep getting a NullPointerException with any operation with the persistence database. Somehow, the QueryInvocationContext is null in EntityRepositoryHandler class. Please help. Thank you very much. [1] https://github.com/julianomqs/ds-data-module.git Atenciosamente, Juliano Marques Desenvolvimento Imobiliário Criciúma - SC Fone: (48) 3461-1000 De: Juliano Marques <[email protected]> Para: [email protected], Data: 15/07/2014 11:28 Assunto: Re: Null QueryInvocationContext in DS Data Module A simpler example at https://github.com/julianomqs/ds-data-module.git Thanks a lot. Atenciosamente, Juliano Marques Desenvolvimento Imobiliário Criciúma - SC Fone: (48) 3461-1000 De: Juliano Marques <[email protected]> Para: [email protected], Data: 14/07/2014 00:00 Assunto: Null QueryInvocationContext in DS Data Module Hi, Somehow the QueryInvocationContext is null in EntityRepositoryHandler, in DS DataModule. I have a multi-module maven project with DS core and data module. The project has: - a EntityManagerProducer (like DS data module docs) - beans.xml with BeanManagedUserTransactionStrategy - AuditEntityListener (for auditing) - DS core and DS data module (compile and runtime) dependencies I am missing something? Source at https://bitbucket.org/julianomqs/vidracaria Thanks a lot. Atenciosamente, *Juliano M.*
