May 11, 2024

Tinkering With Ktor 3: Practical uses of Ktor's plugin system

Summary Ktor isn’t just a small and snappy framework, it features a simple, yet effective plugin system to extend the framework to your heart’s content. My team uses this feature extensively, and I’ve used it in several of my side projects. Let’s play with a few example and see what we can do. Simple example Let’s say, we want to see how long does it take for server to process a request until it responds. Read more

March 30, 2024

Tinkering With Ktor 2: Using HTML DSL for page templates

Photo by Pankaj Patel on Unsplash Summary There are a bunch of templating engines available for Ktor, each one with its own strengths and weaknesses. But, I don’t like that I have to add yet another engine to the runtime (especially when I plan to run React or Vue anyway) so why not try using a simple feature of Kotlin to build our html? Kotlin DSL (Domain Specific Language) capabilities, while having a steep learning curve if you never used them before can be used structures that closely mimic html. Read more

January 7, 2024

Tinkering With Ktor: Setting up a simple server with Docker

Summary After doing a few small projects on Android, I’ve come to enjoy Kotlin’s convenient syntax that strikes a beautiful balance between functional and imperative programming. After doing some research, it looks like Kotlin has been gaining popularity on the server-side as well and for good reasons, it’s so darn productive. I’ll be doing a small series of posts on how to use Ktor framework, for my own learning and hopefully for yours as well :) Read more

August 23, 2020

Go Interview Question #3 - Write a function that checks if brackets are balanced

Another very common interview question, is to check if brackets are balanced in a string. If you have never done any stack questions before, this can be tricky. But, once you see how a stack can be used, it becomes very straightforward. Let’s look at what balanced brackets look like: “(())()”, “((()))”, “()”… Unbalanced brackets: “(((”, “())”, “(()”… A stack is like a can of Pringles, the last chip that was put into it, is the first to come out. Read more

July 4, 2020

I'm a self taught developer, which websites did I use to learn

Looking back, it would of probably been better if I got my Computer Science degree instead of Mathematics. At the very least, it would have made the first few years of my career a whole lot easier. That is one way of looking at it, but would I be a better developer if I had it easier? That is hard to say. But, all those experiences have made me who I am today, and I am happy with where I ended up. Read more

June 25, 2020

Upgrading Razer Blade 15 (Early 2019) RAM SSD

Why? I decided to upgrade my laptop memory this year. While my coding work rarely pushes memory usage above 75%, I recently started doing a lot of Lightroom editing and occasionally video editing as well. I noticed that I was frequently using 15 of 16 GB of memory and I decided to bump it up to 32 gigs. I also heard that the next generation of SSD is coming out soon and will not be compatible with the interface this laptop is using so I decided to ugprade, the storage on the laptop was well to 1TB. Read more

June 4, 2020

Automate Open Tabs in Cmder

I have been using Cmder for about a year now, it’s an excellent console emulator for Windows based on ConEmu emulator, but with a few bells and whistles thrown in. I got it mainly for the tabs and split screen features (which ConEmu also supports), but Cmder looks cooler and has Git support out of the box. At work I like to have git for front-end open on the left side and git for back-end open on the right side; then I have another tab open for yarn commands. Read more

May 16, 2020

Go Interview Question #2 - Write a function to check if a string is a palindrome

This question is very common on interviews, and while fairly straightforward, plenty developers mess it up on the interview. What is a palindrome? Webster dictionary defines it as a word, sentence or number that reads the same forwards and backwards. Some examples are: dad, 1881, abba. There are a few approaches to solving this problem, we can reverse the array of characters and compare the resulting string for example. The more efficient way of doing this is to compare the characters from the beginning and from the end one-by-one. Read more

May 6, 2020

Go Interview Question #1 - Find all the prime numbers less than or equal to 'n'

As a means of keeping my logic sharp and helping others prepare for Go interviews I decided to release a solved interview question every week or so. In this post, let’s write a function in Go that generates us all the primes at or below a specific integer. To even attempt this question, we need to know the exact definition of a prime number. According to Wolfram, A prime number is a positive integer p>1 that has no positive integer divisors other than 1 and p itself. Read more

April 15, 2020

Chunked File Upload using TypeScript, React, and Go

Why you may want to chunk files? The biggest reason for me to upload files in chunks, is because I want to upload very large files; pictures, videos, whatever… This means, I want to know the status of the upload as it progresses and if I can’t finish the upload now, I want to be able to pause, go to my favourite coffee shop and continue on there. Let’s build a simple app using no additional javascript libraries! Read more

© Ilya Nemtsev 2019

Powered by Hugo.