-
Notifications
You must be signed in to change notification settings - Fork 1k
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
fix(render): reduce memory and handle server file #10055
Conversation
path.join(rwjsPaths.base, 'node_modules/.bin/prisma'), | ||
['migrate', 'deploy', '--schema', `"${rwjsPaths.api.dbSchema}"`], | ||
'node_modules/.bin/prisma', | ||
['migrate', 'deploy', '--schema', rwjsPaths.api.dbSchema], |
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.
Did this (the rwjsPaths.api.dbSchema
) need to be explicitly quoted to support things like spaces in paths? I can't remember if execa handles that for you or not - I should look it up.
not sure but that seems likely. if we add back the quotes, we have to add back the shell: true config to execa. it just wasn’t working with those extra quotes and without the shell option. not sure exactly why again. but adding back shell probably doesn’t incur that much memory |
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.
Unless I'm mistaken this was tested with a yarn patch approach and worked. One minor comment but looks good.
I feel like escaping the args passed in is something execa should be doing so I would vote not to undo your change here. Unless I can find some execa docs stating otherwise |
@Josh-Walker-GM I couldn't be sure if the quotes really mattered since I didn't test a scenario for it so reverting on that for now which means adding |
Made some improvements to the render deploy command while debugging an issue with realtime on their platform (see https://community.redwoodjs.com/t/redwood-realtime-on-render-com/5796 for the original issue). Note that while this PR fixes the original issue (subscriptions is not an allowed operation), realtime itself still doesn't work as expected. Currently trying to isolate render if it is specific to them. But these are valid fixes in the meantime: - should improve the memory usage problem by 1) requiring cli-data-migrate to be a devDependency prior to deploy and 2) not importing from the cli's lib which brings in the whole world 3) not using execa's shell option which isn't recommended - render will now use the server file if it's there
Made some improvements to the render deploy command while debugging an issue with realtime on their platform (see https://community.redwoodjs.com/t/redwood-realtime-on-render-com/5796 for the original issue). Note that while this PR fixes the original issue (subscriptions is not an allowed operation), realtime itself still doesn't work as expected. Currently trying to isolate render if it is specific to them. But these are valid fixes in the meantime: - should improve the memory usage problem by 1) requiring cli-data-migrate to be a devDependency prior to deploy and 2) not importing from the cli's lib which brings in the whole world 3) not using execa's shell option which isn't recommended - render will now use the server file if it's there
Similar to #10055, updates the setup command for Coherence to detect the server file. This deployed successfully in this commit on deploy target CI here: redwoodjs/deploy-target-ci@4e5883e.
Similar to #10055, updates the setup command for Coherence to detect the server file. This deployed successfully in this commit on deploy target CI here: redwoodjs/deploy-target-ci@4e5883e.
Similar to #10055, updates the setup command for Coherence to detect the server file. This deployed successfully in this commit on deploy target CI here: redwoodjs/deploy-target-ci@4e5883e.
Similar to #10055, updates the setup command for Coherence to detect the server file. This deployed successfully in this commit on deploy target CI here: redwoodjs/deploy-target-ci@4e5883e.
Similar to #10055, updates the setup command for Coherence to detect the server file. This deployed successfully in this commit on deploy target CI here: redwoodjs/deploy-target-ci@4e5883e.
Similar to #10055, updates the setup command for Coherence to detect the server file. This deployed successfully in this commit on deploy target CI here: redwoodjs/deploy-target-ci@4e5883e.
At first this PR was similar to #10055 but for Flightcontrol. But in the process of testing that and updating deploy target CI, I noticed a few other things were off: - coherence logic for the server file was flipped. fixed here - in general, a few duplicate ways of checking for the server file. tried to dedupe them the best i could without making massive changes - stylistic change to render - the flightcontrol setup wasn't handing corepack Test as much as I could locally. Going to get this one into next so I can test in deploy target CI.
At first this PR was similar to #10055 but for Flightcontrol. But in the process of testing that and updating deploy target CI, I noticed a few other things were off: - coherence logic for the server file was flipped. fixed here - in general, a few duplicate ways of checking for the server file. tried to dedupe them the best i could without making massive changes - stylistic change to render - the flightcontrol setup wasn't handing corepack Test as much as I could locally. Going to get this one into next so I can test in deploy target CI.
At first this PR was similar to #10055 but for Flightcontrol. But in the process of testing that and updating deploy target CI, I noticed a few other things were off: - coherence logic for the server file was flipped. fixed here - in general, a few duplicate ways of checking for the server file. tried to dedupe them the best i could without making massive changes - stylistic change to render - the flightcontrol setup wasn't handing corepack Test as much as I could locally. Going to get this one into next so I can test in deploy target CI.
Made some improvements to the render deploy command while debugging an issue with realtime on their platform (see https://community.redwoodjs.com/t/redwood-realtime-on-render-com/5796 for the original issue). Note that while this PR fixes the original issue (subscriptions is not an allowed operation), realtime itself still doesn't work as expected. Currently trying to isolate render if it is specific to them. But these are valid fixes in the meantime: