For test use
(ctx context.Context, name string)
| 2127 | |
| 2128 | // For test use |
| 2129 | func (sc *ServerContext) Database(ctx context.Context, name string) *db.DatabaseContext { |
| 2130 | db, err := sc.GetDatabase(ctx, name) |
| 2131 | if err != nil { |
| 2132 | panic(fmt.Sprintf("Unexpected error getting db %q: %v", name, err)) |
| 2133 | } |
| 2134 | return db |
| 2135 | } |
| 2136 | |
| 2137 | func (sc *ServerContext) initializeGocbAdminConnection(ctx context.Context) error { |
| 2138 | base.ConsolefCtx(ctx, base.LevelInfo, base.KeyAll, "Initializing server admin connection...") |