- Refactored DELETE statement: appending PK values at the end of parameter list is no longer needed.
- Refactored UPDATE statement: appending PK values at the end of parameter list is no longer needed.
- Feature: INSERT/UPSERT statement accepts WITH PK clause. Appending PK values at the end of parameter list is no longer needed.
- Deprecated: WITH singlePK/SINGLE_PK is now deprecated for INSERT/UPSERT, DELETE and UPDATE statements.
- Improvement: implement fmt.Stringer
- Improvement: Conn implements interface driver.Pinger
- Improvement: Driver implements interface driver.DriverContext
- Improvement: StmtCreateCollection/StmtAlterCollection/StmtDropCollection implements interface driver.StmtExecContext
- Improvement: StmtListCollections implements interface driver.StmtQueryContext
- Improvement: StmtCreateDatabase/StmtAlterDatabase/StmtDropDatabase implements interface driver.StmtExecContext
- Improvement: StmtListDatabases implements interface driver.StmtQueryContext
- Improvement: StmtInsert/StmtDelete/StmtUpdate implements interface driver.StmtExecContext
- Improvement: StmtSelect implements interface driver.StmtQueryContext
- BREAKING: typo fixed, change struct RestReponse to RestResponse
- BREAKING: bump GO version to v1.18
- Refactor: remove internal sync.Mutex from OfferInfo
- Add methods GetApiVersion/GetAutoId/SetAutoId to RestClient struct
- Refactor: follow go-module-template
- Refactor: move tests to separated subpackage
- Fix CodeQL alerts
- Dependency: bump github.com/btnguyen2k/consu/checksum to v1.1.0
- Fix: server may return no content with http status 204 or 304
- Fix: golang-lint
- Change default API version to
2020-07-15
. - Add Hierarchical Partition Keys (sub-partitions) support.
- Use PartitionKey version 2 (replacing version 1), hence large PK is always enabled.
- Bug fixes, Refactoring & Enhancements.
RestClient
:QueryDocuments
: enhancements & bug fixed with cross-partition queries.- New function
QueryDocumentsCrossPartition(QueryReq) *RespQueryDocs
do address limitations ofQueryDocuments
.
database/sql
driver:- Update
StmtSelect.Query
to better support cross-partition queries.
- Update
- Update
RestClient
QueryDocuments
: better support cross-partition queries.ListDocuments
: support fetching change feed.
- REST client: rewrite
RestClient.QueryDocuments
. TODO:- (v0.1.7+) simple cross-partition queries (+paging)
- [-] cross-partition queries with ordering (+paging) / partial supported if number of pkrange == 1
- [-] cross-partition queries with group-by (+paging) / partial supported if number of pkrange == 1
- REST client: fix a bug where function
QueryDocuments
does not return all documents if the query is cross-partition.
- REST client & Driver for
database/sql
: fix a bug in functionReplaceOfferForResource
caused by a change from v0.1.5.
- Fix a bug where no-parameterized query returns error.
- Fix a bug where database or collection name contains upper-cased characters.
- REST client & Driver for
database/sql
:- Add parameter
InsecureSkipVerify=<true/false>
to connection string. This parameter is optional, default value isfalse
. Iftrue
, REST client will disable CA verification for https endpoint (useful to run against test/dev env with local/docker Cosmos DB emulator).
- Add parameter
- REST client: new function
GetPkranges(dbName, collName string)
. - Support cross-partition queries & fix "The provided cross partition query can not be directly served by the gateway".
- REST client & Driver for
database/sql
:- Add
auto-id
support.
- Add
- REST client: new functions
GetOfferForResource(rid string)
: get throughput info of a resource.QueryOffers(query string)
: query existing offers.ReplaceOfferForResource(rid string, ru, maxru int)
: replace/update a resource's throughput.
- Driver for
database/sql
:- Add default database support to DSN.
- Add
ALTER DATABASE
andALTER COLLECTION
statements.
First release:
- REST client for Azure Cosmos DB SQL API:
- Database:
Create
,Get
,Delete
andList
. - Collection:
Create
,Replace
,Get
,Delete
andList
. - Document:
Create
,Replace
,Get
,Delete
,Query
andList
.
- Database:
- Driver for
database/sql
, supported statements:- Database:
CREATE DATABASE
,DROP DATABASE
,LIST DATABASES
- Collection/Table:
CREATE TABLE/COLLECTION
,DROP TABLE/COLLECTION
,LIST TABLES/COLLECTIONS
- Document:
INSERT
,UPSERT
,SELECT
,UPDATE
,DELETE
- Database: