4646 idleThreshold time.Duration
4747 conns xsync.Map [uuid.UUID , * connWrapper ]
4848 done chan struct {}
49- traceSql * trace.DatabaseSQL
49+ trace * trace.DatabaseSQL
5050 traceRetry * trace.Retry
5151 retryBudget budget.Budget
5252 }
@@ -80,18 +80,17 @@ func (c *Connector) Scheme() scheme.Client {
8080}
8181
8282const (
83- queryProcessor_QueryService = iota + 1
84- queryProcessor_TableService
83+ QUERY_SERVICE = iota + 1 //nolint:revive,stylecheck
84+ TABLE_SERVICE //nolint:revive,stylecheck
8585)
8686
8787func (c * Connector ) Open (name string ) (driver.Conn , error ) {
88- //TODO implement me
89- panic ("implement me" )
88+ return nil , xerrors .WithStackTrace (driver .ErrSkip )
9089}
9190
9291func (c * Connector ) Connect (ctx context.Context ) (driver.Conn , error ) {
9392 switch c .queryProcessor {
94- case queryProcessor_QueryService :
93+ case QUERY_SERVICE :
9594 id := uuid .New ()
9695 cc , err := querySql .New (ctx , c , append (
9796 c .queryOpts ,
@@ -114,7 +113,7 @@ func (c *Connector) Connect(ctx context.Context) (driver.Conn, error) {
114113
115114 return conn , nil
116115
117- case queryProcessor_TableService :
116+ case TABLE_SERVICE :
118117 id := uuid .New ()
119118 cc , err := tableSql .New (ctx , c , append (
120119 c .tableOpts ,
@@ -168,10 +167,10 @@ func Open(parent ydbDriver, balancer grpc.ClientConnInterface, opts ...Option) (
168167 c := & Connector {
169168 parent : parent ,
170169 balancer : balancer ,
171- queryProcessor : queryProcessor_TableService ,
170+ queryProcessor : TABLE_SERVICE ,
172171 clock : clockwork .NewRealClock (),
173172 done : make (chan struct {}),
174- traceSql : & trace.DatabaseSQL {},
173+ trace : & trace.DatabaseSQL {},
175174 traceRetry : & trace.Retry {},
176175 }
177176
0 commit comments