dbpack

module
v0.1.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 13, 2022 License: Apache-2.0

README

DBPack

LICENSE codecov

dbpack.svg

DBPack means a database cluster tool pack. It can be deployed as a sidecar in a pod, it shields complex basic logic, so that business development does not need to rely on a specific SDK, simplifying the development process and improving development efficiency.

Feature

  • support MYSQL protocol
  • simple and easy distributed transaction solution inspired by kubernetes
  • support read write splitting,supports custom SQL routing via Hint
  • deployed as a sidecar,support any language
  • sharding: support query on sharded table, support order by,support limit
  • more features on the road

Metrics

using prometheus metrics, default metric server run at :18888

Documentation

Requirements

  • Go 1.17 or higher
  • MYSQL (5.7+)

Contribution Guide

Architecture

architecture

  • Listener: responsible for parsing the SQL protocol.
  • Executor: responsible for forwarding SQL requests to the backend physical DB.
  • Filter: responsible for metrics statistics, SQL interception, encryption and decryption of sensitive information, etc.
  • ConnectionFilter: process the intercepted SQL on the connection.

WeChat group

To enter the WeChat discussion group, please scan the QR code below and reply with the code "join the group".

image-20220427091848831

License

DBPack is licensed under the Apache License, Version 2.0.

Directories

Path Synopsis
pkg
dt
http
* Copyright 2022 CECTC, Inc.
* Copyright 2022 CECTC, Inc.
lb
log
sql
third_party
cache
Package cache implements a LRU cache.
Package cache implements a LRU cache.
parser/ast
Package ast is the abstract syntax tree parsed from a SQL statement by parser.
Package ast is the abstract syntax tree parsed from a SQL statement by parser.
parser/goyacc
Goyacc is a version of yacc generating Go parsers.
Goyacc is a version of yacc generating Go parsers.
pools
Package pools provides functionality to manage and reuse resources like connections.
Package pools provides functionality to manage and reuse resources like connections.
sync2
Package sync2 provides extra functionality along the same lines as sync.
Package sync2 provides extra functionality along the same lines as sync.
timer
Package timer provides various enhanced timer functions.
Package timer provides various enhanced timer functions.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL