Coder Social home page Coder Social logo

Rocket Integration about juniper HOT 6 CLOSED

theduke avatar theduke commented on August 15, 2024 12
Rocket Integration

from juniper.

Comments (6)

mhallin avatar mhallin commented on August 15, 2024 2

Nice!

I used that example and some work put into the Iron integration to come up with a rudimentary integration. You can see the example server here: https://github.com/mhallin/juniper/blob/master/examples/rocket-server.rs. This would be the Rocket-specific code you as an application developer would have to write.

I'm a bit annoyed by the fact that you have to make separate functions for the GET and POST routes, and that GET /graphql returns 404 unless we add yet another route. It would be possible to create Route instances directly, but then it would be harder to provide custom State<> objects to the GraphQL context for e.g. database access.

Unless I'm missing something, this will probably be the integration that I'll release in the next version.

from juniper.

mhallin avatar mhallin commented on August 15, 2024

Definitely! On the non-async side of Rust web programming, Rocket seems to be really .. lifting off?

from juniper.

theduke avatar theduke commented on August 15, 2024

Rocket seems to be really .. lifting off?

I see what you did there. 🚀

from juniper.

monorkin avatar monorkin commented on August 15, 2024

Hey!

I've made a response handler for Rocket that integrates with Juniper. It's available here and can be used like this.

Was the integration you are talking about imagined in a similar fashion? Would you be interested in a PR from this?

from juniper.

monorkin avatar monorkin commented on August 15, 2024

Looks great.

When will this be released?

from juniper.

monorkin avatar monorkin commented on August 15, 2024

@mhallin just saw the release. I thin this can be closed now.

from juniper.

Related Issues (20)

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.