Giter VIP home page Giter VIP logo

Comments (8)

berekuk avatar berekuk commented on June 13, 2024 1

Seems fine now (cronjob broke today on algolia step due to misconfiguration, sorry; but I see in logs that you've already fixed that).

from metaforecast.

NunoSempere avatar NunoSempere commented on June 13, 2024

Increasing dyno size is ok as a hotfix, yes.

from metaforecast.

berekuk avatar berekuk commented on June 13, 2024

After some investigating:

  • polymarket-fetch uses around 260MB if run by itself
  • there might be also be memory leaks from the previous steps, I'm not sure
  • Heroku limits are 512MB on Hobby/Free and on Standard 1X; that sounds quite limiting to me, considering that we might want to fetch huge JSON files for the backend
  • Heroku's Standard 2X with 1GB RAM is $50/month :( on DO 1GB droplet is just $6/month (and on Hetzner we can get 4GB RAM VPS for €5.83)

I'm running updates by hand on my machine for now (everything from 9=polymarket).

from metaforecast.

berekuk avatar berekuk commented on June 13, 2024

polymarket-fetch uses around 260MB if run by itself

This number is hard to bring down for now due to how platform fetchers are currently implemented (load all data in memory and then insert everything to the DB).

So I enabled pro dynos on heroku and changed the main cron job to use Standard-2X, that should be enough. It shouldn't be as bad as $50/month just for that, since Heroku charges only for a fraction of time the dyno runs, so might be around $10/month or so.

from metaforecast.

NunoSempere avatar NunoSempere commented on June 13, 2024

Received, seems ok for now.

from metaforecast.

NunoSempere avatar NunoSempere commented on June 13, 2024

I reworked the polymarket fetcher. It should be significantly less memory intensive now. In particular, we were fetching all markets (including resolved ones), which wasn't necessary. I've reverted the change and we are now using free dynos, but feel free to restore them.

from metaforecast.

berekuk avatar berekuk commented on June 13, 2024

Oh, great. Btw, are https://strapi-matic.poly.market/markets query parameters documented anywhere, or are you just reverse-engineering urls from https://polymarket.com/? I couldn't find anything useful on google.

from metaforecast.

NunoSempere avatar NunoSempere commented on June 13, 2024

Both. There is a devs channel on the polymarket Discord on which this is kinda-but-not-really documented. In this case, I did reverse engineer the parameters.

from metaforecast.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.