Distributed SQL Tricks and Tips – Jan 10, 2019
Welcome to this week’s community update where we recap a few interesting questions that have popped up in the last week or so on the YugabyteDB Slack channel, Forum, GitHub or Stackoverflow. We’ll also review upcoming events, new blogs and documentation.
What’s YugabyteDB? It is an open source, high-performance distributed SQL database built on a scalable and fault-tolerant design inspired by Google Spanner. Yugabyte’s SQL API (YSQL) is PostgreSQL wire compatible.
How do I connect to YugabyteDB from outside a Kubernetes cluster?
By default, the YugabyteDB Helm will expose only the master UI endpoint using LoadBalancer. If you want to expose YSQL and YCQL services using LoadBalancer for your app to use, you’ll need to use the expose-all.yaml files.
To connect an external program, get the load balancer IP address of the corresponding service. The example below shows how to do this for the YSQL and YCQL services.
$ kubectl get services --all-namespaces NAMESPACE NAME TYPE CLUSTER-IP E XTERNAL-IP PORT(S) AGE ... yb-demo yql-service LoadBalancer 10.47.249.27 35.225.153.213 9042:30940/TCP 2m yb-demo ysql-service LoadBalancer 10.106.28.246 35.225.153.214 5433:30790/TCP 2m ...
For more information on how to deploy and manage YugabyteDB on Kubernetes, check out:
https://docs.yugabyte.com/latest/deploy/kubernetes/helm-chart/#connect-using-external-clients
Does YugabyteDB support user-defined PostgreSQL functions?
Yes, YugabyteDB supports both table functions and functions in general. For more info check out:
https://docs.yugabyte.com/latest/api/ysql/commands/ddl_create_function/#grammar and a three part series on table functions:
- An Introduction to PostgreSQL Table Functions in YugabyteDB
- Implementing PostgreSQL User-Defined Table Functions in YugabyteDB
- Four Compelling Use Cases for PostgreSQL Table Functions
How does YugabyteDB generate its performance graphs?
The metrics for each YugabyteDB node are exported in Prometheus format. In our blog post we’re using the same metrics and graphs from Yugabyte Platform which ships with a full-fledged monitoring solution powered by a built-in Prometheus server.
For more information concerning Prometheus and YugabyteDB integration, check out:
https://docs.yugabyte.com/latest/explore/observability/
How can I change the number of tablets after my tables have been created?
Currently, you must specify tablet counts for tables during the CREATE TABLE statement. We’re actively working on automatically splitting tablets and should be available in our upcoming 2.1 release.
You can track the progress of this GitHub issue here:
https://github.com/yugabyte/yugabyte-db/issues/1004
New Documentation, Blogs, Tutorials, and Videos
New Blogs
- An Introduction to PostgreSQL Table Functions in YugabteDB – Part 1
- Implementing PostgreSQL User-Defined Table Functions in YugabyteDB – Part 2
- Four Compelling Use Cases for PostgreSQL Table Functions – Part 3
- Announcing the Kafka Connect YugabyteDB Sink Connector
- Getting Started with DbSchema on a Distributed SQL Database
New Videos
- YugabyteDb Operational Best Practices
- Getting Started with Local Installs, Sample Databases and Tools
- Getting Started with PostgreSQL’s Authentication and Authorization
- Getting Started with PostgreSQL’s Row-Level Security
- Designing a Change Data Capture and Two Data Center Architecture for a Distributed SQL Database
- Distributed Databases Deconstructed: CockroachDB, TiDB and YugabyteDB
- We have uploaded over a dozen videos from this year’s Distributed SQL Summit. You can links to the presentations, slides and a recap of the highlights by checking out, “2019 Distributed SQL Summit Recap and Highlights.”
New and Updated Docs
- ysqlsh
- ysql_dump
- ysql_dumpall
- yugabytedb
- Backup and Restore
- Restore Data
- YugabyteDB JDBC Driver
- Spring Data for YugabyteDB
- Kafka Connect YugabyteDB
Upcoming Meetups and Conferences
PostgreSQL Meetups
- Feb 20: Silicon Valley PostgreSQL Meetup
Distributed SQL Webinars
We are Hiring!
YugaByte is growing fast and we’d like you to help us keep the momentum going! Check out our currently open positions:
- Software Engineer – Cloud Infrastructure – Sunnyvale, CA
- Software Engineer – Core Database – Sunnyvale, CA
- Software Engineer – Full Stack – Sunnyvale, CA
- Developer Advocate – Sunnyvale, CA
- Senior Technical Writer – Remote
Our team consists of domain experts from leading software companies such as Facebook, Oracle, Nutanix, Google and LinkedIn. We have come a long way in a short time but we cannot rest on our past accomplishments. We need your ideas and skills to make us better at every function that is necessary to create the next great software company. All while having tons of fun and blazing new trails!
Get Started
Ready to start exploring YugabyteDB features? Getting up and running locally on your laptop is fast. Visit our quickstart page to get started.
What’s Next?
- Compare YugabyteDB in depth to databases like CockroachDB, Google Cloud Spanner and MongoDB.
- Get started with YugabyteDB on macOS, Linux, Docker, and Kubernetes.
- Contact us to learn more about licensing, pricing or to schedule a technical overview.