Close 关闭连接池。
()
| 187 | |
| 188 | // Close 关闭连接池。 |
| 189 | func (s *Store) Close() error { |
| 190 | if s.pool != nil { |
| 191 | s.pool.Close() |
| 192 | } |
| 193 | return nil |
| 194 | } |
| 195 | |
| 196 | // float32SliceToPgVector 将 []float32 转为 pgvector 兼容的 []float32。 |
| 197 | // 这里直接复用原 slice, pgx 会将其编码为 pgvector 类型。 |