<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Denis Gerić, Author at ShiftMag</title>
	<atom:link href="https://shiftmag.dev/author/denis-geric/feed/" rel="self" type="application/rss+xml" />
	<link>https://shiftmag.dev/author/denis-geric/</link>
	<description>Insightful engineering content &#38; community</description>
	<lastBuildDate>Fri, 27 Sep 2024 09:50:26 +0000</lastBuildDate>
	<language>en-GB</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.0</generator>

<image>
	<url>https://shiftmag.dev/wp-content/uploads/2024/08/cropped-ShiftMag-favicon-32x32.png</url>
	<title>Denis Gerić, Author at ShiftMag</title>
	<link>https://shiftmag.dev/author/denis-geric/</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>From a feature to a problem &#8211; from a problem to an opportunity</title>
		<link>https://shiftmag.dev/from-a-feature-to-a-problem-from-a-problem-to-opportunity-3744/</link>
		
		<dc:creator><![CDATA[Denis Gerić]]></dc:creator>
		<pubDate>Thu, 25 Jul 2024 11:11:31 +0000</pubDate>
				<category><![CDATA[Signals]]></category>
		<category><![CDATA[fake OTP traffic]]></category>
		<category><![CDATA[HTTP]]></category>
		<category><![CDATA[Infobip Signals]]></category>
		<guid isPermaLink="false">https://shiftmag.dev/?p=3744</guid>

					<description><![CDATA[<p>Our feature for sending SMS to "Trusted MSISDNs" hit distribution snags in our microservices setup. This hiccup not only got us back on track but also sparked ideas for turbocharging our entire system.</p>
<p>The post <a href="https://shiftmag.dev/from-a-feature-to-a-problem-from-a-problem-to-opportunity-3744/">From a feature to a problem &#8211; from a problem to an opportunity</a> appeared first on <a href="https://shiftmag.dev">ShiftMag</a>.</p>
]]></description>
										<content:encoded><![CDATA[<figure class="wp-block-post-featured-image"><img fetchpriority="high" decoding="async" width="1050" height="551" src="https://shiftmag.dev/wp-content/uploads/2024/07/new-feature-development.png?x94846" class="attachment-post-thumbnail size-post-thumbnail wp-post-image" alt="" style="object-fit:cover;" srcset="https://shiftmag.dev/wp-content/uploads/2024/07/new-feature-development.png 1050w, https://shiftmag.dev/wp-content/uploads/2024/07/new-feature-development-300x157.png 300w, https://shiftmag.dev/wp-content/uploads/2024/07/new-feature-development-1024x537.png 1024w, https://shiftmag.dev/wp-content/uploads/2024/07/new-feature-development-768x403.png 768w" sizes="(max-width: 1050px) 100vw, 1050px" /></figure>


<p class="wp-block-paragraph">Houston, we have a problem!</p>



<p class="wp-block-paragraph">What the hell is going on?! <strong>Alerts started popping up everywhere</strong>, multiple services crashed and mass confusion arose between colleagues trying to pinpoint the center of the problem. </p>



<p class="wp-block-paragraph">This does not happen very often, and when it does, it usually involves a bigger problem that is out of our reach (Kafka problems, datacenter issues, etc.) and has nothing to do with our code, but this was not the case.</p>



<h2 class="wp-block-heading"><span id="let-me-present-you-the-feature"><strong>Let me present you the feature</strong></span></h2>



<p class="wp-block-paragraph">Our feature allowed our customers to import a <strong>large </strong><span style="box-sizing: border-box; margin: 0px; padding: 0px;"><strong>num</strong></span><strong>ber of mobile numbers and whitelist them,&nbsp;ensuring that the SMS that is sent to those numbers is not blocked at any moment,</strong> even if our analysis detected them as fraudulent. This ensured that traffic sent to those mobile numbers was always sent. We call these &#8220;Trusted MSISDNs&#8221;&nbsp;</p>



<p class="wp-block-paragraph">The problem was <strong>how we distributed those numbers to other services,</strong> which needed to be aware of this information.&nbsp;</p>



<h2 class="wp-block-heading">Our architecture wasn&#8217;t ready</h2>



<p class="wp-block-paragraph">Since we are working with microservice architecture<span style="box-sizing: border-box; margin: 0px; padding: 0px;">,&nbsp;<strong>we are using a configuration service to send configuration updates to other services using HTTP(RMI)</strong>. The configuration service also received information about Trusted MSISDNs, stored them in the database, and then sent them as&nbsp;</span>part of the configuration file to other services. This is where the problem started.&nbsp;</p>



<p class="wp-block-paragraph">We did not expect that a huge amount of Trusted MSISDNs would become a burden to our configuration file:&nbsp;</p>



<p class="wp-block-paragraph">1. <strong>Configuration files became much larger </strong>&#8211; resulting in HTTP timeouts&nbsp;&nbsp;&nbsp;</p>



<p class="wp-block-paragraph">2. <strong>Serialization and De-serialization took more time and used much more RAM&nbsp;</strong></p>



<p class="wp-block-paragraph">3. Configurations were stored in memory and updated often, resulting in being <strong>too big for our virtual machine&nbsp;</strong></p>



<p class="wp-block-paragraph"><span style="box-sizing: border-box; margin: 0px; padding: 0px;">As a result, when services tried to fetch configuration,&nbsp;<strong>they either had timeouts all the time,</strong>&nbsp;making them work with non-updated configuration,&nbsp;<strong>or they fetched configuration and crashed</strong>&nbsp;because not enough RAM was added to the service to handle de-serialization.</span>&nbsp;&nbsp;</p>



<h2 class="wp-block-heading"><span id="you-cannot-think-of-everything">You cannot think of everything</span></h2>



<p class="wp-block-paragraph"><span style="box-sizing: border-box; margin: 0px; padding: 0px;">This functionality was developed first as a proof of concept, and eventually,&nbsp;<strong>it was improved to the point where we used it in production</strong>.</span> We followed the architecture we already had, and it worked well without apparent problems.&nbsp;</p>



<p class="wp-block-paragraph">Millions of numbers were imported, the UI tested, and the feature was in production for many weeks. Sometimes, you can&#8217;t think of everything, and in our case, the estimation of imported numbers was not big enough—and we thought big.</p>



<p class="wp-block-paragraph">We recognized that as our product evolves, <strong>our architecture must also adapt</strong> to accommodate our expanding customer base. This functionality received more attention than we initially thought, and we needed to change our approach.</p>



<h2 class="wp-block-heading"><span id="solving-http-issues-and-optimizing-future-features">Solving HTTP issues and optimizing future features</span></h2>



<p class="wp-block-paragraph">We have moved from RMI and <strong>started using Kafka to resolve our HTTP(RMI) issues</strong>, and the in-memory configuration was switched to Redis as a fast-responding database.&nbsp;</p>



<p class="wp-block-paragraph">The problem that occurred opened our eyes and made us take the first step in changing how we handled configurations. It also changed how we think about future features, where we already took different approaches and where a huge amount of data does not represent a problem.</p>



<p class="wp-block-paragraph">This alert showed us a potentially big problem over time that could be much harder to handle if it came all at once. It was time for a change.</p>



<h2 class="wp-block-heading">Crisis &#8211; &gt; Opportunity</h2>



<p class="wp-block-paragraph"><span style="box-sizing: border-box; margin: 0px; padding: 0px;">Problems sometimes&nbsp;<strong>lead us to resolv</strong></span><strong>e more than one issue and tackle core problems.</strong> However, due to our busy schedules, these issues never get the spotlight.&nbsp;</p>



<p class="wp-block-paragraph">Sometimes, unforeseen challenges can drive significant improvements, transforming crises into opportunities. You never know. <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f642.png" alt="🙂" class="wp-smiley" style="height: 1em; max-height: 1em;" /> Maybe the problem you have today will make your life easier tomorrow.&nbsp;&nbsp;</p>



<p class="wp-block-paragraph">Embrace problems and good luck!</p>



<p class="wp-block-paragraph"><em>Find out more <span style="box-sizing: border-box; margin: 0px; padding: 0px;">a</span>bout&nbsp;<a href="https://www.infobip.com/developers/blog/how-to-fight-fake-otp-traffic-using-infobip-signals">how to combat fake OTP traffic</a>.</em></p>
<p>The post <a href="https://shiftmag.dev/from-a-feature-to-a-problem-from-a-problem-to-opportunity-3744/">From a feature to a problem &#8211; from a problem to an opportunity</a> appeared first on <a href="https://shiftmag.dev">ShiftMag</a>.</p>
]]></content:encoded>
					
		
		
			</item>
	</channel>
</rss>

<!--
Performance optimized by W3 Total Cache. Learn more: https://www.boldgrid.com/w3-total-cache/?utm_source=w3tc&utm_medium=footer_comment&utm_campaign=free_plugin

Page Caching using Disk: Enhanced 

Served from: shiftmag.dev @ 2026-06-25 21:37:08 by W3 Total Cache
-->