Skip to content

Mongo + GraphQL = MongoQL. Kotlin Spring Boot project that takes advantages of the MongoQL maven plugin to expose a GraphQL interface over a database/collection

License

Notifications You must be signed in to change notification settings

Hellorin/MongoQL-kotlin-explorer

Repository files navigation

MongoQL-kotlin-explorer

Build Status

Purpose

Show usage of the MongoQL-springboot-maven-plugin to be able to easily explore MongoQL data through a GraphQL interface

Deployed on Heroku

If you don't want to go through all the trouble of setting things up, you can see the result deployed on the Heroku plateform using a Mongo Atlas database:

HERE

How to use (MongoDB Atlas)

Please refer to MongoQL-core readme for the initial setup of MongoDB data.

Then you should be able to call simply

mvn spring-boot:run -DPORT=8080 -DmongodbUserPwd=*pwd*

Following the call to this command, open a browser and go to this link. You have a here a console to type your graphql query. If you followed the MongoQL-core readme for the initial setup, type the following:

{
  allPerson {
    name
  }
}

The result should then be:

{
  "data": {
    "allPerson": [
      {
        "name": "David"
      },
      {
        "name": "Mathieu"
      },
      {
        "name": "Nuno"
      },
      {
        "name": "Kevin"
      },
      {
        "name": "Michael"
      }
    ]
  }
}

Technologies

  • Kotlin
  • Spring Boot
  • GraphQL Java
  • Spring Boot GraphQL

About

Mongo + GraphQL = MongoQL. Kotlin Spring Boot project that takes advantages of the MongoQL maven plugin to expose a GraphQL interface over a database/collection

Resources

License

Stars

Watchers

Forks

Packages

No packages published