-
Notifications
You must be signed in to change notification settings - Fork 1.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
Migration Guide: Discuss life cycle differences between LB3 and LB4 #3935
Comments
@bajtos , could you please add the acceptance criteria so that the team can estimate? Thanks. |
Discussion with @hacksparrow:
|
@hacksparrow, let me assign it to you for now, because you indicated that you'll be looking into the scope of this task. Thanks. |
https://loopback.io/doc/en/lb4/Understanding-the-differences.html already contains the broad differences between LB3 and LB4. "Operation hooks(interceptors in lb4)/remote hooks and their equivalents in LB4" is covered by "How to migrate boot scripts #3957 might be related" is covered by https://loopback.io/doc/en/lb4/migration-boot-scripts.html. "Datasource interceptor in lb4" is covered by https://loopback.io/doc/en/lb4/Interceptor-generator.html. For the remainder, I am suggesting to create the following pages under the Migration Guide.
Let's create three new tasks, with the sub points as the acceptance criteria. |
+1 in breaking down into smaller tasks or at least PRs. I'm good with your updated acceptance criteria. @aharbis, feel free to chime in if there's particular topic you want to cover. Not sure how we want to organize the docs, we do have an old issue about documenting the request/response cycle: #1833. |
I am fine with breaking this down into smaller tasks, that way we can better track progress and perhaps even spread the work.
That's a good plan 👍 I think it's important to cover application life-cycle and especially the boot process too. In LB3, the boot process works roughly as follows:
There are few more artifacts loaded by loopback-boot, e.g. middleware, I am not sure where exactly are they placed in the boot sequence. In LB4, the boot process works differently. Models are define via TS files (there is no boot step for that), middleware is not supported at LB level yet (it's mounted on the top-level Express app), boot scripts are implemented as lifecycle observers that are invoked outside of the boot process, etc. |
Ok then, another task on booting.
|
FYI - there's a GH issue for documenting application life cycle: #3384. |
I am good with splitting this up into tasks, and I agree that these four will cover the large majority of the gaps I was hoping to see filled:
I am happy to assist in contributing, but my expertise at this point is mostly on the LB3 side. I've yet to do many deep-dives into the inner workings of LB4. |
#3384 would be a more detailed doc too. The content in the Migration Guide would not be as detailed. |
Closing as done. Thanks @hacksparrow! |
Suggestion
This is a spin-off from a discussion on PR #3922.
The purpose of this issue is to discuss the life cycle differences between LB3 and LB4, with a primary goal of identifying pain-points during migration in regards to this topic.
Use Cases
Some initial topics or points of interest:
Since it's life cycle, this should be a high level view
Examples
Acceptance criteria
TBD - will be filled by the team.
The text was updated successfully, but these errors were encountered: