Should we rename this package

pimlie
593
pimlie
commented a year ago

@Atinux @pi0

When I created this package I used the name cluster as I thought it didnt matter much as it would be a temporary package anyway. That would leave the option open for you to create a package with similar functionality but with a better name. Now that you accepted this package to the nuxt-community, could/should we maybe rename it to e.g. a more suitable nuxt-multi-generate or nuxt-generator-workers name? (better suggestions are welcome)

Also I implemented a cleaner and extensible producer/consumer design in my next branch. I am not sure yet if using cluster is the best in the long run, eg using process/child_process would be 'cleaner'.
Besides that I am thinking about creating a nuxt-generate-daemon that just runs all the time and will poll every interval the routes api endpoint to check for new routes/files to (re)generate. So instead of running this package in a crontab. As I will probably need different type of workers for that I am not sure yet cluster will be sufficient for that. With the new implementation we should be able to easily extend and implement process/subprocess if needed.

So maybe it would be an idea to remove the cluster part from this package name now the impact of that would be still small as there are not many users yet?

0
pimlie
593
pimlie
commented a year ago

@Atinux
fyi, after careful consideration I changed my mind and dont think we should rename this package ๐Ÿ‘บ

Using child_process directly will not give any major benefits above using the cluster api. And although it maybe feels/sounds a bit wrong to use cluster (at least to me) as thats primarly focussed on networking, there is nothing wrong with using it anyway: https://github.com/nodejs/help/issues/970

Also the name nuxt-generate-workers might be interpreted as that the package should be used next to another package (that provides the master) so lets keep it as it is

0
Atinux
21.0k
Atinux
commented a year ago

Hi @pimlie

I am fine renaming the package to nuxt-generate-workers and also for your idea of nuxt-generate-daemon :)

0
pimlie
593
pimlie
commented a year ago

@Atinux
fyi, after careful consideration I changed my mind and dont think we should rename this package ๐Ÿ‘บ

Using child_process directly will not give any major benefits above using the cluster api. And although it maybe feels/sounds a bit wrong to use cluster (at least to me) as thats primarly focussed on networking, there is nothing wrong with using it anyway: https://github.com/nodejs/help/issues/970

Also the name nuxt-generate-workers might be interpreted as that the package should be used next to another package (that provides the master) so lets keep it as it is

0
Informations
Question โ€ข Resolved
#c1 - Created a year ago