Hexo: deployments are slow

Created on 17 Sep 2017  Β·  15Comments  Β·  Source: hexojs/hexo

My blog 150+ article, which takes more than 10 minutes each deployment.
CPU has a high occupancy rate at deployment.
Are you the same?

commands that are used: hexo clean && hexo d -g

name | version
--- | ---
nodejs | v8.2
hexo | v3.3.9

#perfmatters

Most helpful comment

The issue is caused by the html-to-text packages, it converts every html files into plain text, then count words based upon that. I have created an issue on hexo-wordcount, hope they could come up some solutions. https://github.com/willin/hexo-wordcount/issues/10

All 15 comments

The situation is somewhat similar, but my blog seems to be somewhat faster. The situation is similar. My blog 230+ article , which takes 6 minutes each deployment.

It may be different depending on the your plugin and CPU.

Also , I think the reason why the CPU occupancy rate is high is because all articles are generated at the same time. If my imagination is correct, hexo may need to be fixed.

my environment

  • hexo v3.3.9
  • node.js v8.5
  • CPU: 3.33GHz x2
$ npm ls --depth 0
[email protected] hexo
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected] (git+https://github.com/tea3/hexo-deployer-netlify.git#68f533757cd63987dd656811456e69add25e1a3b)
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected] (git+https://github.com/tea3/hexo-generator-feed.git#6bf6f0fd5aefdca02e032cbe7581a214b881a658)
β”œβ”€β”€ [email protected] (git+https://github.com/tea3/hexo-generator-index.git#74d86309af930849b41f60db98894031e130fd24)
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected] (git+https://github.com/tea3/hexo-generator-search.git#d3f88cc2adabd43d429388c857d39f717ed2594e)
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected] (git+https://[email protected]/dotimpact/hexo-generator-single-page.git#fb983a67e04193f624cb8ffa95b2fab75ec95196)
β”œβ”€β”€ [email protected] (git+https://github.com/tea3/hexo-generator-tag.git#946b712a81c4cb78bea151738cdb8eff1b8a5697)
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected] (git+https://github.com/tea3/hexo-tag-flickr.git#a684dab69fcd44f5998049277075dd4d0b1ddae1)
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected] (git+https://github.com/tea3/hexo-tag-random-embed.git#52542faa9e6760e3b1c651cdf8441117cf241f28)
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected] (git+https://github.com/tea3/hexo-toc.git#7c9624c2d3fb7d13ce973cb8de4dc10ff865c089)
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
β”œβ”€β”€ [email protected]
└── [email protected]

@tea3

When deployed, opening other applications will take longer.

So, I have to wait until the deployment is complete before I do anything else.

My CPU i5-4300U 1.9GHz

I don't have that many articles. Is that okay to share your source codes?

@NoahDragon
My blog is written in Chinese.
Chinese character need more CPU ?

My blog: http://me.lizhooh.com/

@Lizhooh Not really. I just wonder if I could have your all the source files under your hexo folder to investigate the issue. Right now, we know there is a performance issue in hexo, but don't have enough data to test with. Because the performance may be caused by different aspects, some caused by high volume of posts, some are incorrect implementation of the theme. Need to have the source code to take a look.

@NoahDragon

Can I put my source codes through the mail to you, but you have to promise that it's for testing only.
If you agree, reply your email. Thank.

@Lizhooh thanks, you have my words, I will only use it for testing. You could send it to [email protected] .

@NoahDragon Already sent

Duplicate #2579.

@Lizhooh FYI. I could reproduce the issue, but don't have time to dig into.

@NoahDragon After I tried to remove hexo-wordcount, the build became faster.

@Lizhooh Thanks for the info. I take a look at the code on hexo-wordcount, it does cause the performance issue, and it doesn't provide the trace message.

I will close the issue for now. Please feel free to reopen it.

The issue is caused by the html-to-text packages, it converts every html files into plain text, then count words based upon that. I have created an issue on hexo-wordcount, hope they could come up some solutions. https://github.com/willin/hexo-wordcount/issues/10

get it.

hexo-symbols-count-time. No deps. Welcome.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

hgDendi picture hgDendi  Β·  3Comments

enterhuiche picture enterhuiche  Β·  3Comments

awulkan picture awulkan  Β·  3Comments

demurgos picture demurgos  Β·  3Comments

19uni94 picture 19uni94  Β·  3Comments