The Best Collected Details on the GraphQL Specification – Overview & Language

GraphQL, a query language and execution engine is described in this specification based on capabilities and requirements of data models for client-server applications. This article details and elaborates on the specification, the features and capabilities of GraphQL and implementations. I hope this collection of details around the GraphQL Specification can be used as a reference and launch point into learning about GraphQL use, implementation – server and client side – and ongoing references during future specification additions or changes!

Continue reading “The Best Collected Details on the GraphQL Specification – Overview & Language”

Apollo GraphQL Federation Schema Validation Error [Solved!]

This is the error I’ve bumped into while working through the example for Apollo’s GraphQL Federation when setting up a subgraph API. I’ve tried several things to resolve this error including changing versions for the GraphQL library in use but that hasn’t fixed it. I’ve also got this now on MacOS, Linux, and Windows so it isn’t something odd about the environment.

 ~/Codez/AppoloFederationCore-v2/ [main] node index.js
/Users/adronhall/Codez/AppoloFederationCore-v2/node_modules/apollo-graphql/lib/schema/buildSchemaFromSDL.js:50
        throw new GraphQLSchemaValidationError_1.GraphQLSchemaValidationError(errors);
        ^

GraphQLSchemaValidationError: Unknown directive "@entity".
    at buildSchemaFromSDL (/Users/adronhall/Codez/AppoloFederationCore-v2/node_modules/apollo-graphql/lib/schema/buildSchemaFromSDL.js:50:15)
    at buildSubgraphSchema (/Users/adronhall/Codez/AppoloFederationCore-v2/node_modules/@apollo/subgraph/dist/buildSubgraphSchema.js:26:58)
    at Object.<anonymous> (/Users/adronhall/Codez/AppoloFederationCore-v2/index.js:29:11)
    at Module._compile (node:internal/modules/cjs/loader:1095:14)
    at Object.Module._extensions..js (node:internal/modules/cjs/loader:1124:10)
    at Module.load (node:internal/modules/cjs/loader:975:32)
    at Function.Module._load (node:internal/modules/cjs/loader:816:12)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:79:12)
    at node:internal/main/run_main_module:17:47 {
  errors: [
    GraphQLError [Object]: Unknown directive "@entity".
        at Object.Directive (/Users/adronhall/Codez/AppoloFederationCore-v2/node_modules/graphql/validation/rules/KnownDirectivesRule.js:56:29)
        at Object.enter (/Users/adronhall/Codez/AppoloFederationCore-v2/node_modules/graphql/language/visitor.js:323:29)
        at visit (/Users/adronhall/Codez/AppoloFederationCore-v2/node_modules/graphql/language/visitor.js:243:26)
        at Object.validateSDL (/Users/adronhall/Codez/AppoloFederationCore-v2/node_modules/graphql/validation/validate.js:92:22)
        at buildSchemaFromSDL (/Users/adronhall/Codez/AppoloFederationCore-v2/node_modules/apollo-graphql/lib/schema/buildSchemaFromSDL.js:48:31)
        at buildSubgraphSchema (/Users/adronhall/Codez/AppoloFederationCore-v2/node_modules/@apollo/subgraph/dist/buildSubgraphSchema.js:26:58)
        at Object.<anonymous> (/Users/adronhall/Codez/AppoloFederationCore-v2/index.js:29:11)
        at Module._compile (node:internal/modules/cjs/loader:1095:14)
        at Object.Module._extensions..js (node:internal/modules/cjs/loader:1124:10)
        at Module.load (node:internal/modules/cjs/loader:975:32)
  ]
}
Continue reading “Apollo GraphQL Federation Schema Validation Error [Solved!]”

AWS Amplify Release, GraphQL, and Recent Curated Links

This release kicked off this week in time for re:Invent and I put together a quick write up. Any questions, feel free to ping me via my contact form or better yet, just pop a question at me via the Twitters @Adron.

Continue reading “AWS Amplify Release, GraphQL, and Recent Curated Links”

I Joined AWS, It’s Surreal, and Why

TLDR I joined Amazon Web Services on the 11th of October – i.e. AWS – and it rocks.

When you join Amazon you are signing up to learn a lot of things about the company and the ways in which the company gets things done. Before I get into all that, I’m going to tell you a bit about my career and what led me to Amazon. After all, it is surreal and unexpected for many that know me that I’m here. This relationship has definitely been a 2-way story, and one where it finally fit in a mutually beneficial way.

