-
Notifications
You must be signed in to change notification settings - Fork 38
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
Remove usage of files #65
Conversation
e2312bd
to
8f3c76f
Compare
👍 This PR looks much valuable, it removes the unwanted function into much organic in-memory handling and storing information and writing to the storage.
📓 Update 14th June: I noticed that the zip is removed which will break the I will take another look tonight, and add more folks who will get affected by this in the current PRs. I feel under the hood it makes things much more non-convoluted. Hiya, @JunSun17 can you please eye-ball - seems a simpler approach, but in case you can think of anything which will be an issue please? 🙏 Thank you so much. FYI: cc: @davidkydd , @sophsoph321 , @SanyaKochhar |
2236e33
to
94080be
Compare
What's the motivation behind getting rid of the volume mount? I'm not sure about keeping everything in memory as some clusters already generate significant amounts of data, and additional collectors added in future may exacerbate this. This seems like a recipe for getting OOMKilled? |
@davidkydd I believe it's pretty much the same as before regarding memory as we were storing the command's outputs in a variable and reading content of files in one shot. I believe any command today could cause an OOM in a significant cluster and at least this PR reduces i/o on the disk. |
Ah yes thanks Arnaud! With a streaming solution planned for later this sounds like a great change, reducing disk io is a good immediate benefit too |
cool :) any help on the subject is more than welcome as I don't know for sure if it's doable. It will also depend on what the libraries can do. But I do hope we can find an elegant solution :) |
b4cbf31
to
8d1cf19
Compare
💡 For Honest appraisal of the situation between both tools, here are some quick thoughts:
Please let me know what you guys things and ideas? Happy to chat up as well. I could try and add zip back with rest of refactor from the fork? (If this sounds cool) that will make thi PR non-breaking and a win-win. Thanks heaps, |
8d1cf19
to
169f406
Compare
169f406
to
c4b9725
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Thank you so much for this change and contribution, especially adding back the *.zip
functionality with latest upgrade, I have tested locally with my local image tatsat/test-remove-useoffiles
looks good. +1 and approve.
Thank you for incorporating OSM
changes as well. Hierarchy looks much cleaner.
I will leave one final look with other folks and maintainers, if no replies we can go ahead in next few hours to merge it. Looks good to me. 🙏
cc: @JunSun17 an @davidkydd
This PR removes all uses of files so there is no need to mount a volume on the container. The starting point was to remove functions in utils.go:
WriteToFile
,CreateCollectorDir
,CreateDiagnosticDir
Notes:
map[string]string
, the key being the file name & the value the content of the file.collector
can no longerExport()
and anexporter
requires adataProducer
toExport()
)./creationDate/hostname/<collector/diagnoser>/filename
to/creationDate/hostname/filename