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

【腾讯犀牛鸟开源课题实战】对接mysql sdk #174

Open
weimch opened this issue Aug 19, 2024 · 0 comments
Open

【腾讯犀牛鸟开源课题实战】对接mysql sdk #174

weimch opened this issue Aug 19, 2024 · 0 comments

Comments

@weimch
Copy link
Contributor

weimch commented Aug 19, 2024

  • 背景:mysql数据库已经成为构建互联网世界的基石,尤其是其支持事务的特性,支撑了很多互联网的很多应用场景,比如电商、支付等。
  • 需求:希望你能参考当前已有类库的接口,为tRPC-Cpp设计一套灵活、易用的接口,更好地扩展tRPC的生态。具体来来说,在实现时,你需要注意下面的要点:
    • 你应该封装的mysql c-api,并且基于线程池来驱动c-api的调用,并做好与框架协程模式、线程模式的下框架工作线程的交互。
    • 你应该尽可能复用tRPC-Cpp的各个模块,具体来说,你应该继承 ServiceProxy,实现一个比如MysqlServiceProxy,提供设计良好的接口,在实现接口时,应该复用框架的服务发现以及拦截器模块。
    • 当前阶段,支持事务的接口不是必须的,你可以按需按能力来完成这个需求。
  • 参考资料:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant