Book review Patterns of Distributed Systems which ones NunDB uses

In software Naming things is hard, and a pattern is giving a problem a name, I love the quote from the book, “A Pattern Language” “Each pattern describes a problem which occurs over and over again in our environment, and then describes the core of the solution to that problem, in such a way that you can use this solution a million times over, without ever doing it the same way twice.” Christopher Alexander.

Read More

NunDb is now referenced in the Database of Databases

Last week, I was surprised by an email from Andy Pavlo (Associate Professor with Indefinite Tenure in Databaseology in the Computer Science Department at Carnegie Mellon University) asking me for an SVG logo and what is the official name of NunDB because he had included it in the Database of Databases. I responded to the email 9 minutes later and in a few more minutes. It was a mix of joy and pride.

Read More

Book review: Feel-Good Productivity

I first heard about this book from a famous YouTuber, whose content I love to watch. The book, recently published by him, seemed like an interesting read for the beginning of the year.

Read More

Secrets for becoming a better developer in 2024

Welcome to my yearly post about how to become a better developer; here, I share what I have learned in my last 16 years working as a Software Engineer and what I do to make myself more productive in my full-time job as a Principal Architect in a fast-growing American Startup, running my own SaaS business serving over 6k users monthly, teaching in-person Data Structures at the FasF Faculty (in Brazil) and working on my Open Source project Nun-db in my free time, I have to learn how to do things efficiently and that is what I share in this post yearly.

Read More

Nun-db Chaos Testing with Docker and Toxiproxy

I was writing my annual post about how to become a better developer, and I wanted to add a topic about dealing with latency and how to test latency problems in local and dev environments. When I found a bug in Nun-db where, under high latency, two servers could be in the same cluster and consider themselves the primary.

Read More

Real-time Medical Image Collaboration POC Made Easy with OHIF and Nun-db

Remotely controlling medical imaging visualization enables many use cases; for example, in education, the professor can ask all students to open the same study and manipulate the image from their computers at the lab, and all students can see it reflected immediately on their screens. Or, for example, in collaboration between two doctors while analyzing a patient case.

Read More

How to create users with different permission levels in Nun-db

We have recently taken an important step towards pushing Nun-db into mainstream use cases. Now, assigning multiple users to a single database and defining different permission levels for each is possible. In this tutorial, we will walk you through the process of creating two different users, one to be used by the front end of your application and one to be used by the back end.

Read More

Book Review: Efficient Linux at the Command Line

The book Efficient Linux at the Command Line was a relieving reading. I was already sold on the idea of the command line, and when I heard about this book, it took my attention immediately; I read the book without any hope of learning anything new, but hoping I could learn at least one new trick. I learned things that significantly improved my productivity, including the CDPATH, and now I cannot imagine how I lived so long without it.

Read More

Match vs Hashmap! Which one is faster in rust?

TLRD

In my case, the match was faster, with a median of 114.70 ns, while the Hashmap had a median of 123.43 ns. Nevertheless, I decided to move on with my Hashmap implementation. If you want to understand a bit more about my experiment, let’s dive a bit deeper.

Read More

Towards a More Secure Nun-db: Our Latest Security Enhancements

The initial focus on Nun-db was to be fast and easy to use, then we moved to make it infinitely scalable and to deal with data conflicts as a first-class citizen, bringing even a few offline capabilities. Now it is time to think a bit about Security; up to this point, it has not been the focus. Security will probably drive the next six months of updates to Nun-db core, and the goal is to make it more suitable for production apps out of my control. While I will be writing examples of how to use Nun-db, my goal is to secure the database.

Read More

Book review / personal notes - Distributed Tracing in Practice: Instrumenting, Analyzing, and Debugging Microservices

This book was a recommendation from a very senior close friend, which is why I started reading it. At the beginning of the book, I was in the middle of implementing distributed tracing for the customer I was consulting for, and it gave me rich and practical information on the implementation, such as the information I might like to store on the traces and the drawbacks from tracing all or sampling requests.

Read More

