dsc alternatives and similar packages
Based on the "NoSQL Databases" category.
Alternatively, view dsc alternatives based on common mentions on social networks and blogs.
-
mgo
MongoDB driver for the Go language that implements a rich and well tested selection of features under a very simple API following standard Go idioms. -
qmgo
The MongoDB dirver for Go. It‘s based on official MongoDB driver but easier to use like Mgo. -
Kivik
Kivik provides a common interface to CouchDB or CouchDB-like databases for Go and GopherJS. -
go-rejson
Golang client for redislabs' ReJSON module using Redigo golang client. Store and manipulate structs as JSON objects in redis with ease. -
godscache
A wrapper for the Google Cloud Platform Go Datastore package that adds caching using memcached.
Scout APM - Leading-edge performance monitoring starting at $39/month
Do you think we are missing an alternative of dsc or a related project?
Popular Comparisons
README
Datastore Connectivity (dsc)
This library is compatible with Go 1.10+
Please refer to [CHANGELOG.md
](CHANGELOG.md) if you encounter breaking changes.
- Motivation
- Usage
- Prerequisites
- Installation
- API Documentaion
- Tests
- Examples
- License
- Credits and Acknowledgements
Motivation
This library was developed as part of dsunit (Datastore unit testibility library) to provide unified access to SQL, noSQL, or any other store that deals with structured data in SQL-ish way.
Usage:
The following is a very simple example of CRUD operations with dsc
package main
import (
)
func main() {
config := dsc.NewConfig("mysql", "[user]:[password]@[url]", "user:root,password:dev,url:tcp(127.0.0.1:3306)/mydb?parseTime=true")
factory := NewManagerFactory()
manager, err := factory.Create(config)
if err != nil {
panic(err.Error())
}
// manager := factory.CreateFromURL("file:///etc/myapp/datastore.json")
interest := Interest{}
success, err:= manager.ReadSingle(&interest, SELECT id, name, expiry, category FROM interests WHERE id = ?", []interface{}{id},nil)
if err != nil {
panic(err.Error())
}
var intersts = make([]Interest, 0)
err:= manager.ReadAll(&interests, SELECT id, name, expiry, category FROM interests", nil ,nil)
if err != nil {
panic(err.Error())
}
intersts := []Interest {
Interest{Name:"Abc", ExpiryTimeInSecond:3600, Category:"xyz"},
Interest{Name:"Def", ExpiryTimeInSecond:3600, Category:"xyz"},
Interest{Id:20, Name:"Ghi", ExpiryTimeInSecond:3600, Category:"xyz"},
}
inserted, updated, err:= manager.PersistAll(&intersts, "interests", nil)
if err != nil {
panic(err.Error())
}
deleted, err := manager.DeleteAll(&intersts, "intersts", nil)
if err != nil {
panic(err.Error())
}
fmt.Printf("Inserted %v, updated: %v\n", deleted)
}
More examples illustrating the use of the API are located in the
[examples
](examples) directory.
Details about the API are available in the [docs
](docs) directory.
Prerequisites
Go version v1.5+ is required.
To install the latest stable version of Go, visit http://golang.org/dl/
Target
Installation:
- Install Go 1.5+ and setup your environment as Documented here.
- Get the client in your
GOPATH
:go get github.com/viant/dsc
- To update the client library:
go get -u github.com/viant/dsc
- To update the client library:
Some Hints:
- To run a go program directly:
go run <filename.go>
- to build:
go build -o <output> <filename.go>
API Documentation
API documentation is available in the [docs
](docs/README.md) directory.
Tests
This library is packaged with a number of tests. Tests require Testify library.
Before running the tests, you need to update the dependencies:
$ go get .
To run all the test cases with race detection:
$ go test
Examples
A simple CRUD applications is provided in the [examples
](examples) directory.
GoCover
License
The source code is made available under the terms of the Apache License, Version 2, as stated in the file LICENSE
.
Individual files may be made available under their own specific license, all compatible with Apache License, Version 2. Please see individual files for details.
Credits and Acknowledgements
Library Author: Adrian Witas
Contributors: Sudhakaran Dharmaraj
*Note that all licence references and agreements mentioned in the dsc README section above
are relevant to that project's source code only.