-
Notifications
You must be signed in to change notification settings - Fork 14
add sofaboot4 samples #28
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
Conversation
|
Warning Rate Limit Exceeded@lvjing2 has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 19 minutes and 53 seconds before requesting another review. How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. WalkthroughThe recent updates to the Changes
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configration File (
|
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.
Actionable comments posted: 61
Review Details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (24)
- sofaboot4-samples/Formatter.xml (1 hunks)
- sofaboot4-samples/HEADER (1 hunks)
- sofaboot4-samples/dynamic-stock/README-zh_CN.md (1 hunks)
- sofaboot4-samples/dynamic-stock/README.md (1 hunks)
- sofaboot4-samples/dynamic-stock/base/Dockerfile (1 hunks)
- sofaboot4-samples/dynamic-stock/base/bootstrap/pom.xml (1 hunks)
- sofaboot4-samples/dynamic-stock/base/bootstrap/src/main/java/com/alipay/sofa/dynamicstock/base/BaseApplication.java (1 hunks)
- sofaboot4-samples/dynamic-stock/base/bootstrap/src/main/java/com/alipay/sofa/dynamicstock/base/controller/IndexController.java (1 hunks)
- sofaboot4-samples/dynamic-stock/base/bootstrap/src/main/java/com/alipay/sofa/dynamicstock/base/data/DatabaseSeed.java (1 hunks)
- sofaboot4-samples/dynamic-stock/base/bootstrap/src/main/resources/application.properties (1 hunks)
- sofaboot4-samples/dynamic-stock/base/bootstrap/src/main/resources/templates/index.html (1 hunks)
- sofaboot4-samples/dynamic-stock/base/bootstrap/src/test/java/com/alipay/sofa/dynamicstock/base/BaseApplicationTests.java (1 hunks)
- sofaboot4-samples/dynamic-stock/base/facade/pom.xml (1 hunks)
- sofaboot4-samples/dynamic-stock/base/facade/src/main/java/com/alipay/sofa/dynamicstock/base/facade/StrategyService.java (1 hunks)
- sofaboot4-samples/dynamic-stock/base/facade/src/main/java/com/alipay/sofa/dynamicstock/base/model/ProductInfo.java (1 hunks)
- sofaboot4-samples/dynamic-stock/base/pom.xml (1 hunks)
- sofaboot4-samples/dynamic-stock/biz1/pom.xml (1 hunks)
- sofaboot4-samples/dynamic-stock/biz1/src/main/java/com/alipay/sofa/dynamicstock/biz1/Biz1Application.java (1 hunks)
- sofaboot4-samples/dynamic-stock/biz1/src/main/java/com/alipay/sofa/dynamicstock/biz1/impl/StrategyServiceImpl.java (1 hunks)
- sofaboot4-samples/dynamic-stock/biz1/src/main/resources/application.properties (1 hunks)
- sofaboot4-samples/dynamic-stock/biz1/src/test/java/com/alipay/sofa/dynamicstock/biz1/Biz1ApplicationTests.java (1 hunks)
- sofaboot4-samples/dynamic-stock/config/base-deployment.yaml (1 hunks)
- sofaboot4-samples/dynamic-stock/config/biz1-deployment.yaml (1 hunks)
- sofaboot4-samples/pom.xml (1 hunks)
Files skipped from review due to trivial changes (15)
- sofaboot4-samples/Formatter.xml
- sofaboot4-samples/HEADER
- sofaboot4-samples/dynamic-stock/base/Dockerfile
- sofaboot4-samples/dynamic-stock/base/bootstrap/src/main/java/com/alipay/sofa/dynamicstock/base/data/DatabaseSeed.java
- sofaboot4-samples/dynamic-stock/base/bootstrap/src/main/resources/application.properties
- sofaboot4-samples/dynamic-stock/base/bootstrap/src/main/resources/templates/index.html
- sofaboot4-samples/dynamic-stock/base/bootstrap/src/test/java/com/alipay/sofa/dynamicstock/base/BaseApplicationTests.java
- sofaboot4-samples/dynamic-stock/base/facade/pom.xml
- sofaboot4-samples/dynamic-stock/base/facade/src/main/java/com/alipay/sofa/dynamicstock/base/facade/StrategyService.java
- sofaboot4-samples/dynamic-stock/base/facade/src/main/java/com/alipay/sofa/dynamicstock/base/model/ProductInfo.java
- sofaboot4-samples/dynamic-stock/base/pom.xml
- sofaboot4-samples/dynamic-stock/biz1/src/main/java/com/alipay/sofa/dynamicstock/biz1/Biz1Application.java
- sofaboot4-samples/dynamic-stock/biz1/src/main/resources/application.properties
- sofaboot4-samples/dynamic-stock/biz1/src/test/java/com/alipay/sofa/dynamicstock/biz1/Biz1ApplicationTests.java
- sofaboot4-samples/dynamic-stock/config/biz1-deployment.yaml
Additional Context Used
LanguageTool (14)
sofaboot4-samples/dynamic-stock/README-zh_CN.md (1)
Near line 37: 您不可用“是”来表达个形容词。大部分人都平常用“很”来代替“是”。您是不是想表达"很普通"?
Context: ...factId> ``` ### biz biz 也是普通 SOFABoot,修改打包插件方式为 sofaArk biz 模块打包方式,打...sofaboot4-samples/dynamic-stock/README.md (13)
Near line 17: Possible typo: you repeated a word
Context: ...effects. ## Experiment application ### base Base is built from a normal SOFABoot applica...
Near line 37: Possible typo: you repeated a word
Context: ...gin ``` ### biz Biz is build from a normal SOFABoot applica...
Near line 38: Make sure that the noun ‘build’ is correct. Did you mean the past participle “built”?
Context: ...ctId> ``` ### biz Biz is build from a normal SOFABoot application, you...
Near line 38: The word ‘biz’ is informal. Consider replacing it.
Context: ... change the packaging plugin to sofaArk biz module packaging plugin, the packaging ...
Near line 70: The word ‘biz’ is informal. Consider replacing it.
Context: ... that the web context path of different biz is changed to different values, so that...
Near line 74: The word ‘biz’ is informal. Consider replacing it.
Context: ...s step will package the module into ark biz jar in the module directory biz1/target...
Near line 132: Possible agreement error. The noun ‘kind’ seems to be countable.
Context: ...ld the module in jar file. we have two kind of deploy: one is uninstall the old ver...
Near line 132: Consider using either the past participle “uninstalled” or the present participle “uninstalling” here.
Context: ...le. we have two kind of deploy: one is uninstall the old version and install the new ver...
Near line 132: Consider using either the past participle “installed” or the present participle “installing” here.
Context: ...d install the new version, the other is install the new version directly. #### Only one...
Near line 156: The word ‘deploy’ is a verb. Did you mean the noun “deployment” (= release, placement)?
Context: ...APSHOT-ark-biz.jar" }'3. check the deploy statusshell curl --location --reque...
Near line 199: The word ‘biz’ is informal. Consider replacing it.
Context: ...run mvn command to build the new module biz package ```mvn clean package -DskipTest...
Near line 264: It appears that a preposition is missing after ‘According’.
Context: ...t POST 'localhost:1238/queryAllBiz' ``` According the return response, we can see that the st...
Near line 292: Possible missing article found.
Context: ... module to be slim: the dependencies of module should be set to provided as much as po...
Additional comments not posted (8)
sofaboot4-samples/dynamic-stock/biz1/pom.xml (2)
14-43: Dependencies are correctly scoped and relevant to the module.
45-70: Build plugins are correctly configured for the module.sofaboot4-samples/dynamic-stock/base/bootstrap/pom.xml (2)
14-59: Dependencies are correctly scoped and relevant to the module.
61-82: Build plugins are correctly configured for the module.sofaboot4-samples/pom.xml (4)
17-20: Modules are correctly defined.
22-42: Properties are correctly defined and relevant to the project.
47-81: Dependency management is correctly defined and relevant to the project.
84-174: Build plugins are correctly configured for the project.
| # 实验内容 | ||
| 基于 SOFABoot 完成模块动态安装,动态更新。 |
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.
Grammatical issue: Replace "是普通" with "很普通".
- biz 也是普通 SOFABoot
+ biz 很普通 SOFABootCommittable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
| # 实验内容 | |
| 基于 SOFABoot 完成模块动态安装,动态更新。 | |
| # 实验内容 | |
| 基于 SOFABoot 完成模块动态安装,动态更新。 |
|
|
||
| </div> | ||
|
|
||
| # 实验内容 |
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.
Add a blank line below the heading.
# 实验内容
基于 SOFABoot 完成模块动态安装,动态更新。Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
| # 实验内容 | |
| # 实验内容 | |
| 基座定义接口 `com.alipay.sofa.dynamicstock.base.facade.StrategyService` | ||
| 模块实现接口 `com.alipay.sofa.dynamicstock.biz1.impl.StrategyServiceImpl` | ||
|
|
||
| 修改模块接口的实现,可以看到不同的效果。 |
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.
Add a blank line below the heading.
修改模块接口的实现,可以看到不同的效果。
## 实验应用Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
| 修改模块接口的实现,可以看到不同的效果。 | |
| 修改模块接口的实现,可以看到不同的效果。 | |
| ## 实验应用 |
|
|
||
| 修改模块接口的实现,可以看到不同的效果。 | ||
|
|
||
| ## 实验应用 |
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.
Add a blank line below the heading.
## 实验应用
### baseCommittable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
| ## 实验应用 | |
| ## 实验应用 | |
| ### base |
| 修改模块接口的实现,可以看到不同的效果。 | ||
|
|
||
| ## 实验应用 | ||
| ### base |
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.
Add a blank line above the heading.
## 实验应用
### baseCommittable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
| ### base | |
| ## 实验应用 | |
| ### base |
| ```json | ||
| { | ||
| "code": "SUCCESS", | ||
| "data": { | ||
| "code": "SUCCESS", | ||
| "message": "Switch biz: biz1:0.0.2-SNAPSHOT is activated." | ||
| } | ||
| } | ||
| ``` |
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.
Surround fenced code blocks with blank lines.
- ```json
+
+ ```json| ```shell | ||
| curl --location --request POST 'localhost:1238/queryAllBiz' | ||
| ``` | ||
| According the return response, we can see that the status of module version 2 has become ACTIVATED | ||
|
|
||
| ```json | ||
| { | ||
| "code": "SUCCESS", | ||
| "data": [ | ||
| { | ||
| "bizName": "biz1", | ||
| "bizState": "DEACTIVATED", | ||
| "bizVersion": "0.0.1-SNAPSHOT", | ||
| "mainClass": "com.alipay.sofa.dynamicstock.biz1.Biz1Application", | ||
| "webContextPath": "provider" | ||
| }, | ||
| { | ||
| "bizName": "biz1", | ||
| "bizState": "ACTIVATED", | ||
| "bizVersion": "0.0.2-SNAPSHOT", | ||
| "mainClass": "com.alipay.sofa.dynamicstock.biz1.Biz1Application", | ||
| "webContextPath": "provider-1" | ||
| } | ||
| ] | ||
| } | ||
| ``` |
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.
Surround fenced code blocks with blank lines.
- ```shell
+
+ ```shell| ```json | ||
| { | ||
| "code": "SUCCESS", | ||
| "data": [ | ||
| { | ||
| "bizName": "biz1", | ||
| "bizState": "DEACTIVATED", | ||
| "bizVersion": "0.0.1-SNAPSHOT", | ||
| "mainClass": "com.alipay.sofa.dynamicstock.biz1.Biz1Application", | ||
| "webContextPath": "provider" | ||
| }, | ||
| { | ||
| "bizName": "biz1", | ||
| "bizState": "ACTIVATED", | ||
| "bizVersion": "0.0.2-SNAPSHOT", | ||
| "mainClass": "com.alipay.sofa.dynamicstock.biz1.Biz1Application", | ||
| "webContextPath": "provider-1" | ||
| } | ||
| ] | ||
| } | ||
| ``` |
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.
Surround fenced code blocks with blank lines.
- ```json
+
+ ```json| ] | ||
| } | ||
| ``` | ||
| 10. Access the service, we can see that the order returned at this time has been changed to the order of module version 2 |
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.
Fix grammatical errors and improve clarity.
- 10. Access the service, we can see that the order returned at this time has been changed to the order of module version 2
+ 10. Access the service. We can see that the order returned at this time has been changed to the order of module version 2.Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
| 10. Access the service, we can see that the order returned at this time has been changed to the order of module version 2 | |
| 10. Access the service. We can see that the order returned at this time has been changed to the order of module version 2. |
| ## Attention | ||
| 1. Here we use simple applications for verification. If it is a complex application, pay attention to the module to be slim: the dependencies of module should be set to provided as much as possible if it had been imported from the base. | ||
| 2. If you have any questions about the use of web context path, you can check [here](https://github.com/koupleless/koupleless/tree/master/samples/springboot-samples/web/tomcat) |
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.
Fix grammatical errors and improve clarity.
- Here we use simple applications for verification. If it is a complex application, pay attention to the module to be slim: the dependencies of module should be set to provided as much as possible if it had been imported from the base.
+ Here we use simple applications for verification. If it is a complex application, pay attention to keeping the module slim: the dependencies of the module should be set to provided as much as possible if they have been imported from the base.Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
| ## Attention | |
| 1. Here we use simple applications for verification. If it is a complex application, pay attention to the module to be slim: the dependencies of module should be set to provided as much as possible if it had been imported from the base. | |
| 2. If you have any questions about the use of web context path, you can check [here](https://github.com/koupleless/koupleless/tree/master/samples/springboot-samples/web/tomcat) | |
| ## Attention | |
| 1. Here we use simple applications for verification. If it is a complex application, pay attention to keeping the module slim: the dependencies of the module should be set to provided as much as possible if they have been imported from the base. | |
| 2. If you have any questions about the use of web context path, you can check [here](https://github.com/koupleless/koupleless/tree/master/samples/springboot-samples/web/tomcat) |
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.
Actionable comments posted: 0
Review Details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (1)
- .github/workflows/samples_formatter_and_unit_test.yml (2 hunks)
Files not reviewed due to errors (1)
- .github/workflows/samples_formatter_and_unit_test.yml (no review received)
Summary by CodeRabbit
New Features
dynamic-stockandproviderservices.Documentation
Bug Fixes
pom.xmlfiles.Tests
BaseApplicationandBiz1Application.