Continue reading “I Joined AWS, It’s Surreal, and Why”

My Bespoke JetBrains Toolbox Configuration

One thing I do just enough to remember I need to do, but not frequently enough to remember which settings are which, is installing the JetBrains Toolbox app to get the other JetBrains’ software installed.

The following is the quick list of the key things that I setup to get the most out of Toolbox. This is a quick process and I’ve detailed it here, one for memory, but also to detail what some of the features provide so this might be of more use to others.

The Toolbox Settings options are located by clicking on the gear icon when the application is opened up. This is the same across operating systems; Windows, Ubuntu, MacOS, or others. Find the gear, click it!

Once Settings are opened up the core 4 configurations include:

  1. If you’ve got an account, login. Everything is easier if you’re logged into your account.
  2. This second option around the theme is great on MacOS and Ubuntu. I’m not sure what it does on Windows exactly, but presume a similar effect. I myself set this to Auto since I always set the OS level theme to dark and love that almost all the apps that I use shift to that theme.
  1. I don’t set a shortcut for the toolbox, I simply use the Ctrl+Space to launch it from the spotlight on MacOS and use whatever option to issue apps from command on Windows and Linux OS installations of Toolbox.
  2. This section, I’ll detail further down, has a host of additional settings around the tools use itself.

When logging into the app, the Toolbox will launch a browser to complete the process. The ! is what I do, log in with a regular JetBrains username and password based account versus using one of the Oauth options like Github. I feel like, however, maybe I should check if I can switch it or add the Github auth to use that, I am a fan of using it as my general dev auth across systems.

Upon logging in and clicking Approve the prompt to open and then match the Toolbox extension for opening to the Toolbox application in the browser.

Once all that is setup, my next move is to get the Tools section updated and setup the update behaviors, reload setting, and shell scripts.

  1. I toggle the Update Toolbox App automatically option on.
  2. I also, cuz I’m such a nice person, send the anonymous usage statistics to JetBrains.
  3. For the Update all tools automatically I often toggle this on. As in the vast majority of scenarios I’m working in, I need to ensure I have the latest patches and updates.
  4. The Keep only the latest version is similar to #3 where as, I generally only want one version of the particular IDE, I don’t particularly need the EAP or previous versions, and I toggle this to keep only the latest version that is currently available.
  5. I leave the Reload Dock after update option toggled on.
  6. This last feature is one of the most important for me. I launch most of the IDEs, JetBrains or others, vai the terminal. My most used method is to issue the ide . so that the IDE opens the particular directory that the prompt is located in. This section, the Generate shell scripts enables this for all of the respective IDEs that are installed per the Toolbox App.
  1. This is diving into, once the Generate shell scripts is toggled on.
  2. The Shell scripts location, I’d argue, should be set to your /usr/local or some system directory so that it’s available specifically for you, or if multiple users use the machine that use all the apps, it’s available prospectively for everybody. The fact is you can set it to whatever path you want, I’ve had some issues managing that autonomously of a directory like /usr/local that one just tends to end up with as part of one’s path on a machine. With that, I’d wrap this up with a strong suggestion to set it to /usr/local and call it a day.

An important thing to note about this path, whatever is selected has to be the path and the permissions must allow the creation of the actual files once apply is clicked. Whichever IDEs are installed should show like this. If permissions or or something else prevents these from being created then another directory needs to be selected or the permissions changed or problems resolved.

At this point navigate to any directory and open the respective IDE by command or open the directory you’re located with ideaCmd . and the specific IDE will launch and open that particular directory.

That’s it for the Toolbox settings. I’ll end this article with a few suggestions on IDEs to install, pending you’re using an account that has the entire suite or you have multiple IDE subscriptions purchased. I would recommend, to install IntelliJ IDEA Ultimate regardless of what other IDEs you install. It’s a good option that has a little bit of every other IDE and has been the one (my understanding here) that was the original and thus, longest developed of all the options.

Then, if you’re focused on a particular language stack, then install the IDE that is available for that particular language. GoLand for Go, PyCharm for Python, Rider for .NET, and WebStorm for web related development. There are others, so choose as you develop. Of course, any of these can all be developed in the IntelliJ IDEA IDE but your mileage may vary if you go that route, I’d highly recommend using the IDE specific to the language stack.

Cheers, enjoy your thrashing code! 🤘🏻