Skip to content
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

[RFC #0006] Introduction of component-base Repository #955

Closed
cubxxw opened this issue Aug 25, 2023 · 0 comments · Fixed by openim-sigs/component-base#2
Closed

[RFC #0006] Introduction of component-base Repository #955

cubxxw opened this issue Aug 25, 2023 · 0 comments · Fixed by openim-sigs/component-base#2
Assignees
Labels
enhancement New feature or request kind/feature Categorizes issue or PR as related to a new feature. proposal RFC Project design proposal
Milestone

Comments

@cubxxw
Copy link
Contributor

cubxxw commented Aug 25, 2023

RFC #0006 Introduction of component-base Repository

Meta

📇Topics

Summary

Proposal to introduce the component-base repository, a centralized hub to house common tools and shared code, aimed to enhance code reusability and component coherence, inspired by Kubernetes's component-base.

Motivation

  • Current repositories like chat, core, and server share multiple common tools, but dependencies aren't clearly isolated.
  • A clear, independent repository helps external contributors or platforms to leverage OpenIMSDK's tools effortlessly.
  • Achieve similar component structure like Kubernetes to maintain a modular and scalable codebase.

What it is

component-base is a repository designed to contain shared tools and utilities used across OpenIMSDK projects. This will include, but isn't limited to:

  • ComponentConfig implementations
  • Flag and command handling
  • HTTPS serving
  • Delegated authn/z
  • Logging.

Comparing Repositories: openim-sigs/component-base vs OpenIMSDK/tools

Overview

The openim-sigs/component-base repository stands distinct from the OpenIMSDK/tools repository. Each serves a unique purpose in the ecosystem and caters to different consumers.

Primary Consumers of OpenIMSDK/tools

The main consumers for the OpenIMSDK/tools repository are:

These entities leverage the utilities and tools offered by this repository for their functioning and enhancements.

Purpose of openim-sigs/component-base

In contrast, the openim-sigs/component-base repository houses core foundational components. These are designed to be used externally, offering a broad spectrum of utilities and functions. Its scope of influence and application, thus, tends to be more expansive than that of the OpenIMSDK/tools.

Migration

Transition involves:

  1. Identifying common tools/code from the respective repositories.
  2. Refactoring and migrating them to component-base.
  3. Adjusting dependencies in the original repositories to now point to component-base.

Drawbacks

  • Initial overhead due to refactoring.
  • Potential for issues during the migration phase.

Alternatives

  • Maintain the current structure but ensure stricter guidelines for code sharing.
  • Create separate utility repositories for each original repository instead of a single shared one.

Prior Art

Kubernetes's component-base repository serves a similar purpose. They created it to have a unified, consistent base for components, promoting shared utilities and configurations.

Unresolved Questions

  • What might be the challenges in the migration phase?
  • How do we ensure minimal disruption during the transition?

Spec. Changes (OPTIONAL)

No specification changes as of now.

History

  • 2023-08-25: Initial draft proposed by @cubxxw
@cubxxw cubxxw added enhancement New feature or request kind/feature Categorizes issue or PR as related to a new feature. RFC Project design proposal proposal labels Aug 25, 2023
@cubxxw cubxxw changed the title [RFC #0006](https://github.com/OpenIMSDK/community/edit/main/RFC/0006-openim-component-base.md) Introduction of component-base Repository [RFC #0006] Introduction of component-base Repository Aug 25, 2023
@cubxxw cubxxw self-assigned this Aug 25, 2023
@cubxxw cubxxw added this to the v3.3 milestone Aug 25, 2023
@cubxxw cubxxw linked a pull request Sep 4, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request kind/feature Categorizes issue or PR as related to a new feature. proposal RFC Project design proposal
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

1 participant