How to Succeed When Your Gut Tells You a Project Is Going to Fail as a Developer?

“We are rushing too much, we will miss many details, this will not end up well”. These were my words to the director on a project we were rushing to deliver. The odd part is that in times like that, working 10 hours a day, on weekends late at night and earlier in the morning. You may try to predict what will go wrong, but I guarantee you won’t be able to cover all details needed when running that much.

Read More

Book review The 5AM Club

This book has been recommended to me many times, yet I never wanted to read it because I was already sold out on the idea of waking up earlier. I have been waking up at 5 am for at least four years now since I started my master’s degree while working on a fast-growing startup and had a much bigger load than I could handle. So I decided to read to book to rest a bit from a few complicated and slow technical books I am reading. I did learn a few lessons from the book that made the reading worth it.

Read More

Keepin up with Nun-db 2023

2022 was the year to change directions on NunDB. After driving some adoption in 2021, I decided to shift NunDB to be leaderless (Not depend on a single primary node to operate) to be more aligned with my goals of a never-down service. That cost us a lot of time invested in research and coding. Nevertheless, it was a fantastic year with lots of internal improvements, consolidation, and learning.

Read More

My thoughts on local first software

In 2008 when I started working in what would become my SaaS company, one of the major concerns of my customers was if E-belle (my product) would work offline. The Internet was not great in brazil, and mobile networks were slow and expensive, making them not trust they would have their data when needed. I did many unsuccessfully POCs to make that a reality and needed to come up with many alternatives to convince my customers it would be safe to use a pure web product.

Read More

My Path to Become a Principal Software Engineer

A few days ago, I was promoted to Principal Software Engineer, it has been a while since I decided to get that title, so I decided to briefly describe my path for that in this blog post. If you are considering becoming a principal soon or moving to management as a side track, this post is for you. This is a more personal post, if you are looking for tips and tricks on becoming a better engineer. I recommend you to read my series of Secrets I use to become a better developer in 2019,or 2020 where you gonna find many of them. If you want to read more about my career, hang around.

Read More

Book review the power of habit

Many people recommended me this book, yet it took me a long time to read it because I was already convinced that good habits are the way to win in life. I thought it would be a waste of time. I only decided to read because I was procrastinating to finish other more complex books and wanted something easier to read. What a great surprise this book was, I learned so much from it.

Read More

The new storage engine of Nun-db

When I started Nun-db, I intended it to be an in-memory database for several reasons. For obvious reasons, I eventually needed to snapshot it to the database to disk. At that time, I decided not to spend too much time thinking ho how the data would be on disk. Therefore, I decided to use a serialization lib and move on with my coding with the more important stuff at the time. I used the lib bincode that did a good job at the time and took less than 2 hours to implement. I knew the time to write my own serialization structure and disk storage would come eventually. Well, that time is now.

Read More

My favorite metric as a small tech business owner

I don’t write about my company very often. I work only about 4 hours a week on it, so I don’t have much to share. This Sunday, as I was reviewing the annual metrics for my SaaS, I felt like sharing the one metric I like the most.

Read More

An approach to hunt and fix non-reproducible bugs - Case study - Fixing a race conditions in Nun-db replication algorithm in rust

This is the story behind the fix of one race condition in Nun-db. In this post, I went over the process to find the race condition by eliminating two initial theories and finally identifying the root cause, fixing it, and validating the fix. If you only want to see the results go straight to 3. Third and correct theory: Are nodes acknowledging messages before they are registered as pending?

Read More

NunDB the debug command

In this blog post, I document the decision to create a command called Debug to Nun-db. As we scale on usage and features, more complex problems are showing up, and it is about time to start adding features that will help manage Nun-db as Database administrators. If you unintentionally got to this post and want to read more about Nun-db, go to Github repository will be much richer information about the Database. The rest of this post will be focused on people familiar with Nun-db code.

Read More

Keeping up with Nun-db 2021

This was an excellent year for Nun-db; at first, I thought it would take me a lot of time to get some adoption and bring external users to use it, but it was super quick.

