Created
March 31, 2017 12:11
-
-
Save knu/11756dd9695bfbfa6ddfbac5b5c62d81 to your computer and use it in GitHub Desktop.
Huginn scenario for detecting updates in BigQuery SQL Reference
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"schema_version": 1, | |
"name": "Detect updates in BigQuery SQL Reference", | |
"description": "No description provided", | |
"source_url": false, | |
"guid": "3d9024f5898a7183e278289832f0720a", | |
"tag_fg_color": "#ffffff", | |
"tag_bg_color": "#5bc0de", | |
"icon": "globe", | |
"exported_at": "2017-03-31T12:09:09Z", | |
"agents": [ | |
{ | |
"type": "Agents::WebsiteAgent", | |
"name": "BigQuery SQL Reference HTML timestamp checker", | |
"disabled": false, | |
"guid": "969e25cf6d0b3276882a61d61043e9e3", | |
"options": { | |
"expected_update_period_in_days": "2", | |
"url_from_event": "{{ url }}", | |
"type": "html", | |
"mode": "merge", | |
"extract": { | |
"updated_at": { | |
"css": "[itemprop='datePublished']", | |
"value": "@content" | |
}, | |
"title": { | |
"css": "h1", | |
"value": "normalize-space(.)" | |
} | |
} | |
}, | |
"schedule": "never", | |
"keep_events_for": 86400, | |
"propagate_immediately": true | |
}, | |
{ | |
"type": "Agents::EventFormattingAgent", | |
"name": "BigQuery SQL Reference updates", | |
"disabled": false, | |
"guid": "ca2ddd17bcae9380b565b09354b8377d", | |
"options": { | |
"instructions": { | |
"message": "BigQuery SQL Reference {{ updated_at }} ({{ title }})" | |
}, | |
"mode": "merge" | |
}, | |
"keep_events_for": 0, | |
"propagate_immediately": true | |
}, | |
{ | |
"type": "Agents::ChangeDetectorAgent", | |
"name": "BigQuery SQL Reference timestamp keeper", | |
"disabled": false, | |
"guid": "da679ce32a8c7fe8ab740687d12a13c8", | |
"options": { | |
"property": "{% if last_property == blank or updated_at > last_property %}{{ updated_at }}{% else %}{{ last_property }}{% endif %}", | |
"expected_update_period_in_days": "30" | |
}, | |
"keep_events_for": 0, | |
"propagate_immediately": true | |
}, | |
{ | |
"type": "Agents::WebsiteAgent", | |
"name": "BigQuery SQL Reference HTML lister", | |
"disabled": false, | |
"guid": "ef8815edb3b3041ce6d01f9476116a4e", | |
"options": { | |
"expected_update_period_in_days": "2", | |
"url": "https://cloud.google.com/bigquery/docs/reference/standard-sql/", | |
"type": "html", | |
"mode": "all", | |
"extract": { | |
"url": { | |
"css": "link[rel='canonical'], a[href^='https://cloud.google.com/bigquery/docs/reference/standard-sql/'][href$='.html']", | |
"value": "@href" | |
} | |
} | |
}, | |
"schedule": "every_12h", | |
"keep_events_for": 86400, | |
"propagate_immediately": false | |
} | |
], | |
"links": [ | |
{ | |
"source": 0, | |
"receiver": 2 | |
}, | |
{ | |
"source": 2, | |
"receiver": 1 | |
}, | |
{ | |
"source": 3, | |
"receiver": 0 | |
} | |
], | |
"control_links": [ | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment