You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Yifan Cai (Jira)" <ji...@apache.org> on 2025/02/11 19:11:00 UTC

[jira] [Updated] (CASSSIDECAR-208) Refactoring Guice modules

     [ https://issues.apache.org/jira/browse/CASSSIDECAR-208?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Yifan Cai updated CASSSIDECAR-208:
----------------------------------
    Change Category: Code Clarity
         Complexity: Normal
             Status: Open  (was: Triage Needed)

> Refactoring Guice modules
> -------------------------
>
>                 Key: CASSSIDECAR-208
>                 URL: https://issues.apache.org/jira/browse/CASSSIDECAR-208
>             Project: Sidecar for Apache Cassandra
>          Issue Type: Improvement
>          Components: Rest API
>            Reporter: Yifan Cai
>            Assignee: Yifan Cai
>            Priority: Major
>
> {color:#000000}As more engineering efforts are made into Sidecar, the current Guice module setup is reaching to a bottleneck, making it hard to scale, hurting the development experience. {color}
> {color:#000000}- Object bindings are declared in one single module, MainModule, which is used like a dump ground. Besides the growing files size (it now has 1000 lines and growing), one also cannot tell in which feature the bindings are needed.{color}
> {color:#000000}- Bindings take a growing large amount of dependencies. For example, the vertx router provider already takes 40 parameters. It is hard to manage. And the size of the parameter list is increasing, as new APIs are introduced. {color}
> {color:#000000}I would like to propose a refactoring to Guice modules, applying the Guice best practices ({color}[https://github.com/google/guice/wiki/BestPractices]{color:#000000}). {color}
> {color:#000000}Organize the bindings by feature to provide a good dependency isolation, as well as documentation.{color}
> {color:#000000}Invert the control of building object with large amount of dependencies, e.g. vertx router and scheduling tasks, to make it open to extend in the future development.{color}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cassandra.apache.org
For additional commands, e-mail: commits-help@cassandra.apache.org