Category: Announcements

  • Introducing playground.wpgraphql.com

    I’ve done many presentations about the WPGraphQL plugin, and I find myself showing demos of many of the same features, so in order to streamline the demos before my presentation at the 2018 WordCamp Phoenix, I created https://playground.wpgraphql.com

    This site showcases examples of GraphQL Queries and Mutations on a live WordPress site with the WPGraphQL plugin active. The demos start out very basic, and as you work down the list, you will see progressively more advanced examples of GraphQL use cases, demonstrating both unique features of the WPGraphQL plugin and the broader GraphQL Query Language.

    Enjoy.

  • WPGraphQL Featured on FreeCodeCamp

    FreeCodeCamp is a popular YouTube channel that posts free videos about coding. Today, Jesse Weigel did a live coding session diving into using GraphQL with WordPress and after comparing a few options, he settled on using WPGraphQL.

    Watching the video was eye opening. It was great to see that folks are interested in using GraphQL with WordPress, but it was also clear that the documentation and resources to get started using WPGraphQL are still pretty lacking. Documentation will be a focus over the next few weeks to make sure folks have what they need to get up and running with WPGraphQL.

    Thanks, Jesse for featuring the plugin!

    Check out the video from FreeCodeCamp here:

     

     

  • Tracing for WPGraphQL

    In 2015, Huey Petersen wrote an article about instrumenting a GraphQL schema to track resolver times and provide insight into how the GraphQL server is performing. Since then Apollo Optics has taken the instrumentation to a new level, providing a SaaS solution for storing data about your GraphQL requests. The Apollo team has also been working on a proposal to standardize the instrumentation, and they’re calling it Apollo Tracing.

    The proposed spec is still young, but the goal is to come up with a standard for how GraphQL schemas should record performance metrics for requests and their resolvers so that tools like Apollo and perhaps even GraphiQL or others can make use of these standard extensions.

    While the spec is still young, having these metrics is pretty important for us, so we’ve introduced WPGraphQL Insights. It’s a plugin that adds tracing to your WPGraphQL server. The plugin is pretty early in development, so I wouldn’t suggest running it in production quite yet, but feel free to test it out on your local/dev environments and provide any feedback on the Github repo so we can make it better!

    The near-future plans for the WPGraphQL Insights plugin are:

    • add the ability for the server to enable/disable tracing
      • add a settings page
      • define via a constant, ex: define( ‘GRAPHQL_TRACING’, true );
    • allow the client to request tracing in the response (see this discussion)
    • provide storage options for the trace data
      • We’re working with the Apollo Optics team to figure out how we can get the trace data from a WPGraphQL server into Optics
      • We’re experimenting with storing trace data locally in WordPress to some degree
      • We’re experimenting with sending the data elsewhere, like logstash/elasticsearch.

    Here’s a look at tracing in action on WPGraphQL. Enjoy!