Read More

Book review Working in Public The Making and Maintenance of Open Source Software

Working in Public is an excellent book, in my opinion, but I am unsure who I would recommend reading blindly. If you are doing open source, I am sure it will be a great source of inspiration and information. It would also be an excellent reference for people out of open-source to learn how we operate in the software industry since it is hard to explain why super-smart people work thousands of hours for free to give the result of their work for free work well to everyone.

Read More

Writing a prometheus exporter in rust from idea to grafana chart

In this post, I will show my thought process to get the Nun-db Prometheus exporter from idea to POC to repository to the final Grafana chart. I have used Prometheus for a long time, but I never took the time to understand how the exporters work in deep. So it seemed the obvious choice when I started to look for an alternative to improving Nun-db observability. Observability is a must-have for infrastructure components like Nun-db, and I want to make sure we will monitor what we need to make it successful.

Read More

Integration tests in rust a multi-process test example

Testing is essential for developing good software. It is hard to keep speed and quality on software development without having a great test suite. I particularly like all levels of tests, and I think they are all vital, from the unit test, integration, to end-to-end tests. Each will run faster or slower than the other and cover a more significant part of the stack.

Read More

Book review Staff Engineer Leadership Beyond the Management Track

Staff Engineer Leadership Beyond the Management is the first book I read in years that a friend did not recommend. It initially got my attention because of the title in an auto recommendation from amazon. I decided to buy it as soon as I see it included an interview with Damian Schenkelman (I met him some years ago at an event in Brazil, and he seemed to be a great engineer, in the worst case, I would get some updates about his career).

Read More

Book review Traction Get A Grip On Your Business

Overall I think the book is direct and practical. I felt like reading a programming language book with lots of “Howtos,” except that it is about management and business. The 4th Chapter, The people’s content, got my attention especially. It does build an exciting framework to find the right people. The author highlights a few characteristics that seem to identify great professionals, to list the ones that got my attention, “

  • Unequivocal excellence
  • Honesty and integrity
  • Hungry for achievement
  • Is enthusiastic
  • energetic” (Read the book for the complete list, I liked all of them)
Read More

Book review Designing Data-Intensive Applications The Big Ideas Behind Reliable, Scalable, and Maintainable Systems

The book was by far the most useful, inside a full book I read in the last year or so. It may be because I am have been working on Nun-db (a real-time database), but I think I would have liked it just as much in the past as well. First of all, the book has been recommended to me by a friend that the opinion I respect a lot (A Ph.D. in Computer Science), the title immediately caught my attention and I have been reading it since the day I put it on my kindle.

Read More

A fast-to-sync/search and space-optimized replication algorithm written in rust, The Nun-db data replication model

I have been working on Nun-db as a side project for over two years. Finally, in June 2020, I got it running as the unique real-time database for my main application. In the post, I shared that milestone. Since then, a couple of other applications have been starting using Nun-db, e.g., a chatbot, a real-time visitor for my blog, a house price scraper, a tic tac toe multiplayer, etc.

Read More

NunDb How to backup one or all databases

NunDB is an in-memory database that means we store all the data mainly in memory for speed (this helps keep NunDb fast). The obvious drawback is that if you are hosting your own NunDb and you have a server restart or need to stop it for any reason, you may lose what is in memory.

Read More

When pure agile is falling apart, Shape Up might be the way to go

Last year, I started working as one of the tech leaders on a performance optimization project for one of my employer’s customers. At first, the team started using a regular Kanban process, so an engineer would pick some part of the code to optimize and work on until we felt good about the improvement. To me, it felt not to be the right approach to the problems we were trying to solve.

Read More

How to create your simple version of google analytics real-time using Nun-db

One of the features I like the most about Google Analytics is the real-time user track. Randomly during my day, I visit the real-time analytics of all products I run to see how many people my work is impacting at that time. It gives me the energy to see my work affecting other people. On the other hand, there are some drawn backs of using google analytics, to name a few:

  • Technical user may block google analytics to avoid been tracked (and you will not see that traffic in your tool)
  • You are giving data to google for free just to use a simple feature that may not be worth paying for at all. Or maybe you won’t even use most of it’s features.
