Detta inlägg är gammalt och kan innehålla inaktuell information.

Saving GTFS Realtime data


I am interested in retrieving and storing the messages from the GTFS and GTFS Realtime feeds which, at first glance, looks trivial to implement on my own. But I am, anyway, wondering if there are any APIs that I can use for that purpose or any recommendations how this is to be done.
I have found OneBusAway project ( and the onebusaway-gtfs-realtime-exporter library and wonder if anyone has tried it already.

Any info in this direction would be really appreaciated.

Thanks and all the best



  • Hej Valentina!

    I don't have experience with the OneBusAway libraries, but you can find more information on their Wiki page:

    During our own experiments with storing realtime data, we used a cron-job to run a simple shell script. This shell script ran every minute and stored the protobuf files in an archive file. This archive file can reach up to 80% compression. After every day, the files can be decompressed and compressed again into a solid archive using LZMA2 compression. This way the data becomes 99% compressed, and 1TB turns into 10-20GB.

    I hope this helps, don't hesitate to ask us in case you have any other questions.
    I noticed you are part of RI.SE. Do you know about the Ko.Da project? If you are part of it, we (Samtrafiken/Trafiklab) can contact you to arrange a meeting to discuss how all data can be saved. If you aren't part of this project, you might be able to re-use the data they (will) store.

    Team Trafiklab
  • Hej Bert,

    Thanks for the quick reply!

    Yes, I am part of the KoDa project. Let's get in touch and discuss that.

    Thanks & all the best


Kommentera eller skriv ett nytt inlägg

Ditt namn och inlägg kan ses av alla. Din e-post visas aldrig publikt.