<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Openapi on Yonatan Karp-Rudin</title><link>https://yonatankarp.github.io/he/tags/openapi/</link><description>Recent content in Openapi on Yonatan Karp-Rudin</description><generator>Hugo</generator><language>he</language><lastBuildDate>Wed, 14 Dec 2022 00:00:00 +0100</lastBuildDate><atom:link href="https://yonatankarp.github.io/he/tags/openapi/index.xml" rel="self" type="application/rss+xml"/><item><title>איך לבנות Domain Gateway עם OpenApi</title><link>https://yonatankarp.github.io/he/blog/build-domain-gateway-openapi/</link><pubDate>Wed, 14 Dec 2022 00:00:00 +0100</pubDate><guid>https://yonatankarp.github.io/he/blog/build-domain-gateway-openapi/</guid><description>&lt;div class="editors-note"&gt;
&lt;p&gt;&lt;strong&gt;TL;DR:&lt;/strong&gt; המאמר הזה מסביר מה זה domain gateway, איך לבנות אחד ולמה תרצו אותו.&lt;/p&gt;
&lt;/div&gt;
&lt;h2 id="מה-זה-domain-gateway"&gt;מה זה Domain Gateway?&lt;/h2&gt;
&lt;p&gt;domain gateway הוא מקרה פרטי של ה-API gateway pattern. האתר &lt;a href="https://java-design-patterns.com/patterns/api-gateway/"&gt;java-design-patterns&lt;/a&gt; מגדיר את ה-gateway pattern כך:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;With the Microservices pattern, a client may need data from multiple different microservices. If the client called each microservice directly, that could contribute to longer load times, since the client would have to make a network request for each microservice called. Moreover, having the client call each microservice directly ties the client to that microservice – if the internal implementations of the microservices change (for example, if two microservices are combined sometime in the future) or if the location (host and port) of a microservice changes, then every client that makes use of those microservices must be updated. The intent of the API Gateway pattern is to alleviate some of these issues. In the API Gateway pattern, an additional entity (the API Gateway) is placed between the client and the microservices. The job of the API Gateway is to aggregate the calls to the microservices. Rather than the client calling each microservice individually, the client calls the API Gateway a single time. The API Gateway then calls each of the microservices that the client needs.&lt;/p&gt;</description></item><item><title>איך להשתמש ב-OpenApi לבניית RESTful API חזק</title><link>https://yonatankarp.github.io/he/blog/openapi-robust-restful-api/</link><pubDate>Sun, 04 Dec 2022 00:00:00 +0100</pubDate><guid>https://yonatankarp.github.io/he/blog/openapi-robust-restful-api/</guid><description>&lt;div class="editors-note"&gt;
&lt;p&gt;&lt;strong&gt;הערת עורך:&lt;/strong&gt; הפוסט הזה נכתב על ידי במקור ופורסם בבלוג של SumUp. אבל הרבה השתנה מאז. אני כבר לא עובד ב-SumUp, OpenAPI שחרר שתי גרסאות major, ל-Spring Boot היה release major, ואפילו ל-Gradle היו כמה releases major. לא רק זאת, כישורי הכתיבה שלי השתפרו דרמטית מאז, ולאורך זמן מצאתי כמה טעויות קטנות במאמר המקורי. מאחר שהמאמר המקורי הוא אחד המוצלחים שלי, החלטתי לכתוב אותו מחדש ולפרסם גרסה מעודכנת.&lt;/p&gt;
&lt;/div&gt;
&lt;h2 id="מבוא"&gt;מבוא&lt;/h2&gt;
&lt;h3 id="restful-api--הצד-המכוער"&gt;RESTful API — הצד המכוער&lt;/h3&gt;
&lt;p&gt;כמהנדסת/מהנדס backend, פיתחתי APIs רבים ב-REST במהלך הקריירה שלי. אחת הבעיות הכי מעצבנות שנתקלתי בה שוב ושוב הייתה חוסר בשילוב חלק בין ה-backend לבין הלקוחות. שגיאות כתיב ב-URLs, חוסר עקביות ב-JSON (camel case לעומת snake case), העברת ערכים מהסוג הלא נכון (לדוגמה, string במקום integer) ועוד טעויות דומות קרו לי הרבה פעמים.&lt;/p&gt;</description></item></channel></rss>