Tag : postgresql

How to Connect to Cloud Foundry’s Databases

Photo by N. on Unsplash Whether you are using PCF, cf-deployment, or KubeCF, there is an easy pattern to connect to the underlying MySQL or PostgreSQL databases that works regardless of the secrets provider (CredHub, Vault, or Kubernetes secrets). Makes you feel a bit like a pirate, right? So, break out your sand shovels and

Chris Weibel Profile Image

Posted by:
Chris Weibel

Read More ➝
Debugging Slow BOSH Deployed PostgreSQL

Photo by Vincent van Zalinge on Unsplash Something is just not quite right, the CLI is sluggish and your senses are tingling that something is wrong. Is it the database? Maybe. How do you know? pgBadger is a nifty tool that reads through postgres logs and generates a report showing slow queries, table locks, DML

Chris Weibel Profile Image

Posted by:
Chris Weibel

Read More ➝
Where is PostgreSQL Getting That $%&^ing Configuration Parameter From?

​ Photo by Steve Smith on Unsplash Like a squirrel looking for a lost nut, finding where a configuration parameter is being set in PostgreSQL can be a pain in the (fluffy) tail. For example, the log_min_duration_statement which is used to configure the threshold duration of a query before it is logged can be set

Chris Weibel Profile Image

Posted by:
Chris Weibel

Read More ➝
Adding pgBadger to the PostgreSQL Helm Chart

pgBadger is a helpful tool which will generate reports and diagrams about the type and pattern of sql queries over time that are submitted to PostgreSQL. The tool works by reading the PostgreSQL logs (not transaction logs) which are not typically enabled by default in the helm chart. Below are a few methods for leveraging

Chris Weibel Profile Image

Posted by:
Chris Weibel

Read More ➝
Modifying the Default PostgreSQL Helm Chart to Emit Logging

Photo by Aleksandar Radovanovic on Unsplash While using the PostgreSQL Helm Chart I wanted to take a look at the queries which were running. I quickly realized I needed to enable the logging to see all the DML goodness to later feed into pgBadger to review the usage patterns of the queries. Below are three

Chris Weibel Profile Image

Posted by:
Chris Weibel

Read More ➝
Running the CrunchyData Postgres Operator on Minikube

Why are we interested in Postgres on Kubernetes? I gave a talk last week on beginning the journey to getting PostgreSQL running on Kubernetes at the Buffalo Web Developers Database Meetup. There were examples on a simple deployment, configuring stateful sets, adding persistent volume claims and even a liveness probe. What I wanted to show

Chris Weibel Profile Image

Posted by:
Chris Weibel

Read More ➝
Using Concourse CI to test your web app and PostgreSQL

A typical web application will need services, such as databases and caches, to run. It will probably also need these services to run its test suite. In this blog post, we will look at how to set up and run PostgreSQL within Concourse CI prior to running our application’s test suite. The Problem For a

Dr Nic Williams Profile Image

Posted by:
Dr Nic Williams

Read More ➝
Piping psql into jq

The modern hero of shell scripts is jq. Pipe in JSON, find values, store back into variables or create new JSON and work with that. Unfortunately my data was in PostgreSQL, and the psql output is not JSON. But it would be awesome if it was. Just imagine the power of psql -c ‘SELECT somecolumn

Dr Nic Williams Profile Image

Posted by:
Dr Nic Williams

Read More ➝
Try out PostgreSQL 9.5beta on Cloud Foundry

PostgreSQL 9.5 is coming and includes many new features, including the new UPSERT command, and JSONB-modifying operators and functions. For operators of Cloud Foundry, we’ve pushed out a new service broker release that allows you to offer PostgreSQL 9.5 beta to some of your users, even before the final 9.5 release. This service broker is

Dr Nic Williams Profile Image

Posted by:
Dr Nic Williams

Read More ➝