You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This directory contains the GCP serverless function that will update all the feed statuses according to their associated latest dataset service date range.
3
+
4
+
It will exclude Feeds with exisiting status 'deprecated' and 'development'
5
+
6
+
## Function Workflow
7
+
1.**HTTP Request Trigger**: The function is invoked through an HTTP request that includes identifiers for a dataset and feed.
8
+
2.**Dataset Query**: Retreives all feeds which have latest dataset with exisitng values for the service date range
9
+
3.**Feed Update Query**: Update the feed status based on the service date range values comparing vs current date
10
+
11
+
## Function Configuration
12
+
The function depends on several environment variables:
13
+
-`FEEDS_DATABASE_URL`: The database URL for connecting to the database containing GTFS datasets and related entities.
14
+
15
+
## Local Development
16
+
Follow standard practices for local development of GCP serverless functions. Refer to the main [README.md](../README.md) for general setup instructions for the development environment.
17
+
18
+
## Testing
19
+
To run it locally `./scripts/function-python-run.sh --function_name update_feed_status`
20
+
21
+
In postman or similar service, with a `POST` call `v1/update_feed_status`
0 commit comments