commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Min Cha <minslo...@gmail.com>
Subject Re: Robust-Task introduction
Date Fri, 20 Mar 2009 17:20:11 GMT
Hi. ted.
Thanks for your question.

In general, MQ is using to send messages among distribued servers in
enterprise environment.
I think that workflow you mentioned is workflow on the viewpoint of
integration.

On the other hands, Robust-Task handles general worlflow on one process or
one marchine.
For example, you can think of database transaction code which inserts data
to various tables. In this case, you might not choose MQ to implment that.

Robust-Task is similar to 'Apache commons chain' rather than MQ.
However, Robust-Task has more advantages than Apache commons chain.

First, Robust-Task is based on DSL(Domain Specific Langueage). It makes code
more READABLE. You can compare with the code style of Robust-Task and the
code style of Apache commons chain.

=== Robust-Task ===

new TaskChain()
  .add(new GenesisCoupeTask())
  .add(new TuscanyCoupeTask())
  .add(new TiburonCoupeTask())
.execute();

=== Apache commons chain ===

public class SellVehicleChain extends ChainBase {
  public SellVehicleChain() {
    super();
    addCommand(new GenesisCoupeTask());
    addCommand(new TuscanyCoupeTask());
    addCommand(new TiburonCoupeTask());
  }

  public static void main(String[] args) throws Exception {
    Command process = new SellVehicleChain();
    Context ctx = new ContextBase();
    process.execute(ctx);
  }
}

Second, Robust-Task provides Task decoration which can add special function
to Task as following.

=== LoggingCurrentTimeTask is run asynchronously ===
Method-Chaining style

new LoggingCurrentTimeTask()
  .areWrappedByAsycer()
.execute();

Nested Function style

asyncer(
  task(new LoggingCurrentTimeTask()),
).execute();

Last of all, Robust-Task provides combination among Task, Task-Chain and
Task-Decoration.
This can be called 'Potent combination'.
Using this feature, you can write flexible expression as following.

=== Combination among Task, Task-Chain and Task-Decoration ===

aspect(
  before(new LoggingCurrentTimeTask()),
  task(new TaskChain()
    .add(new GenesisCoupeTask())
    .add(new TuscanyCoupeTask())
    .add(new TiburonCoupeTask())),
  after(new AfterTask().areWrappedByRetryFailover().failover(new
FailoverTask()))
).areWrappedByAsycer().execute();



On Sat, Mar 21, 2009 at 12:56 AM, Ted Dunning <ted.dunning@gmail.com> wrote:

> How is this different from things like OpenMQ (from Sun) or ActiveMQ
> (apache)?
>
> These do workflow pretty well.d
>
> On Fri, Mar 20, 2009 at 6:04 AM, Min Cha <minslovey@gmail.com> wrote:
>
> > Hi, Niclas.
> > Thanks for your opinion.
> >
> > I wonder whether I am understanding a message from you.
> > Do you think this project should or can be a component in Commons?
> >
> > If so,  I would like to know how to be a component in Commons.
> > IMHO, Robust-Task has a possibility to be a good contributor to Java and
> > Apache community.
> >
> > Cheers.
> >
> > On Fri, Mar 20, 2009 at 12:54 PM, Niclas Hedhman <niclas@hedhman.org>
> > wrote:
> >
> > > I think this is a neat thing that Commons might pick up on, as I see a
> > > problem of it to be large enough for its own community.
> > >
> > > Cheers
> > > Niclas
> > >
> > > On Wed, Mar 18, 2009 at 8:53 AM, Min Cha <minslovey@gmail.com> wrote:
> > > > Hi, all.
> > > >
> > > > I am developing a framework called as Robust-Task.
> > > > Robust-Task is a framework which helps you write READABLE code when
> you
> > > need
> > > > to express complex or long business flow.
> > > > (Recently, 0.1 concept version was released.)
> > > > I would like to see that the idea of Robust-Task is valuable through
> > the
> > > > opinions of Apache incubator members and Apache commons member.
> > > > Following is a document to introduce Robust-Task.
> > > >
> > > > http://code.google.com/p/robust-coupe/wiki/RobustTaskIntroduction
> > > >
> > > > If you have a opinion, please reply to this mail.
> > > > Thanks for your reading.
> > > >
> > > > --
> > > > Min Cha, Dreaming Developer
> > > > English : http://minslovey.blogspot.com
> > > > Korean : http://minslovey.tistory.com
> > > >
> > >
> > >
> > >
> > > --
> > > http://www.qi4j.org - New Energy for Java
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: general-unsubscribe@incubator.apache.org
> > > For additional commands, e-mail: general-help@incubator.apache.org
> > >
> > >
> >
> >
> > --
> > Min Cha, Dreaming Developer
> > English : http://minslovey.blogspot.com
> > Korean : http://minslovey.tistory.com
> >
>
>
>
> --
> Ted Dunning, CTO
> DeepDyve
>
> 111 West Evelyn Ave. Ste. 202
> Sunnyvale, CA 94086
> www.deepdyve.com
> 408-773-0110 ext. 738
> 858-414-0013 (m)
> 408-773-0220 (fax)
>



-- 
Min Cha, Dreaming Developer
English : http://minslovey.blogspot.com
Korean : http://minslovey.tistory.com

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