Read More

Book review Atomic Habits

The book Atomic Habits is a classic and a consensus among productivity and self-improvement actors (Youtubers, influences, writers, etc.). It did not introduce any new profound concept I have never seen in some other source. On the other hand, the author outstandingly exposes the ideas behind acquiring new habits. The idea of driving your habits in the direction of the future version of what you want to become is not evident in other books, and it proves to be a good idea.

Read More

Migrating a chat bot feature from Firebase to Nun-db

A group of friends and I maintain a telegram group to talk about investing. A few years ago, we developed a chatbot to search for some stock prices once we post the stock’s name. The bot is quite simple and makes it fun since you don’t need to google or any other platform to see the price of the stock you want to check (Check out the image one of me getting the price of bitcoin).

Read More

Book review Adopting Elixir From Concept to Production

Adopting Elixir: From Concept to Production is an excellent book about adopting new technologies. I would recommend it to anyone who plans to migrate a legacy system to any new technology, not only Elixir, manly the initial character that contains extensive insides about approaching the migration.

Read More

Keepin' up with NunDB

It has been a year since I open-sourced NunDB. That happened when https://www.teknisa.com invited me to give a talk about real-time processing. At that time, I worked on NunDB for over six months, and I thought it would be an excellent opportunity to announce the project. It was called “Freira-DB” back then, and the goal of this post is to update the NunDB and what has happened during this one year.

Read More

Secrets I use to becoming a better remote developer

I have been working as a remote developer fulltime, for the last five years. Part-time/freelancing for at least ten years, over this time, I have collected several tips and tricks on how to become better at it and how to succeed and deliver results under this environment. I am writing this post to share some of these tricks, while this is a brief list. I am always testing these things. I thought it would be useful to do this one and periodically create a new one to share some updates.

Read More

Going live with NunDB

I needed a realtime database for two personal projects I was working, a time tracker (not public yet ) and http://ebelle.vilarika.com.br, the natural decision would be to use something like Firebase, but I was looking for a light open-source alternative turns out I did not found one as simple as I wished, so I decided to build one. My needs were simple, I need my frontend to be updated whenever the data change in the backend (And I do not want to implement a new WebSocket for each of my application). Here I will not give many details about how I build NunDB. You can read it [not public yet], but I will focus on how I went to production with it for my project Ebelle.

Read More

Making the react + redux + redux-saga development more fun and productive and less repetitive and verbose.

I have recently been working on and delivering some projects using pure react and react + redux, and it seemed like something was missing that would make working with them more reliable. Early last year, I started learning new front-end architectures using react to a POC for one of my customers. I came across the combination react + redux + redux-saga, which felt pretty healthy to me as the right solution for lots of problems I had faced in recent projects. Since then, I have wanted to try the combination in a real-world project to see if it scales or not. The opportunity came early this year when I needed to create a new mobile UI for one of my personal SAS solutions, so I decided to give it a shot. After developing the first set of features, I found myself doing a lot of repetitive work that delivered few new features or improvements.

Read More

Are you working remotely? You should be ready to hit the road at any time

One of the most significant advantages of working remotely is choosing how and where you work. That is what makes a big difference from a person working in an office. On the other hand, sometimes, you feel you have no focus or unproductive working on your home-office. The simple fact to go somewhere else will make you be much more productive and get your attention back. That happens because novelty produces dopamine, and dopamine increases focus.

Read More

Productivity Trackers I use (as a developer working remote)

I have been working remotely full time the last 2 years, since I join Tenfold (https://www.tenfold.com/), almost at the same time I was starting to work toward a master’s degree in Computer Since(You can see some info about my research here). Those are two demanding activities I have to deal with on a daily bases. To achieve my goals on both I have been testing myself on all the ways possible, on how to be more productive in these last two year, and this is the first of a group of articles about what I have learned an tested and what has worked or not.

Read More