GithubHelp home page GithubHelp logo

Comments (10)

leighmcculloch avatar leighmcculloch commented on August 16, 2024 1

@sreuland Are you able to open a PR or share a diff of what would change in the quickstart image to use this different setup you were proposing? I suspect when I tested it I was not using the configuration you proposed.

from quickstart.

leighmcculloch avatar leighmcculloch commented on August 16, 2024 1

Ok, I got similar results to what I mentioned the first time I tested this (#490 (comment)):

Running without bucket list change:
Screenshot 2023-10-02 at 4 13 37 PM

Running with bucket list change:
Screenshot 2023-10-02 at 4 20 18 PM

The differences appear to be:

  • CPU usage is more choppy and generally a bit higher when bucket list is enabled.
  • Memory usage is a tiny bit lower when using the bucket list.

from quickstart.

leighmcculloch avatar leighmcculloch commented on August 16, 2024

@sreuland I gave this a go by enabling bucketlistdb on Horizon's captive core in the quickstart image. CPU usage was higher by ~5%. It's unclear to me if this is a better outcome as I couldn't see any other measure of improvement. There's a few resources we could measure impact on, but increased CPU seems pretty bad for devices that run on batteries like laptops.

What sort of performance improvements should we see on captive-core?

Does captive-core use on disk db? I thought it'd be in memory anyway?

Could you share some examples of the performance improvement you see?

from quickstart.

sreuland avatar sreuland commented on August 16, 2024

Hello @leighmcculloch ,

What sort of performance improvements should we see on captive-core?

when the captive core db is located on disk, which is done in quickstart by default for horizon, the savings are in less round-trips to the db from core process, as the bucklist acts like a read cache first, it was enabled on horizon cc config by default on horizon/4733 whenever 'use disk' is also enabled via CAPTIVE_CORE_USE_DB=true which is the default horizon prefers to use for captive core config rather than 'in memory', horizon/4733 went in as of release horizon 2.24.0

Does captive-core use on disk db? I thought it'd be in memory anyway?

yes, for horizon cc in quickstart, it runs on disk mode,

Could you share some examples of the performance improvement you see?

@urvisavla , has actually done some recent horizon benchmarking for docs updates which included cc on disk and bucketlistdb which may provide more data. the findings are posted here - stellar/go#4960.

from quickstart.

sreuland avatar sreuland commented on August 16, 2024

@leighmcculloch ,

#504

i'm trying out two runs locally using --pubnet to observe, one with current quickstart:testing from dockerhub which has no bucketlist enabled, and the other built with this config, will watch activity monitor and see if any spikes on cpu/ram

horizon attempts to enable bucketlist by default, but it does so based on core's version string, looking for a semver of 19.6 or above, and since horizon built from source on quickstart image, I think it's not getting this automatically, so would have to add the enablement directly in the core .cfg

from quickstart.

leighmcculloch avatar leighmcculloch commented on August 16, 2024

I gave this a whirl using testnet, which I think is more representative of a developers use of quickstart. Pubnet is more data than a user is likely to use. The difference between the two doesn't seem that meaningful. Here's the resource usage of the docker container:

Without bucket list:
Screenshot 2023-10-02 at 1 58 36 PM

With bucket list:
Screenshot 2023-10-02 at 2 04 16 PM

The only differences I see from this run is that:

  • the bucket list resulted in more disk read/writes
  • the bucket list resulted in less cpu usage

Seems fine to move ahead with this change then.

from quickstart.

sreuland avatar sreuland commented on August 16, 2024

ok, when you run quickstart are you including --enable-horizon-captive-core, I realized that by default, and w/o including that flag, quickstart will launch horizon ingestion with --stellar-core-db-url which skips captive core. maybe in tandem to adding bucketlist to captive configs in quickstart, we take the same time to just remove --enable-horizon-captive-core so that horizon always uses captive core, and avoid confusion, i hacked it out in the sample pr - 681cc5d

docker run --rm -it     -p "8000:8000"     --name stellar     stellar/quickstart:testing   --pubnet --enable-horizon-captive-core

from quickstart.

leighmcculloch avatar leighmcculloch commented on August 16, 2024

Ah, I missed that. Thanks. When we merge #498 then this won't be such an easy mistake to make. I'll rerun and see what it is like on my system with it enabled.

from quickstart.

sreuland avatar sreuland commented on August 16, 2024

cool, #498 looks good, maybe can just add the bucketlist enablement in there as it's closely related to captive core anyways? - ac9088a

I ran with --testnet --enable-horizon-captive-core and bucketlistdb enabled and disabled, nothing spiked in resources on either, running with --pubnet and bucketlistdb, it did elevate on CPU to max and stayed there when it got to applying:
stellar-core: Catching up; Catching up to ledger 48382143: Applying buckets 0%. Currently on level 10, I need to try it with no bucketlistdb to see if any different.

from quickstart.

github-actions avatar github-actions commented on August 16, 2024

This issue is stale because it has been open for 30 days with no activity. It will be closed in 30 days unless the stale label is removed.

from quickstart.

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.