Improve 'start-airflow' experience for users and ui developers#26341
Merged
potiuk merged 1 commit intoapache:mainfrom Sep 16, 2022
Merged
Improve 'start-airflow' experience for users and ui developers#26341potiuk merged 1 commit intoapache:mainfrom
potiuk merged 1 commit intoapache:mainfrom
Conversation
Member
Author
|
cc: @bbovenzi @pierrejeambrun - apart of improving |
potiuk
commented
Sep 12, 2022
potiuk
commented
Sep 12, 2022
b30d534 to
b40c72b
Compare
Member
Author
|
Looking forward to merging this one :). Should be good improvement for many users. |
Member
Author
|
(rebased it to include PEP-563) |
3efcc1a to
8cf3bcf
Compare
pierrejeambrun
approved these changes
Sep 14, 2022
jedcunningham
approved these changes
Sep 14, 2022
36083dc to
ac9640c
Compare
Merged
ac9640c to
9a7ec38
Compare
josh-fell
approved these changes
Sep 15, 2022
Contributor
josh-fell
left a comment
There was a problem hiding this comment.
Only a small comment. This will definitely be an improvement!
potiuk
commented
Sep 15, 2022
246827c to
4ff8b1c
Compare
Since we moved the "compile-www-assets" to host (and deferred it to pre-commit to prepare and manage appropriate node virtualenv), starting airflow via `start-airflow` command had become slower, adding quite a few seconds always when you run the command. Also it was a bit convoluted to start dev mode - you had to stop and restart webserver and run dev asset recompilation. This change improves the `start-airflow` experience in several ways: * the compile-www-assets pre-commit in start airflow runs in a background, daemon thread. This allows start-airflow command to continue even if asset compilation takes quite some time. By the time webserver starts and database initializes and the user launches browser it should be completed anyway. * the assets are not recompiled if none of the "www" files changed which for most people who run airflow without modifying the UI part will make it really fast to re-run start-airflow * we have a new flag --skip-assets-compilation added that will skip asset compilation even if the www files were modified * finally we have a new "--dev-mode" when starting airflow that will run the "dev" mode of assets compilation. And thanks to the background, daemon thread, assets compilation in dev mode will continue running as long as the `start-airflow` command is running All this should naturally plug in the exisitng start-airflow usage and add new capabilities for those who develop UI (you can run dev mode now without manually restarting anything).
4ff8b1c to
0ad03c0
Compare
ephraimbuddy
pushed a commit
that referenced
this pull request
Nov 10, 2022
Since we moved the "compile-www-assets" to host (and deferred it to pre-commit to prepare and manage appropriate node virtualenv), starting airflow via `start-airflow` command had become slower, adding quite a few seconds always when you run the command. Also it was a bit convoluted to start dev mode - you had to stop and restart webserver and run dev asset recompilation. This change improves the `start-airflow` experience in several ways: * the compile-www-assets pre-commit in start airflow runs in a background, daemon thread. This allows start-airflow command to continue even if asset compilation takes quite some time. By the time webserver starts and database initializes and the user launches browser it should be completed anyway. * the assets are not recompiled if none of the "www" files changed which for most people who run airflow without modifying the UI part will make it really fast to re-run start-airflow * we have a new flag --skip-assets-compilation added that will skip asset compilation even if the www files were modified * finally we have a new "--dev-mode" when starting airflow that will run the "dev" mode of assets compilation. And thanks to the background, daemon thread, assets compilation in dev mode will continue running as long as the `start-airflow` command is running All this should naturally plug in the exisitng start-airflow usage and add new capabilities for those who develop UI (you can run dev mode now without manually restarting anything). (cherry picked from commit 7661f34)
ephraimbuddy
pushed a commit
that referenced
this pull request
Nov 10, 2022
Since we moved the "compile-www-assets" to host (and deferred it to pre-commit to prepare and manage appropriate node virtualenv), starting airflow via `start-airflow` command had become slower, adding quite a few seconds always when you run the command. Also it was a bit convoluted to start dev mode - you had to stop and restart webserver and run dev asset recompilation. This change improves the `start-airflow` experience in several ways: * the compile-www-assets pre-commit in start airflow runs in a background, daemon thread. This allows start-airflow command to continue even if asset compilation takes quite some time. By the time webserver starts and database initializes and the user launches browser it should be completed anyway. * the assets are not recompiled if none of the "www" files changed which for most people who run airflow without modifying the UI part will make it really fast to re-run start-airflow * we have a new flag --skip-assets-compilation added that will skip asset compilation even if the www files were modified * finally we have a new "--dev-mode" when starting airflow that will run the "dev" mode of assets compilation. And thanks to the background, daemon thread, assets compilation in dev mode will continue running as long as the `start-airflow` command is running All this should naturally plug in the exisitng start-airflow usage and add new capabilities for those who develop UI (you can run dev mode now without manually restarting anything). (cherry picked from commit 7661f34)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Since we moved the "compile-www-assets" to host (and deferred it to pre-commit to prepare and manage appropriate node virtualenv), starting airflow via
start-airflowcommand had become slower, adding quite a few seconds always when you run the command. Also it was a bit convoluted to start dev mode - you had to stop and restart webserver and run dev asset recompilation.This change improves the
start-airflowexperience in several ways:start-airflowcommand is runningAll this should naturally plug in the exisitng start-airflow usage and add new capabilities for those who develop UI (you can run dev mode now without manually restarting anything).
^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named
{pr_number}.significant.rstor{issue_number}.significant.rst, in newsfragments.