Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 5992579
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T23:33:08+00:00 2026-05-22T23:33:08+00:00

I am writing a Ruby on Rails(3) application that relies on an xml feed

  • 0

I am writing a Ruby on Rails(3) application that relies on an xml feed that is updated ~30 seconds. Should I be parsing the xml data on my server with some sort of worker? If this is the case, will the server be able to respond to the client fast enough to stay ‘real-time’. I was thinking that it could be done with javascript but I’m not sure.

Edit:
Each update will be around 70kb and the source of the xml is able to handle a ton of connections.

No, this information is not going to be saved to the database. The user will have read-only access to the xml data.

Would it be possible to directly connect to the xml server with javascript on the clientside?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T23:33:09+00:00Added an answer on May 22, 2026 at 11:33 pm

    There are 3 realistic ways to approach this. I’m not a ruby guy, but none of these methods are ruby specific, either.

    • Refresh the page itself periodically to grab the latest feed. This is the old way of doing it, and though reliable, not a very good user experience.
    • Grab the new data periodically via AJAX and append it to the web page UI elements as necessary. This is probably your best bet in a high volume scenario, as it doesn’t retain any active connections to the server and doesn’t refresh the entire page. It also suffers from the same downside as option 1 though, which is that the updates are not real-time.
    • If you have a small enough audience or enough servers to split the load, you could take a comet approach. Essentially, each request to the page opens another long-running request in an invisible iframe. The output of the thread serving this request is a series of small, real-time updates in the form of javascript that triggers the UI elements to be updated. You then have to develop the process on the server that parses the input in real-time and notifies each active connection of the new data.

    Summary: Use a COMET type setup if you absolutely need real-time data access and/or your target audience is small enough to handle the load. Otherwise, use periodic AJAX updates.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm writing a Rails application that serves files stored on a remote server to
I'm currently writing an application in ruby on rails that uses AWS. I see
I am writing some unit tests for my Ruby on Rails application. I would
I'm writing a non-Rails ruby application (gasp!) and would like to be able to
Background: I'm writing a 'standard' (nothing special) web application in Ruby (not Rails) and
I am writing some Ruby code, not Rails, and I need to handle something
I'm writing a ruby program that executes some external command-line utilities. How could I
Im writing a ruby application that can post comments on behalf of the user
I am writing a web based application using Ruby on Rails. In one of
Does Webrat require that the web application be written in Ruby/Rails? I'd like to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.