users@glassfish.java.net

RE: Need design suggestions

From: Deepu Syamaladevi Janardhananachary (UST, IND) <"Deepu>
Date: Tue, 6 Jul 2010 14:14:51 +0530

Did u try extending the abstract class TimerTask without using Quartz?

Regards,
Deepu Janardhananachary


-----Original Message-----
From: glassfish_at_javadesktop.org [mailto:glassfish_at_javadesktop.org]
Sent: Monday, July 05, 2010 9:46 PM
To: users_at_glassfish.dev.java.net
Subject: Need design suggestions

Hello. I am beginner in JSF (only have created two projects with Glassfish and Icefaces using Netbeans). I have created a medium sized project (web application) following a very basic process: implementation of a database, generation of entities from the database schema, generation of "JPA controllers" (netbeans) from the generated entities and effort focussed on presentation layer and bussiness logic. The goal was achieved, however my client needs scheduling of some control tasks. I have made two prototypes using Quartz: both quartz schedulers are started when application is deployed, the first approach was to duplicate some persistence entites and call their methods from within the quartz job (i could not reference the JPA controllers from the Quartz job); the second approach was using a specific Quartz job (SendQueueMessageJob) and send messages to an Message Driven Bean, also duplicating some entities (i could not reference the JPA controllers from the MDB).
My questions are focused in code reuse:
* Is there a way of calling the JPA controllers from within the Quartz job? (The JPA controllers are container managed).
* Is there a way of calling the JPA controllers from within the Message Driven Beans?
* I must redesign my application to improve code reuse? If i must do it, what design guidelines i could follow?

Thanks in advance.
[Message sent by forum member 'gxcr']

http://forums.java.net/jive/thread.jspa?messageID=476801

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
For additional commands, e-mail: users-help_at_glassfish.dev.java.net