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

Large projects causing memory error? #4

Open
ryantuck opened this issue Dec 18, 2018 · 6 comments
Open

Large projects causing memory error? #4

ryantuck opened this issue Dec 18, 2018 · 6 comments

Comments

@ryantuck
Copy link

Hey @fabio-looker - I think we uncovered a bug whereby lookml-parser fails on large (~800 files) projects: https://github.com/WarbyParker/lookmlint/issues/50#issuecomment-447420100

Didn't know if you had seen that before, or had any immediate ideas on how one would go about fixing that. I'll poke around in the code myself to see if anything obvious jumps out, but javascript isn't quite my strength. I've got a handful of ideas for working around it for lookmlint in the meantime, but wanted to flag this as an issue 👍

@fabio-looker
Copy link
Owner

Thanks for the report! I've run it on pretty large projects without issue, but I'll have to dig it up and try it again.

That said, it is true that all the files are loaded into memory at once and at some point it will break. Shouldn't be that hard to refactor it to default to in-memory but have some sort of file-system fallback mode if there are too many objects in the project

@kingfink
Copy link

Thanks @fabio-looker and @ryantuck ! If you need an example happy to provide...or if I have some free time in the near future I'll try poking around

@fabio-looker
Copy link
Owner

Wouldn't hurt to have a realistic project for repro'ing. Can you send it to [email protected] ?

@kingfink
Copy link

kingfink commented Jan 3, 2019

Good news! I was able to get this working 🙂

I needed to tweak my node options: export NODE_OPTIONS=--max_old_space_size=4096

@fabio-looker
Copy link
Owner

Glad to hear it. I'm going to keep the ticket open as I think this could be addressed anyway

@fabio-looker
Copy link
Owner

While this issue is not fundamentally resolved, 5.0.0 should reduce memory usage due to less repetitive representations being built out in-memory

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