Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

feature - fetching data from kansalaisaloite.fi #303

Open
wants to merge 1 commit into from

2 participants

@blahutka
# fetch from details according range ids 1..50
rake kansalaisaloite:fetch_range

# fetch new from index page
rake kansalaisaloite:fetch_index

# run with cron
rake kansalaisaloite:cron:enable
rake kansalaisaloite:cron:disable
@darkbart

fail PR

Whenever have no write access to heroku dynos cron_tab

To controll cron tasks on heroku use add-ons for it :/

All of them use extra dyno for processing

if we didn't plan extra dyno for background processing

the only way to do it without extra dyno, only additional admin_panel controller actions

The "all_in_one" field in ideas table bad smell. We don't need to keep twice attributes for each external idea we need extra attributs but not packed in one field :/

2 extra actions in admin_panel + additional small table of fetched_ideas)

fetch_ideas_from(kansalaisaloite.fi) button nr 1 it only fetch the ideas from external service (for speedup)
compare_fetched_ideas button nr 2 action which compare/check ideas from fetched_ideas table for duplicates and save/update existed real ideas

cons... it needs human activity to work

advantages... it works without extra dyno

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.