GithubHelp home page GithubHelp logo

vgkholla / plant-tracker Goto Github PK

View Code? Open in Web Editor NEW
0.0 2.0 1.0 485 KB

Server side application to track gardening activities. Built with CosmosDB, gRPC and GraphQL.

Java 99.45% HTML 0.55%
cosmosdb graphql grpc-java grpc graphql-server grapqhl-client graphql-java cosmos-db rejoiner protobuf3

plant-tracker's Introduction

plant-tracker

Build Status Codacy Badge

Playing with CosmosDB and GraphQL

To try, first create a CosmosDB account that has a Database with name "PlantsTracker" and container with name "plants"

Then run

./gradlew run --args="--cosmosDBAccountEndpoint COSMOS_DB_ACCOUNT_ENDPOINT --cosmosDBAccountKey COSMOS_DB_ACCOUNT_KEY --cosmosDBPreferredRegions COSMOS_DB_ACCOUNT_PREFERRED_REGION1,COSMOS_DB_ACCOUNT_PREFERRED_REGION2"

Navigate to http://localhost:8080/ and try out the following queries

Create plant
mutation {
  createPlant(input: { plant: {
    id: "ptracker:plant:myplant",
    name: "MyPlant"
  }}) {
    name
  }
}
Get created plant
{
  getPlant(input: { id: "ptracker:plant:myplant"}) {
    name
  }
}
Update plant
mutation {
  updatePlant(input: { plant: {
    id: "ptracker:plant:myplant",
    name: "MyPlantUpdated"
  }, shouldUpsert: true}) {
    name
  }
}
Get updated plant
{
  getPlant(input: { id: "ptracker:plant:myplant"}) {
    name
  }
}
Delete plant
mutation {
  deletePlant(input: { id: "ptracker:plant:myplant"}) {
    _
  }
}
Try to get deleted plant
{
  getPlant(input: { id: "ptracker:plant:myplant"}) {
    name
  }
}

plant-tracker's People

Contributors

vgkholla avatar

Watchers

 avatar  avatar

Forkers

tejala30

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.