Skip to content
Mike Karabushin edited this page Feb 12, 2015 · 5 revisions

When service ids expire in GTFS, the update is necessary to provide users with non-interrupted service for onebusaway applications. This page describes process of manually updating GTFS bundle for onebusaway applications.

Basic Scenario

For the basic case lets assume setup with single machine running application server with onebusaway-transit-data-federation-webapp and data bundle at C:\OneBusAway\bundle. This is reasonable setup for doing proof of concept with onebusaway. However, it does not take into consideration data validation and testing, or server downtime.

  1. Compile GTFS using FederatedTransitDataBundleCreatorMain.java in onebusaway-transit-data-federation-builder
  2. Stop application server
  3. Delete contents of C:\OneBusAway\bundle
  4. Copy newly compiled data bundle to C:\OneBusAway\bundle
  5. Start application server
  6. Monitor onebusaway-transit-data-federation-webapp log to make sure trip planner graph initialized successfully

More Advanced Scenario

For this case lets assume QA and PROD environments with identical setup having two machines each running application server with onebusaway-transit-data-federation-webapp and data bundle at C:\OneBusAway\bundle. For scalability and high availability lets assume we are using load balancer. Provided there is an existing and new GTFS that need to be combined.

For QA

  1. Merge existing GTFS with new-one
  2. Run FeedValidation tools and investigate reported issues
  3. Compile GTFS using FederatedTransitDataBundleCreatorMain.java in onebusaway-transit-data-federation-builder
  4. Take server #1 out of rotation in load balancer
  5. Update server #1 using same procedure as in Basic Setup
  6. Bring server #1 into load balancer rotation, take server #2 out
  7. Update server #2 using same procedure as in Basic Setup
  8. Bring server #2 into load balancer rotation

At this point QA is running merged GTFS bundle and is available for testing through REST API and / or user-facing applications.

For PROD

  1. Use the same process as for QA minus GTFS merge, validation, and compile. Instead copy tested bundle from QA.

As an alternative to start / stopping / rotating application servers "hot swapping" features may be used as they are in OBA NYC in onebusaway-application-modules.