Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

Java Application Server Question

  • 16-10-2012 10:34am
    #1
    Registered Users, Registered Users 2 Posts: 1,280 ✭✭✭


    I am looking for some advice on a Java application I have started development on. The application essentially gathers specific football market price information from Betfair and stores this to a SQL database. At present I have this coded as a pure Java application which requires manual intervention. I have started to refactor it to become more automated, whereby I collect upcoming fixture information for the next 7 days, and schedule tasks to collect data automatically just before kick-off.

    What I am not sure of, is how/where best to run such an application - ie. which is required to be running at all times and have internet connectivity (without simply ensuring my home system is always on...). I have never done any Servlet development or other application server type development, and I'm wondering what would be the best fit for this. My impression was that Servlets are for more light-weight applications with short lifecycles but I could be wrong?

    Could anyone offer any advice on what might be a good fit to run an application such as this?


Comments

  • Registered Users, Registered Users 2 Posts: 3 xor


    Hi,

    you could convert your application to have a web-front end. This would involve re-writing the front end of your application as a web application using a framework such as Spring MVC or struts in a container such as Apache Tomcat. You could use something like JBoss Application server, but that might be a little overkill.

    Within your container you could use a java scheduling framework (like Quartz) to kick off your jobs at certain intervals. Quartz basically will call your java class at specified times.

    Where to host ?
    You could see if you could get a Virtual Private Server (basically a Virtual Machine) where you control the OS. They can start off for as little as 13 Euro per/month and are constantly connected to the internet. If your application has got a front end eg myprices.com then that will be available 24x7 as well.
    As it is your VM you will be free to install what you want , and you will have full control.

    Hope that helps a little.

    xor.


  • Registered Users, Registered Users 2 Posts: 1,280 ✭✭✭jArgHA


    @xor

    thanks for the tips, I'll do a bit more research on some of the technologies you mentioned to try make a decision which way to go. thanks again


  • Registered Users, Registered Users 2 Posts: 2,021 ✭✭✭ChRoMe


    xor wrote: »
    Hi,

    you could convert your application to have a web-front end. This would involve re-writing the front end of your application as a web application using a framework such as Spring MVC or struts in a container such as Apache Tomcat. You could use something like JBoss Application server, but that might be a little overkill.

    Within your container you could use a java scheduling framework (like Quartz) to kick off your jobs at certain intervals. Quartz basically will call your java class at specified times.

    Where to host ?
    You could see if you could get a Virtual Private Server (basically a Virtual Machine) where you control the OS. They can start off for as little as 13 Euro per/month and are constantly connected to the internet. If your application has got a front end eg myprices.com then that will be available 24x7 as well.
    As it is your VM you will be free to install what you want , and you will have full control.

    Hope that helps a little.

    xor.

    Thats a very complex solution. I'd suggest simply moving the application on to a Linux server and scheduling a cron job to execute the class at the desired time. No changes required to the java code and about ten minute setup time for the cron job.


  • Registered Users, Registered Users 2 Posts: 3 xor


    @ChRoMe
    Thats true, cron indeed would be good enough to schedule a call to the java program to pull down the stats from the relevant site, and would require no change.

    I just mentioned the part about SpringMVC as I thought the poster might need a front end to show some of this information.

    The part about the VPS is still needed, if the poster requires a constant internet connection.

    -xor


  • Registered Users, Registered Users 2 Posts: 586 ✭✭✭Aswerty


    No need to pay for a VPS initially since something like a free amazon ec2 micro instance should service your needs until you want to scale it.


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 2,021 ✭✭✭ChRoMe


    Aswerty wrote: »
    No need to pay for a VPS initially since something like a free amazon ec2 micro instance should service your needs until you want to scale it.

    This is an excellent suggestion, however the AWS console can be confusing, so be careful to pick the free micro instance otherwise you risk running up a big bill.


Advertisement