Controller Request Mapping in Golang

Background I’ve been developing web applications using Java and Spring Framework and in 2019, I started using Golang in some of my projects. So far my experience with Golang is great but I miss the annotation that Spring framework provides particularly the @RequestMapping for URL mapping, @Bean and @Autowired for dependency injection. Most of the […]

Continue Reading…

Two-letter country codes

Happy New Year! I hope you’re having a great time. Today, I am updating my online tool, ip.johnpili.com to use Cloudflare’s Request Header, “CF-IPCountry” so that I can display the IP address together with the country. I also want to have my own two-letter country code on my website as quick reference. The table below […]

Continue Reading…

IP Address Classes

The table below shows the IP address classes. This could be handy for someone trying to remember possible IP ranges of a particular IP class. The first 8 bits of the IP address are used to determine the class. Class Address Range No. of Network Hosts A 1-126.x.y.z 126 16,777,214 B 128-191.x.y.z 16,384 65,534 C […]

Continue Reading…

How to setup static IP address on Red Hat Enterprise Linux 8

Setting up a static IP address on your RHEL or CentOS is simple. Prerequisite This how-to guide requires that you have administrative access to the Linux operating system. Steps 1. Inside the RHEL Operating system, open the terminal and head to /etc/sysconfig/network-scripts cd /etc/sysconfig/network-scripts Using ls command, you can see the available network devices. 2. […]

Continue Reading…