New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

github.com/tharindu-wj/golang-rest-couchdb

Package Overview
Dependencies
Alerts
File Explorer
Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

github.com/tharindu-wj/golang-rest-couchdb

  • v0.0.0-20190605094803-fd37490d0e12
  • Source
  • Go
  • Socket score

Version published
Created
Source

Project Setup

Required Packages

* gorilla/mux : `go get -u github.com/gorilla/mux`
* couchbase/gocb : `go get gopkg.in/couchbase/gocb.v1`

Couchbase Setup

* Need to create two buckets in couchbase `company` and `geo`

Project Deployment

Project consist with 3 binary files for each service. These files located in '/bin' folder. Before run those add couchbase credentials in auth.json

* `companyService` : Run server on `localhost:3000` listen for company services
* `geoService` : Run server on `localhost:3001` listen for geo services
* `restuarantImporter` : Import resturants data to couchDB. This needs valid json file with restuarants.
   Example json can be found in `/resources/retuarants.json`

KrakenD Integration

* Run Krakend with `/resources/krakend.json`. Before run this `company` and `geo` services should be executed and 
  open their ports

API Endpoints

Sample postman collection can be found in `/resources/Go REST Couchbase.postman_collection.json`

Company Service

  • http://localhost:3000/api/v1/company/{id}
    • GET: get company by id
  • http://localhost:3000/api/v1/companies?ids={[ids]}
    • GET:get companies by multiple id's. ex:-["12345678","14723698"]

Geo Service

Krakend

Development

* All services source codes in `/src` folder
* Common package helper functions and models are in `shared` folder

FAQs

Package last updated on 05 Jun 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc