Skip to content

Larger Files #17118

Answered by martinpitt
elcarn23 asked this question in Q&A
Mar 10, 2022 · 1 comments · 5 replies
Discussion options

You must be logged in to vote

Can you please be a little more specific what you are trying to do, and where? Is that some standard cockpit page, or a custom one of yours? cockpit.file(...).read() should work fine with 20 MB, provided that you set an appropriate max_read_size (the default is 16 MiB, see docs).

But indeed things get increasingly inefficient if you download that much data into JS and the page's working memory. At some point it's probably better to process the XML data on the server side, by running some program/script through cockpit.spawn().

Replies: 1 comment 5 replies

Comment options

You must be logged in to vote
5 replies
@elcarn23
Comment options

@elcarn23
Comment options

@elcarn23
Comment options

@martinpitt
Comment options

@martinpitt
Comment options

Answer selected by elcarn23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants