MKMark Karamyarindevmarkpro.com·Jan 1, 2022 · 15 min readData Integration between databasesIn an event-driven architecture, one of the common scenarios, when we are facing a monolith application, is how to get a huge amount of data out of the monolith database. This task became even more complicated when we have to take the stability and u...01S
MKMark Karamyarindevmarkpro.com·Mar 17, 2021 · 3 min readGeneric in GolangThis year started with new news from the golang team, "Adding Generic!". If you have familiar with languages like Java or C#, you already familiar with the concept of Generics. For example, let's talk about sorting an array. package main import ( ...00
MKMark Karamyarindevmarkpro.com·Mar 13, 2021 · 8 min readWorking with big files in golangToday, I am going to show you how to read files in golang line-by-line. Let's imagine that have a jsonl file. What's jsonl? it's json lines in a simple term, it's a file that each line of it represents a valid json object. So if we read the file line...02JZ
MKMark Karamyarindevmarkpro.com·Mar 11, 2021 · 2 min readHow to embed the content of a file to a variable in GolangIn this article, we were talking about how to deal with a large file in Golang. But have you ever seen yourself in a situation that just wanted to read a file and load its entire content to a variable and work with it? I have been in the same situati...00
MKMark Karamyarindevmarkpro.com·Jan 11, 2021 · 4 min readError handling in goroutines with errgroupGolang made life easier with goroutine, however, sometimes it's difficult to handle errors that happened inside a goroutine effectively. For example, imagine you have an array of some kind of actions and wanted to run a specific function on each one ...00