Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Elfeed is too slow when when there are a lot of rss list #317

Open
testinggithub1222 opened this issue May 2, 2019 · 10 comments
Open

Elfeed is too slow when when there are a lot of rss list #317

testinggithub1222 opened this issue May 2, 2019 · 10 comments

Comments

@testinggithub1222
Copy link

I have been using elfeed for a while now and build up like 30 to 50 rss list. Whenever I call elfeed-update to update everything, it takes quite a long time and hang emacs during the time. It might be 20mn, i am not sure. It consumes 100% of cpu and 54% of my ram which should be 4gb of 8gb of ram and garbage collection always collect. So, my question is, is there a way to make this run faster without interruption or hang emacs? Is that parsing xml consume that much cpu and took so long period of time? Isn't there async process?

@skeeto
Copy link
Owner

skeeto commented May 2, 2019 via email

@testinggithub1222
Copy link
Author

testinggithub1222 commented May 3, 2019

@skeeto, I have check elfeed-use-curl variable and it return true and it's already byte-compile as i seen .elc file there in my elfeed package dir.

Last night i have tried it again on my another more power computer and give gc-cons-threshold 8gb of ram as i got 16gb there and yes it took all the 8gb with 100% cpu again.

Also have Elfeed fetch them one at a time to see which one causes the problem

I will tried them. I doubt if reddit feed is the cause as i got many of them.

@testinggithub1222
Copy link
Author

@skeeto, I have set my feed list to empty as below:

(setq elfeed-feeds
        '())

and then tried to call elfeed-update to see the cpu time but it still took 89% of cpu again. I doubt this might be because i have too many feeds (when calling elfeed). I got 6004 list of feed there listing from 2019-05-02 to 2018-12-16

@skeeto
Copy link
Owner

skeeto commented May 3, 2019 via email

@testinggithub1222
Copy link
Author

I have tried delete ~/.elfeed folder in the purpose of testing this. After deleted this folder, elfeed is empty so then i tried to call elfeed-update to update my feed. But before that, I have already set filtering only show feed in the last 3 months. So, during the elfeed-update at the first time, everything seem smooth but after 1000 record was fetched, thing start to slow down. It took a while until reach 2000 record and it stuck there for so long but no more record is added beyond this. I doubt if it still fetch more data but only show the last 3 months of record.

If you don't mind, here is my configuration:

(use-package elfeed
  :ensure t
  :config
  (setq 
elfeed-search-filter "@3-months-ago "
elfeed-feeds
'("https://www.reddit.com/r/programming/.rss" "https://www.xda-developers.com/feed/" "https://www.reddit.com/r/science/.rss" "https://www.reddit.com/r/kurzgesagt/.rss" "https://www.reddit.com/r/worldnews/.rss" "https://www.reddit.com/r/todayilearned/.rss" "https://www.reddit.com/r/LifeProTips/.rss" "https://www.reddit.com/r/explainlikeimfive/.rss" "https://www.reddit.com/r/DIY/.rss" "https://www.reddit.com/r/technology/.rss" "https://www.reddit.com/r/Android/.rss" "https://www.reddit.com/r/linux/.rss" "https://www.reddit.com/r/archlinux/.rss" "https://www.reddit.com/r/gadgets/.rss" "https://www.reddit.com/r/IAmA/.rss" "https://www.reddit.com/r/Futurology/.rss" "https://www.reddit.com/r/AskMen/.rss" "https://www.reddit.com/r/AskWomen/.rss" "https://www.reddit.com/r/vim/.rss" "https://www.reddit.com/r/YouShouldKnow/.rss" "https://www.reddit.com/r/learnprogramming/.rss" "https://www.reddit.com/r/investing/.rss" "https://www.reddit.com/r/hacking/.rss" "https://www.reddit.com/r/javascript/.rss" "https://www.reddit.com/r/java/.rss" "https://www.reddit.com/r/Piracy/.rss" "https://www.reddit.com/r/homeautomation/.rss" "https://www.reddit.com/r/quotes/.rss" "https://www.reddit.com/r/androidapps/.rss" "https://www.reddit.com/r/HowToHack/.rss" "https://www.reddit.com/r/arduino/.rss" "https://www.reddit.com/r/startup/.rss" "https://www.reddit.com/r/Entrepreneur/.rss" "https://lifehacker.com/tag/linux/rss" )))

@skeeto
Copy link
Owner

skeeto commented May 10, 2019 via email

@testinggithub1222
Copy link
Author

Sorry for late reply i was so busy in this month.
By the way, I am not sure what or how could i do your given idea. I have read it many time but still not sure about it. Should i download this Makefile from elfeed repo and then execute your given script:

$ make clean
$ HOME=. make virtual ARGS='-l tmp.el'

And what does it mean by? How it is really work?

That provides a clean, empty, isolated, temporary test environment. The
special "virtual" target in the Makefile imports a copy of your real
database by default.

And especially, this last word, how does it working and what should i do with it?:

so the HOME=. part stops this from happening

@skeeto
Copy link
Owner

skeeto commented May 16, 2019 via email

@testinggithub1222
Copy link
Author

I have tried to reduce to "@15-days-ago +unread" and feed show around a thousand. Around this number, it seem works good.

@mssdvd
Copy link

mssdvd commented Dec 5, 2021

@testinggithub1222 are you using Flycheck? If so, #448 could fix your problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants