yes, calling APP layer API (beans) from the UI is OK.
 I was thinking if it is possible the other way around : to somehow inform
the UI that soemthing happened on the backend and it has to display a
message accordingly. (kind of polling from UI to back end). The APP layer
bean triggering an event in UI application. Coud this be done?

-----Original Message-----
From: Turansky, Mark [mailto:[EMAIL PROTECTED]
Sent: Monday, December 08, 2003 9:57 AM
To: Struts Users Mailing List
Subject: RE: designing simple scheduler


how to reuse beans?

You should be making your beans without any thought of the web whatsoever.
THEN your Actions can calls your beans.  This way, the Actions are clients
of your API.  By having an API containing business logic (instead of
business logic in your actions), you promote reuse.

An additional benefit of this type of bean design is that you can test it
automatedly (JUnit!) without having Tomcat or servlet container running.

The Action, in this case, is the glue connecting all your business logic
(beans).  Replace the glue with another type of glue and you can reuse your
business components anywhere.

-----Original Message-----
From: Voinea, Marina [mailto:[EMAIL PROTECTED]
Sent: Monday, December 08, 2003 9:19 AM
To: 'Struts Users Mailing List'
Subject: RE: designing simple scheduler



 Vic, can you please explain a bit more how do you reuse your beans ? (and
have cron job call yor application - you know the idea of separating layers,
how is your architecture like now ?)

 (we would need something similar...)
Thanks,
M.

-----Original Message-----
From: Vic Cekvenich [mailto:[EMAIL PROTECTED]
Sent: Monday, December 08, 2003 6:29 AM
To: [EMAIL PROTECTED]
Subject: Re: designing simple scheduler


With a layered MVC application you can re-use beans outside of Struts.
Have cron call beans application. I do.
.V

Raman wrote:
> Hello,
> 
> I am using struts/beans  in my application. I want a scheduler kind of
thing that after regular interval of time should check the db and send
mails.
> I want some suggestions regarding running it on red hat linux and way to
go for this.
> 
> Cheers,
> Raman Garg



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to