Results 1 to 5 of 5

Thread: starting point

  1. #1
    Join Date
    Jul 2007
    Location
    Mauritius
    Posts
    127

    Default starting point

    Hello batch people,
    I need a little help to get really started, please bear with me as I am a complete beginner. I am using the maven 2 webApp archetype to build a skeleton. I have added the 3 dependencies that was specified on the batch site.

    Now what I want to do is as follows:
    1.) a application that runs a small task(eg, ping an IP) every 1h

    Can anybody please tell me what are the other dependencies that I require for the scheduling and on which use case should I inspire myself ( http://static.springframework.org/sp...ses/index.html).


    Thanks in advance
    Kris

  2. #2
    Join Date
    Jun 2006
    Location
    The Netherlands
    Posts
    13,632

    Default

    scheduling is something different than a batch job. For scheduling you want to take a look at the java TimerTask and/or Quartz (for more advanced scheduling).
    Marten Deinum
    Java Consultant / Pragmatist / Open Source Enthousiast / Author


    Pro Spring MVC: With Web Flow
    Conspect

    Have you read the reference guide.
    Use the [ code ] tags, young padawan

  3. #3
    Join Date
    Jul 2007
    Location
    Mauritius
    Posts
    127

    Lightbulb

    i will be adding quartz to the dependency and try to learn how it works.
    That would be for the scheduling part!

    My batch part should be the part which pings the required addresses.
    Any clues for this.

    I am a little lost into how to make my scheduling part connect to the batch part

    I guess I should understand better after taking a deeper look at Quartz.

    Thanks
    Kris

  4. #4

    Default

    I don't think pinging an IP address makes much sense as batch job (no need for transactions or restartability). If the purpose is to get familiar with the framework on a simple example I would suggest to start with the sample jobs. Good first step towards real use is to create the schema in your database and configure samples to use the 'real' database instead of in-memory HSQL. This will allow you to see what is actually happening when you run a job.

    Concerning Quartz integration, Spring offers good support so it is straightforward to do scheduling. You can use the BatchCommandLineLauncher to launch a batch job.
    Last edited by robert.kasanicky; Oct 18th, 2007 at 03:17 AM.

  5. #5
    Join Date
    Jul 2007
    Location
    Mauritius
    Posts
    127

    Default

    Robert,
    thanks for the reply.
    My aim is indeed to get more acquainted with the framework.
    I believe your help will help me progress a little bit. I will post my new questions on the forum as they arise.

    p.s I apologize if my questions sound silly, but I am just getting started and there are no books on Spring-Batch(as far as I know). They will get smarter as I learn more.

    Regards
    Kris

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •