Native MongoDB to Sequelize with PostgreSQL

John Boardman Databases, Heroku, MongoDB, PostrgreSQL Leave a Comment

Every long-term project will outlive at least some of the technologies it was originally built with. For example, a project I have been involved with recently ran into this situation. The app is hosted on Heroku, and over the years, the available MongoDB add-ons have changed and dwindled until now, there is only one.

Several migrations between MongoDB add-ons have already happened because of shutdowns. So, it was decided that rather than migrating to the last one still in existence, the project would switch to using PostgreSQL, which is supported directly by the Heroku team.

Utilizing Spring Batch for Large Dataset Summarization

Clayton Neff Databases, Java, Spring, Spring Batch Leave a Comment

I was recently tasked with summarizing the data of a several-million-row table, and the task proved to be a bit grueling at first. Eventually, I found a way to summarize the large dataset with Spring Batch, but not without a wrong turn or two at first. In this post, I’ll walk you through my process and how I overcame this …

Go To SQL

Gabe Schmidt Databases, Go, Programming, Tutorial Leave a Comment

In between projects here at Keyhole, I’ve been tasked with applying a relational database access and mapping framework in the Go language.

In this post, I go step by step to create a Postgres relational database, then perform CRUD operations against it in the Go language.

I won’t get into the specifics of configuring Go in this blog, but you can check it out yourself here – https://golang.org/. Additionally, Keyhole’s very own David Pitt wrote an excellent primer on the subject here – https://keyholesoftware.com/2019/09/26/go-on-the-fly/.

Generate Strongly Typed React Components with GraphQL

Mat Warger AWS, Development Technology, GraphQL, JavaScript, Programming 1 Comment

When developing in React, using a type system (like Typescript or Flow) can be a great help. You can be sure that your props and state are what you expect, at build-time, and code your components to match.

But what happens when you’re calling to an API to fetch some data, and the shape of that data is what really matters? Maybe the data get passed as props to a child component? You can create types for this, sure, but are they correct? Probably not! Or at least, probably not for long! Things change. Wouldn’t it be great if your types changed too?

In this post, we’re going to take a simple component from zero type awareness to fully typed, with local variables and GraphQL queries included, with a simple workflow. Grab a cup of coffee and a snack, and let’s see how this we can use GraphQL to generate type-safe components in React.