Run PostgreSQL Database With Docker

Running PostgreSQL with docker is very useful for testing purposes. You can run it everywhere. You can create any testing data, use it then destroy it after testing is done. Integration testing and automation testing are made easy by it.

[Read More]

Zero Downtime Reload With Socketmaster

Nowadays, zero downtime reload is mandatory for most systems. Especially for the system that is accessed all the time. Stakeholders demand the high availability of the system. So it is bad if the system needs downtime for reloads even if it’s in milliseconds. Socketmaster is there to help your system reload with zero downtime.

[Read More]

Handle Panic in HTTP Server by Using Middleware in Go

If you have code in Go, most likely you have ever encountered a panic. Panic can stop your application if it is not recovered. Fortunately, in the Go HTTP server, there is already a panic recovery, so the server will continue to run if panic is encountered. But the client will not get any response from the server if a panic happens. It is good that you have your own panic recovery that responds with an error message.

[Read More]

Wait for Goroutine to Finish With WaitGroup

Goroutine is very useful to execute a process asynchronously. You can use multiple goroutines to run multiple processes at the same time. But what if you want to wait for the goroutines to finish before continue to the next process? You can use WaitGroup to wait for goroutines to finish.

[Read More]
go 

NGINX Custom Error Response

If you use NGINX as a proxy, you may want to use a custom error response, because the default error response from NGINX is not pretty. Read this post to know how to use custom error responses in NGINX.

[Read More]

Enable WordPress HTTPS With AWS CloudFront

Why do you need to enable HTTPS for your WordPress site?

HTTPS secures your data transmitted in the network by encrypting it so that the intruder can’t see and tamper the data. It is important to protect your web with HTTPS, whether your web is big e-commerce or just a simple blog. This article will show you how to enable HTTPS for your WordPress site using Amazon CloudFront.

[Read More]

Go: You Should Know This Before Using Defer

Defer is one of my favorite things in Go. You can use it to make sure operation is executed before a function returns. It is very useful. I think almost all Go programmer, if not all, has used defer statement in their application. But there is one thing you should know before using defer in Go.

[Read More]
go 

NSQ: Requeue vs Requeue Without Backoff

NSQ enables us to requeue a message with a delay duration. There are two functions to requeue messages, that is Requeue and RequeueWithoutBackoff. This article will show you the differences and help you choose the most suitable function for your use case.

[Read More]
nsq  go