You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@celix.apache.org by GitBox <gi...@apache.org> on 2021/10/03 12:25:26 UTC

[GitHub] [celix] pnoltes opened a new pull request #369: Feature/deadlock on stop cmd

pnoltes opened a new pull request #369:
URL: https://github.com/apache/celix/pull/369


   This PR fixes an issue with the shell commands `install`, `start` `stop` and `uninstall` leading to deadlocks.
   
   A deadlock occurred under two conditions:
    - stopping the shell bundle from a shell interface (shell_tui, etc)
    - stopping or starting a bundle with provides an additional shell command from a shell interface.
   This is because the shell protects (mutex) the shell commands while being used and when shell commands are added/removed. And for example using a shell command `stop` prevents removing/adding additional shell commands.
   
   This issue is solved by adding async bundle lifecycle functions to the celix_framework, these function enforce that the bundle lifecycle updates are handled on a separate spawned thread.
   
   This PR also updates the following:
   
   - Adds unit tests for shell_tui and refactors the shell_tui so that input,output and error file descriptors can be configured
   - Fixes an issue in the shell_tui for autocomplete with shell command containing namespace (e.g. "celix::")
   - Refactors the `lb` command so that the - almost always used - `-a` argument is no longer needed.
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@celix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [celix] codecov-commenter commented on pull request #369: Feature/deadlock on stop cmd

Posted by GitBox <gi...@apache.org>.
codecov-commenter commented on pull request #369:
URL: https://github.com/apache/celix/pull/369#issuecomment-932942272


   # [Codecov](https://codecov.io/gh/apache/celix/pull/369?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#369](https://codecov.io/gh/apache/celix/pull/369?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (44f2ed7) into [master](https://codecov.io/gh/apache/celix/commit/15c7853c6d3ab306de3507808f0333569a321929?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (15c7853) will **increase** coverage by `0.16%`.
   > The diff coverage is `84.75%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/celix/pull/369/graphs/tree.svg?width=650&height=150&src=pr&token=JdsiThga8P&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/celix/pull/369?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master     #369      +/-   ##
   ==========================================
   + Coverage   71.57%   71.74%   +0.16%     
   ==========================================
     Files         203      206       +3     
     Lines       34967    35319     +352     
   ==========================================
   + Hits        25029    25338     +309     
   - Misses       9938     9981      +43     
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/celix/pull/369?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [bundles/shell/shell/src/start\_command.c](https://codecov.io/gh/apache/celix/pull/369/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YnVuZGxlcy9zaGVsbC9zaGVsbC9zcmMvc3RhcnRfY29tbWFuZC5j) | `79.16% <0.00%> (-7.20%)` | :arrow_down: |
   | [bundles/shell/shell/src/std\_commands.c](https://codecov.io/gh/apache/celix/pull/369/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YnVuZGxlcy9zaGVsbC9zaGVsbC9zcmMvc3RkX2NvbW1hbmRzLmM=) | `100.00% <ø> (ø)` | |
   | [bundles/shell/shell/src/uninstall\_command.c](https://codecov.io/gh/apache/celix/pull/369/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YnVuZGxlcy9zaGVsbC9zaGVsbC9zcmMvdW5pbnN0YWxsX2NvbW1hbmQuYw==) | `81.81% <0.00%> (-8.19%)` | :arrow_down: |
   | [bundles/shell/shell\_tui/src/history.c](https://codecov.io/gh/apache/celix/pull/369/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YnVuZGxlcy9zaGVsbC9zaGVsbF90dWkvc3JjL2hpc3RvcnkuYw==) | `87.09% <ø> (ø)` | |
   | [bundles/shell/shell/src/lb\_command.c](https://codecov.io/gh/apache/celix/pull/369/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YnVuZGxlcy9zaGVsbC9zaGVsbC9zcmMvbGJfY29tbWFuZC5j) | `80.30% <40.00%> (-4.97%)` | :arrow_down: |
   | [...framework/src/framework\_bundle\_lifecycle\_handler.c](https://codecov.io/gh/apache/celix/pull/369/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-bGlicy9mcmFtZXdvcmsvc3JjL2ZyYW1ld29ya19idW5kbGVfbGlmZWN5Y2xlX2hhbmRsZXIuYw==) | `69.41% <66.66%> (+44.05%)` | :arrow_up: |
   | [bundles/shell/shell/src/install\_command.c](https://codecov.io/gh/apache/celix/pull/369/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YnVuZGxlcy9zaGVsbC9zaGVsbC9zcmMvaW5zdGFsbF9jb21tYW5kLmM=) | `89.47% <83.33%> (+13.28%)` | :arrow_up: |
   | [libs/framework/src/framework.c](https://codecov.io/gh/apache/celix/pull/369/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-bGlicy9mcmFtZXdvcmsvc3JjL2ZyYW1ld29yay5j) | `77.55% <83.33%> (-0.03%)` | :arrow_down: |
   | [bundles/shell/shell\_tui/src/shell\_tui.c](https://codecov.io/gh/apache/celix/pull/369/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YnVuZGxlcy9zaGVsbC9zaGVsbF90dWkvc3JjL3NoZWxsX3R1aS5j) | `79.29% <91.33%> (ø)` | |
   | [bundles/shell/shell\_tui/src/activator.c](https://codecov.io/gh/apache/celix/pull/369/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YnVuZGxlcy9zaGVsbC9zaGVsbF90dWkvc3JjL2FjdGl2YXRvci5j) | `93.54% <93.54%> (ø)` | |
   | ... and [7 more](https://codecov.io/gh/apache/celix/pull/369/diff?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/celix/pull/369?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/celix/pull/369?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Last update [15c7853...44f2ed7](https://codecov.io/gh/apache/celix/pull/369?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@celix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [celix] pnoltes merged pull request #369: Feature/deadlock on stop cmd

Posted by GitBox <gi...@apache.org>.
pnoltes merged pull request #369:
URL: https://github.com/apache/celix/pull/369


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@celix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org