<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Nimrod Shlagman on Medium]]></title>
        <description><![CDATA[Stories by Nimrod Shlagman on Medium]]></description>
        <link>https://medium.com/@nemos_30228?source=rss-f3514ccd1002------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*r_4Wqg1LP_jI9Cmv</url>
            <title>Stories by Nimrod Shlagman on Medium</title>
            <link>https://medium.com/@nemos_30228?source=rss-f3514ccd1002------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 17 Nov 2026 10:03:59 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@nemos_30228/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Using OpenTelemetry OpAMP to modify service telemetry on the go]]></title>
            <link>https://medium.com/@nemos_30228/using-opentelemetry-opamp-to-modify-service-telemetry-on-the-go-37b064cf8a49?source=rss-f3514ccd1002------2</link>
            <guid isPermaLink="false">https://medium.com/p/37b064cf8a49</guid>
            <category><![CDATA[opentelemetry]]></category>
            <category><![CDATA[telemetry]]></category>
            <category><![CDATA[configuration-management]]></category>
            <dc:creator><![CDATA[Nimrod Shlagman]]></dc:creator>
            <pubDate>Wed, 19 Oct 2022 00:00:28 GMT</pubDate>
            <atom:updated>2022-10-19T09:52:38.332Z</atom:updated>
            <content:encoded><![CDATA[<p>How verbose should your service telemetry be? Should a service output all traces, metrics, and logs 100% of the time? How much of the service traffic should be sampled? I would like to suggest the answer of “it depends”. Desired telemetry data differs in a service lifecycle from development to continuous deployment. It changes when clients face an error or a service has been thrown into a major scale.</p><p>It is possible to change a service telemetry configuration or sampling rate. Usually, it requires only a minimal code change and a deployment process. It might not seem a lot, but whenever facing a change like this across an entire system, we tend to avoid it. Instead, it is common to collect as much data as possible, which causes an issue by itself. Can we dynamically modify service telemetry without those barriers? Thanks to <a href="https://github.com/open-telemetry/opamp-go">OpAMP</a> protocol and the people behind it, I believe that the answer is about to change.</p><p>OpenTelemetry, also known as OTel, is a vendor-neutral open-source observability framework for instrumenting, generating, collecting, and exporting telemetry data such as traces, metrics, and logs. It’s a fast-growing Cloud Native Computing Foundation (CNCF) project. OTel is made of several components including per-language SDKs and a collector. The collector is a centralized pipeline made to collect, transform and export telemetry data. The SDK is a specific language OTel API implementation, running with a service. It is used as an input to the collector telemetry receiver.</p><p>OpAMP stands for <a href="https://github.com/open-telemetry/opamp-spec/blob/main/specification.md">Open Agent Management Protocol</a>. It aims at managing large fleets of data collection agents, and its GoLang <a href="https://github.com/open-telemetry/opamp-go/">implementation</a> is at the Beta stage. It allows configuration changes as well as package downloads. It defines the communication between the OpAMP server and OpAMP client but does not assume any particular client-agent relationship giving it a lot of flexibility.</p><p>In the following example, we’ll create a simple GoLang server, instrument it, and then control it with an OpAMP server and supervisor. We won’t dive into OpAMP implementation itself, but rather focus on its implications using these examples.</p><p>First, consider this basic go server:</p><pre>package main</pre><pre>import (<br> &quot;fmt&quot;<br> &quot;log&quot;<br> &quot;net/http&quot;<br>)</pre><pre>func httpHandler(w http.ResponseWriter, r *http.Request) {<br> fmt.Fprintf(w, &quot;Hi! This action could create a trace!&quot;)<br>}</pre><pre>func main() {<br> handler := http.HandlerFunc(httpHandler)<br> http.Handle(&quot;/&quot;, handler)<br> fmt.Println(&quot;Starting server on port 8080&quot;)<br> log.Fatal(http.ListenAndServe(&quot;:8080&quot;, nil))<br>}</pre><p>Next, add a basic configuration file named effective.yaml. Place it in the same folder as our main.go file with this configuration:</p><pre>instrument: false</pre><p>Let’s add a basic configuration handler to our server:</p><pre>package main</pre><pre>import (<br>   &quot;fmt&quot;<br>   &quot;gopkg.in/yaml.v3&quot;<br>   &quot;io/ioutil&quot;<br>   &quot;log&quot;<br>   &quot;net/http&quot;<br>   &quot;path/filepath&quot;<br>)</pre><pre>type configurations struct {<br>   Instrument bool<br>}</pre><pre>func httpHandler(w http.ResponseWriter, r *http.Request) {<br>   fmt.Fprintf(w, &quot;Hi! This action could create a trace!&quot;)<br>}</pre><pre>func main() {<br>   filename, _ := filepath.Abs(&quot;./effective.yaml&quot;)<br>   yamlFile, _ := ioutil.ReadFile(filename)</pre><pre>var config configurations<br>   yaml.Unmarshal(yamlFile, &amp;config)</pre><pre>handler := http.HandlerFunc(httpHandler)<br>   http.Handle(&quot;/&quot;, handler)<br>   fmt.Println(&quot;Starting server on port 8080&quot;)<br>   log.Fatal(http.ListenAndServe(&quot;:8080&quot;, nil))<br>}</pre><p>Next, let’s wrap our handler with instrumentation and condition it with our configuration file. Something like this:</p><pre>package main</pre><pre>import (<br>   &quot;context&quot;<br>   &quot;fmt&quot;<br>   &quot;go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp&quot;<br>   &quot;go.opentelemetry.io/otel&quot;<br>   &quot;go.opentelemetry.io/otel/exporters/stdout/stdouttrace&quot;<br>   sdktrace &quot;go.opentelemetry.io/otel/sdk/trace&quot;<br>   &quot;go.opentelemetry.io/otel/trace&quot;<br>   &quot;gopkg.in/yaml.v3&quot;<br>   &quot;io/ioutil&quot;<br>   &quot;log&quot;<br>   &quot;net/http&quot;<br>   &quot;os&quot;<br>   &quot;path/filepath&quot;<br>)</pre><pre>type configurations struct {<br>   Instrument bool<br>}</pre><pre>var tracer trace.Tracer</pre><pre>func newConsoleExporter() (sdktrace.SpanExporter, error) {<br>   return stdouttrace.New(<br>      stdouttrace.WithWriter(os.Stdout),<br>      stdouttrace.WithPrettyPrint(),<br>   )<br>}</pre><pre>func httpHandler(w http.ResponseWriter, r *http.Request) {<br>   fmt.Fprintf(w, &quot;Hi! This action could create a trace!&quot;)<br>}</pre><pre>func setHandler(handler http.Handler, config configurations) http.Handler {<br>   if config.Instrument {<br>      return otelhttp.NewHandler(handler, &quot;instrumentation activated by OpAMP&quot;)<br>   }<br>   return http.HandlerFunc(httpHandler)<br>}</pre><pre>func main() {<br>   filename, _ := filepath.Abs(&quot;./effective.yaml&quot;)<br>   yamlFile, _ := ioutil.ReadFile(filename)</pre><pre>var config configurations<br>   yaml.Unmarshal(yamlFile, &amp;config)</pre><pre>exp, _ := newConsoleExporter()<br>   tp := sdktrace.NewTracerProvider(sdktrace.WithBatcher(exp))<br>   defer func() { _ = tp.Shutdown(context.Background()) }()</pre><pre>otel.SetTracerProvider(tp)</pre><pre>tracer = tp.Tracer(&quot;ControlledOpAMPAgentDemo&quot;)<br>   handler := http.HandlerFunc(httpHandler)<br>   http.Handle(&quot;/&quot;, setHandler(handler, config))<br>   fmt.Println(&quot;Starting server on port 8080&quot;)<br>   log.Fatal(http.ListenAndServe(&quot;:8080&quot;, nil))<br>}</pre><p>Build and run this app:</p><pre>go build .<br>go run .</pre><p>Open a browser and visit <a href="http://localhost:8080/">http://localhost:8080</a>. Nothing special will be shown. It’s time to add some opamp. Git clone <a href="https://github.com/open-telemetry/opamp-go">opamp-go</a> and run the server with:</p><pre>cd internal/examples/server<br>go run .</pre><p>Visit <a href="http://localhost:4321/">http://localhost:4321</a> to verify server is running. Notice that no agent is displayed:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/425/0*VrjbytXIs9xd4D5S.png" /></figure><p>Next, edit internal/examples/supervisor/bin/supervisor.yaml to point at our agent. It should look like this:</p><pre>server:<br>  endpoint: ws://127.0.0.1:4320/v1/opamp<br>agent:<br>  executable: &lt;absolute|relative path to previous build&gt;</pre><p>Then open a new terminal and run the following command:</p><pre>cd internal/examples/supervisor/bin<br>go build -o ./supervisor ../main.go<br>./supervisor</pre><p>We have now a system consisting of OpAMP server supervisor and our server</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/425/0*9EuUgiemiPWAP_S9.png" /></figure><p>Via the supervisor we can now see our agent running at <a href="http://localhost:4321/">http://localhost:4321</a>. Select it and pass instrument: true to its configurations.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Ftmd9OOr-D9SfH8I.png" /></figure><p>You can see the changes over the supervisor console log:</p><pre>Received remote config from server, hash=0008886301f3ccb3520216823cfa09a.<br>Effective config changed.<br>Config is changed. Signal to restart the agent.<br>Restarting the agent with the new config.<br>Stopping agent process, PID=19206<br>Agent process PID=19206 successfully stopped.<br>Starting agent &lt;agent path&gt;<br>Agent process started, PID=19506</pre><p>Finally, visit <a href="http://localhost:8080/">http://localhost:8080</a>. Traces should now appear in internal/examples/supervisor/bin/agent.log.</p><pre>Starting server on port 8080<br>{<br>   &quot;Name&quot;: &quot;instrumentation activated by OpAMP server&quot;,<br>   &quot;SpanContext&quot;: {<br>      &quot;TraceID&quot;: &quot;d2f76958023624d4c1def3f44899b6d4&quot;,<br>      &quot;SpanID&quot;: &quot;085510f551dc31a1&quot;,<br>      &quot;TraceFlags&quot;: &quot;01&quot;,<br>      &quot;TraceState&quot;: &quot;&quot;,<br>      &quot;Remote&quot;:false<br>   ...</pre><p>These lines are the trace itself!</p><p>To sum up, we have here a server that controls whether our service will generate traces. Try setting it off using the instrument: false configuration.</p><p>This is a very basic implementation. Wrapping a system above OpAMP could perform as an instrumentation orchestrator. The starting point is being able to externally add and match tailor-made dynamic telemetry for your system. Imagine what AI can achieve on this type of system. It could collect metrics over the entire system, automatically and dynamically adding trace/log collections onto any detected bottlenecks. Using this protocol enables many new possibilities, I believe it has the potential to change how we think about telemetry.</p><p><em>Originally published at </em><a href="https://opentelemetry.io/blog/2022/opamp/"><em>https://opentelemetry.io</em></a><em> on October 19, 2022.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=37b064cf8a49" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[7 Tips to make your life better when switching from Windows to macOS]]></title>
            <link>https://medium.com/@nemos_30228/7-tips-to-make-your-life-better-when-switching-from-windows-to-macos-40549a6b1d24?source=rss-f3514ccd1002------2</link>
            <guid isPermaLink="false">https://medium.com/p/40549a6b1d24</guid>
            <category><![CDATA[macos]]></category>
            <category><![CDATA[tips-and-tricks]]></category>
            <category><![CDATA[workflow]]></category>
            <dc:creator><![CDATA[Nimrod Shlagman]]></dc:creator>
            <pubDate>Thu, 24 Mar 2022 08:21:11 GMT</pubDate>
            <atom:updated>2022-03-24T08:52:16.035Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DQvW9i5G0yv9_iBE8YxZYw.jpeg" /></figure><p>Switching between operating systems is hard and triggering. Think about the anxiety of starting a new job fueled by each insecure keystroke. Fear not my friend - nobody cares how you type, plus you’ve got this short and handy guide on your side!</p><p>A short disclaimer — this isn’t a comparison between OS. This guide provides some simple customizations to make macOS more intuitive for PC windows users. It’s not focused on ultimate power-user shortcuts. It’s not a cheat sheet. We have gifs, let’s begin:</p><p><strong>1 Where’s my right-click?</strong> I remember doing stuff with right-click!<br>Well, secondary tap isn’t so big in macOS, still, you can easily enable it via system preferences (your new control panel):</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2F0v6N18LybzTypgGZja%2Ftwitter%2Fiframe&amp;display_name=Giphy&amp;url=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2F0v6N18LybzTypgGZja%2Fgiphy.gif&amp;image=https%3A%2F%2Fi.giphy.com%2Fmedia%2F0v6N18LybzTypgGZja%2Fgiphy.gif&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="396" frameborder="0" scrolling="no"><a href="https://medium.com/media/86828c1037baeeb4f849e4910945482e/href">https://medium.com/media/86828c1037baeeb4f849e4910945482e/href</a></iframe><p><strong>2 I want a big My Computer icon on my desktop.</strong><br>You got it:</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2FXF17Bzb3BE1lnNP2pA%2Ftwitter%2Fiframe&amp;display_name=Giphy&amp;url=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2FXF17Bzb3BE1lnNP2pA%2Fgiphy.gif&amp;image=https%3A%2F%2Fi.giphy.com%2Fmedia%2FXF17Bzb3BE1lnNP2pA%2Fgiphy.gif&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="415" frameborder="0" scrolling="no"><a href="https://medium.com/media/3f776e21bcfe4d4da2c40ac0e77a6db9/href">https://medium.com/media/3f776e21bcfe4d4da2c40ac0e77a6db9/href</a></iframe><p><strong>3 I Can’t find an app</strong><br>Use the ⌘ Space shortcut or the big magnifier glass icon on the top right corner to search by its name. This will work surprisingly fast for file search as well.</p><p><strong>4 How can I move one directory up in File Explorer Finder?</strong><br>Oh, you can do more than that! Simply add a Bar path for a super useful breadcrumbs display.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2FxxxKeUihh05lRRj1PI%2Ftwitter%2Fiframe&amp;display_name=Giphy&amp;url=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2FxxxKeUihh05lRRj1PI%2Fgiphy.gif&amp;image=https%3A%2F%2Fi.giphy.com%2Fmedia%2FxxxKeUihh05lRRj1PI%2Fgiphy.gif&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="259" frameborder="0" scrolling="no"><a href="https://medium.com/media/59f8db8cb665f54954415a462095c3e9/href">https://medium.com/media/59f8db8cb665f54954415a462095c3e9/href</a></iframe><p><strong>5 How do I close an application?</strong><br>See that little red X on the top left corner of your application? Surprisingly, it doesn’t completely close the app. You can see it’s still running by the little dot below it over the Dock. Introducing Quit App with ⌘Q or:</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2F1BvhTrMnnUivUP2Ype%2Ftwitter%2Fiframe&amp;display_name=Giphy&amp;url=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2F1BvhTrMnnUivUP2Ype%2Fgiphy.gif&amp;image=https%3A%2F%2Fi.giphy.com%2Fmedia%2F1BvhTrMnnUivUP2Ype%2Fgiphy.gif&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="381" frameborder="0" scrolling="no"><a href="https://medium.com/media/433f0eec087c20d71ebea2dff695553a/href">https://medium.com/media/433f0eec087c20d71ebea2dff695553a/href</a></iframe><p><strong>6 I keep messing with the language input source switch, got any suggestions?</strong> <br>Yes, type “Language input methods” on the system preference upper right search bar and check the “Use the caps lock key to switch to and from ABC”. Now there’s a proper usage to this huge keyboard key (you can still enable all caps with a longer angry press).</p><p><strong>7 OK what’s next? </strong><br>macOS has an alt-tab equivalent but I want to suggest the mission control + swipe between full-screen apps combo ✊🦶 steps:</p><ol><li>Make your 3 mainly used apps on full-screen mode. Say IDE, browser and communication app.</li></ol><p>That’s it, you can now swipe between them easily using the mysterious 3 fingers swipe ➡️ (2 if your using the magic mouse):</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2FjnQzz4ibx9VCXWw09N%2Ftwitter%2Fiframe&amp;display_name=Giphy&amp;url=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2FjnQzz4ibx9VCXWw09N%2Fgiphy.gif&amp;image=https%3A%2F%2Fi.giphy.com%2Fmedia%2FjnQzz4ibx9VCXWw09N%2Fgiphy.gif&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="435" frameborder="0" scrolling="no"><a href="https://medium.com/media/33b367db10efdb2456f13a0c5ade2ade/href">https://medium.com/media/33b367db10efdb2456f13a0c5ade2ade/href</a></iframe><p><strong>Where are the non full-screen ones?</strong> <br>Same fingers, now ⬆️ and everything revealed:</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fgiphy.com%2Fembed%2FpjVfmaOQvu3YFwyX8n%2Ftwitter%2Fiframe&amp;display_name=Giphy&amp;url=https%3A%2F%2Fmedia.giphy.com%2Fmedia%2FpjVfmaOQvu3YFwyX8n%2Fgiphy.gif&amp;image=https%3A%2F%2Fi.giphy.com%2Fmedia%2FpjVfmaOQvu3YFwyX8n%2Fgiphy.gif&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=giphy" width="435" height="435" frameborder="0" scrolling="no"><a href="https://medium.com/media/4e564e93428d31f70b57e4d2e45316f4/href">https://medium.com/media/4e564e93428d31f70b57e4d2e45316f4/href</a></iframe><p><strong>Congrats!</strong> You finished this guide 🎊 search for “hot corners” in system preferences for some time saving cool customizable shortcuts.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=40549a6b1d24" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>