<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Grpc on 300.Watts</title><link>https://300watts.me/tags/grpc/</link><description>Recent content in Grpc on 300.Watts</description><generator>Hugo</generator><language>en</language><managingEditor>morristai01@gmail.com (Morris)</managingEditor><webMaster>morristai01@gmail.com (Morris)</webMaster><copyright>This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.</copyright><lastBuildDate>Thu, 30 Mar 2023 20:27:00 +0000</lastBuildDate><atom:link href="https://300watts.me/tags/grpc/index.xml" rel="self" type="application/rss+xml"/><item><title>Serverless with Rust and Protocol Buffers</title><link>https://300watts.me/posts/serverless-with-rust-and-protocol-buffers/</link><pubDate>Wed, 08 Mar 2023 19:43:00 +0000</pubDate><author>morristai01@gmail.com (Morris)</author><guid>https://300watts.me/posts/serverless-with-rust-and-protocol-buffers/</guid><description>&lt;link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/katex@0.16.2/dist/katex.min.css" integrity="sha384-bYdxxUwYipFNohQlHt0bjN/LCpueqWz13HufFEV1SUatKs1cm4L6fFgCi1jT643X" crossorigin="anonymous"&gt;
&lt;p&gt;I&amp;rsquo;ve recently been working on rewriting our small service with Rust for fun. One reason is to see if Rust, as a system programming language, is ready for cloud development in 2023. Another reason is that I wonder how much better it is compared to Python or Java in major cloud and data computing.&lt;/p&gt;
&lt;blockquote&gt;
 &lt;p&gt;💡 There is a lot of discussion over which language to use as a serverless service. In my point of view, dynamic languages like Python lack compile-time checks, which can cause more runtime errors than static languages like Rust or Java.&lt;br&gt;
Another reason is that Python and Java need a runtime process (JVM, CPython) to run your actual code, which means they can&amp;rsquo;t run natively like compiled Rust does. However, I&amp;rsquo;m not sure about the performance gap. Furthermore, Rust doesn&amp;rsquo;t require garbage collection, so ideally, a program&amp;rsquo;s heap size should fluctuate less than a garbage-collected language when running. That means Lambda or Function underlying infrastructure controller should be able to handle invocation or scaling more easily.&lt;br&gt;
In terms of language paradigms, in my opinion, compared to traditional OOP, the modern &lt;a href="https://en.wikipedia.org/wiki/ML_%2528programming_language%2529" target="_blank" rel="noopener noreferrer"&gt;ML (meta-language) family&lt;/a&gt; has a better design for scalable cloud services.&lt;/p&gt;</description></item></channel></rss>