<?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 Damiano Giampaoli on Medium]]></title>
        <description><![CDATA[Stories by Damiano Giampaoli on Medium]]></description>
        <link>https://medium.com/@damianofds?source=rss-7596d3f1af79------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*gAIewoREdgE3Mv0nDN64CQ.jpeg</url>
            <title>Stories by Damiano Giampaoli on Medium</title>
            <link>https://medium.com/@damianofds?source=rss-7596d3f1af79------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 17 Nov 2026 10:29:48 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@damianofds/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[Slip into Messi’s Jersey: Unveiling the Magic of Snapchat Lens Studio!]]></title>
            <link>https://medium.com/fansea/slip-into-messis-jersey-unveiling-the-magic-of-snapchat-lens-studio-fc6e6a2c1821?source=rss-7596d3f1af79------2</link>
            <guid isPermaLink="false">https://medium.com/p/fc6e6a2c1821</guid>
            <category><![CDATA[messi]]></category>
            <category><![CDATA[metaverse]]></category>
            <category><![CDATA[world-cup]]></category>
            <category><![CDATA[ar]]></category>
            <category><![CDATA[snapchat]]></category>
            <dc:creator><![CDATA[Damiano Giampaoli]]></dc:creator>
            <pubDate>Fri, 10 Nov 2023 16:31:11 GMT</pubDate>
            <atom:updated>2023-11-10T16:31:11.725Z</atom:updated>
            <content:encoded><![CDATA[<p>In the ever-evolving world of augmented reality (AR), Snapchat has been at the forefront of fun and innovation, offering users exciting and immersive experiences. One of the features that set Snapchat apart is its 3D Body Tracking technology, which allows for the integration of 3D models into the real world.</p><p>In this article, we’ll dive into the two primary approaches we use at Fansea for bringing <a href="https://fansea.io/">3D models to life using Snapchat Lens Studio</a>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_RMVLYKCogAFeiUiWph8og.png" /><figcaption>Metaverse artists rigging a 3d model of a human body in year 2028</figcaption></figure><h3>Manual rigging: unleash your creativity</h3><p>Snapchat’s 3D Body Tracking offers the flexibility to import your own rigged 3D models, providing a canvas for your creative endeavors. This approach, empowers AR creators to bring their unique visions to life, at a cost of a less automated process. Here’s how it works:</p><h4>Custom Weights and Bone Hierarchy:</h4><ul><li>While Snapchat allows for custom weights, your model’s bone hierarchy must adhere to a specific structure.</li><li>Snapchat’s official documentation provides a detailed hierarchy, ensuring that the bones’ names follow a specific naming convention.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/760/1*eJRUgANql3NLCu2zyYJSlQ.png" /></figure><h4>Partial Structure Customization</h4><ul><li>Creators can use a partial bone structure, but the bones’ names must align with Snapchat’s established schema.</li><li>This means you can create your own custom weight paint while adhering to Snapchat’s bone structure guidelines.</li></ul><p>While the Manual approach grants creative freedom, it does require creators to adhere to Snapchat’s bone hierarchy and naming conventions. However, this ensures that your 3D models can seamlessly integrate into the AR environment and provide users with an immersive experience.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*K2wXvz-56StkSdD3otsr6g.png" /><figcaption>Developing a messi wearable… while wearing it :)</figcaption></figure><h3>Automatic rigging: let Snapchat work for you</h3><p>Snapchat automatic mode takes a different approach to 3D Body Tracking. It leverages the same reference skeletal system explained earlier to generate body meshes in real time. This approach reduces the burden on creators by rigging models automatically within the Snapchat ecosystem.</p><p>Here’s how it works:</p><ol><li>Real Time rigging<br>Snapchat’s Auto mode rigs the 3D model in real time, aligning it with the reference skeletal system.</li><li>No Custom Weights<br>Unlike the Manual approach, Auto mode does not allow for the import of custom weight paint.</li><li>Simplified Workflow<br>Creators have less work to do in Auto mode, as Snapchat handles most of the rigging automatically.</li></ol><p>The Automatic mode streamlines the process of bringing 3D models into Snapchat’s AR environment, making it more accessible for creators with varying levels of expertise. However, it may come with some limitations in terms of model adaptability.</p><h4>Wearables: Exploring External Meshes</h4><p>For those interested in creating AR wearables within Snapchat, there’s an exciting option known as “External Meshes.” These wearables require no rigging, and creators need only focus on designing the model and materials according to a reference mesh provided by Snapchat. Here’s how it works:</p><ol><li>Reference Mesh Integration<br>Creators need to design wearables according to a reference mesh provided by Snapchat, eliminating the need for custom rigging.</li><li>Weights Slider Control<br>Creators can adjust the degree of morphing between the base mesh created by Snapchat and the External mesh provided using the Weights slider.</li></ol><p>The “External Mesh” approach is perfect for those who want to create AR accessories and wearables without diving into the complexities of rigging. It offers a streamlined process and allows for real-time adjustments to achieve the desired visual effects.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1010/1*SeaDzjBweZsVJ-hVGYeMQA.png" /><figcaption>The messi jersey modelled on a reference mesh</figcaption></figure><h3>Some last thoughts</h3><p>In conclusion, Snapchat’s 3D Body Tracking opens up a world of creative possibilities, and creators can choose the approach that best suits their needs. Manual rigging allows for complete customization but comes with specific requirements, while Auto mode simplifies the process but limits customizations. For AR wearables, External Meshes provide a hassle-free solution.</p><p>Ultimately, the choice between rigging and using reference meshes in Snapchat depends on your creative vision and technical expertise. Whichever path you choose, you’re bound to be part of the exciting world of AR content creation, enhancing the Snapchat experience for users worldwide.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=fc6e6a2c1821" width="1" height="1" alt=""><hr><p><a href="https://medium.com/fansea/slip-into-messis-jersey-unveiling-the-magic-of-snapchat-lens-studio-fc6e6a2c1821">Slip into Messi’s Jersey: Unveiling the Magic of Snapchat Lens Studio!</a> was originally published in <a href="https://medium.com/fansea">Fansea</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Apple Vision Pro: what’s new for app development]]></title>
            <link>https://medium.com/fansea/apple-vision-pro-whats-new-for-app-development-b8152691fb99?source=rss-7596d3f1af79------2</link>
            <guid isPermaLink="false">https://medium.com/p/b8152691fb99</guid>
            <category><![CDATA[ar]]></category>
            <category><![CDATA[apple]]></category>
            <category><![CDATA[vr]]></category>
            <category><![CDATA[spatial-computing]]></category>
            <category><![CDATA[apple-vision-pro]]></category>
            <dc:creator><![CDATA[Damiano Giampaoli]]></dc:creator>
            <pubDate>Thu, 21 Sep 2023 07:59:13 GMT</pubDate>
            <atom:updated>2023-09-21T07:59:13.665Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="Two developers working on a spatial computing project" src="https://cdn-images-1.medium.com/max/1024/1*ouyRUw5VfmunbarLahiR5Q.png" /></figure><p>Apple is introducing several innovative features and design principles to enhance the user experience and productivity of its first spatial computing device.</p><p>I’m super excited to work on <a href="https://fansea.io/">spatial computing</a> app development at Fansea. In this article, we’ll delve deeper into some innovative features that every spatial app will have on a Vision Pro device.</p><h4>A special test model</h4><p>Throughout all the examples in this article, we will use as a test model a 3D scan of a historic tango ball used in the World Cup final in 1978, the first won by Selección Argentina. Our most loyal customers received it as Airdrop in 2022 to celebrate the new Argentina World Cup victory.</p><p>This is how it looks in <a href="http://fansea.app/">fansea.app</a></p><figure><img alt="The tango ball in the fansea.app 3D stage" src="https://cdn-images-1.medium.com/max/1024/1*znLgFd7GfC9zdzgDs0uEFA.png" /><figcaption>The tango ball in the fansea.app 3D stage</figcaption></figure><p>Let’s play with it on Apple Vision Pro!</p><h3>A new operating system</h3><p>With the presentation of Vision Pro at WWDC23, Apple introduced a new operating system called <strong>visionOS</strong>. While Vision Pro is the hardware, visionOS serves as the operating system that powers the immersive experiences on the Vision Pro headset.</p><p>VisionOS can be run on a simulator, mirroring the approach taken with iOS development. This means that as developers we can start crafting applications for visionOS today, without the immediate necessity of owning a Vision Pro device for development and testing.</p><figure><img alt="A simple app running on visionOS simulator" src="https://cdn-images-1.medium.com/max/1024/1*AnmAVI75lJq2pNysoC-7hA.png" /><figcaption>A simple app running on visionOS simulator which runs on MacOS X</figcaption></figure><p>The living room you can see in the picture above is fictional and it is added by the simulator. If you were running this on the Vision Pro device, you would see your own living room there.</p><h3>New design primitives</h3><p>Mac OS X is essentially composed of resizable windows operating over a desktop, iOS has a home screen from where you can launch full-screen apps.</p><p>VisionOS instead, is composed of <strong>volumes</strong> and <strong>windows</strong> floating into a s<strong>pace</strong>.</p><p>But let’s dive into these 3 UI elements:</p><h4>Windows</h4><p>Just as in traditional computing environments, windows in visionOS serve as the primary interface for users to interact with various applications. These windows, built with <strong>SwiftUI</strong>, offer a familiar structure that incorporates traditional views and controls, ensuring a seamless transition for users familiar with Apple’s mobile operating system.</p><p>This is a window, saw from a ~45 degrees angle. It contains some text, a button, and a the tango ball. The last one is a <em>volume</em>.</p><figure><img alt="A SwiftUI window with some text, a button and a Tango Ball!" src="https://cdn-images-1.medium.com/max/1024/1*5k39HNqFGzc2_9WOaQirqA.png" /><figcaption>This is a window, I’ve coded it like a swiftUI iOS form</figcaption></figure><h4>Volumes</h4><p>They represent a notable shift in UI design. These SwiftUI scenes are capable of showcasing 3D content, which is essential for creating immersive AR experiences. Developers have the flexibility to use either <strong>RealityKit </strong>or <strong>Unity </strong>to build these volumes, opening up a world of possibilities for creating interactive, 3D-rich applications.</p><p>Volumes can be of two types:</p><ul><li><strong>bounded</strong>, the 3D content resides inside a window</li><li><strong>unbounded</strong>, the 3D content lives inside the space</li></ul><p>The user can interact with unbounded volumes as if they were part of the physical world, but they are digital objects overlayed to it.</p><p>So yes, with Apple Vision Pro you can play soccer in the kitchen without making your parents upset :)</p><figure><img alt="An example of a bounded volume and an unbounded one on visionOS" src="https://cdn-images-1.medium.com/max/1024/1*T0sm7x4ORMAldR2dzN40Pg.png" /><figcaption>Our historic tango ball loaded as a bounded (top-right) and unbounded (bottom-left) volume</figcaption></figure><h4>Spaces</h4><p>They introduce a new way of organizing multitasking to the VisionOS experience. There are two primary types:</p><ul><li>A <strong>Shared Space</strong> allows multiple apps to coexist within the user’s view, similar to how multiple apps can be open on a Mac desktop simultaneously.</li><li>On the other hand, a <strong>Full Space</strong> is more focused, presenting only a single app at a time. It can include windows, volumes (bounded or unbounded to a window), and even portals to different virtual worlds, emphasizing flexibility and immersive experiences.</li></ul><p>The screenshots above were all taken in a Shared Space. But clicking on the button “Play!” of the window the app brings us to the Shared Space…</p><p>Ready? click…</p><figure><img alt="beware of full space" src="https://cdn-images-1.medium.com/max/1024/1*9CQ_25DNb3-3Q-ZXKceGHQ.png" /><figcaption>This warning message wouldn’t make sense on traditional computing…</figcaption></figure><p>Entering the Full Space requires extra safety. We will not see the physical environment around us, we will be immersed in our app.</p><p>So let’s click on “Continue”…</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vq9lfgrMojNAHvFkU7_KXg.png" /><figcaption>The tango ball in a Full Space simulating deep space</figcaption></figure><p>And here we are! No, it’s not the moon. It’s our tango ball loaded in a Full Space. Here, even the background is virtual, the user is immersed in the app without reference to its physical surrounding.</p><p>Apple rarely used the terms Augmented Reality (AR) or Virtual Reality (VR), they refer only to spatial computing. But the two terms are still valid:</p><ul><li>With multiple apps running in a Shared Space the user is having an AR experience</li><li>With an app in a Full Space the user is immersed in a VR experience</li></ul><h3>New Input Methods</h3><p>Mobile devices primarily rely on multitouch screens as a default input method. Laptops instead use the old mouse and keyboard.</p><p>As of today, voice control and gestures are secondary options in mobile and Desktop computing but visionOS disrupts the status quo!</p><h4>VisionOS Input Methods</h4><p>VisionOS taps into the potential of augmented reality.</p><p>Its default input methods are <strong>eyes</strong> and <strong>voice</strong>, adding a layer of natural and intuitive interaction with the digital world.</p><p>Users can navigate and control elements also using gestures like pointing with the index finger, wrist movements, or even head gestures, which can be configured through Pointer Control settings.</p><p>As a secondary option, VisionOS retains compatibility with Apple peripherals like Magic Touchpad, Magic Mouse, and Magic Keyboard for users who prefer a more conventional approach.</p><h3>New Ways of Rendering</h3><p>The rendering capabilities of VisionOS are notably different from those of iOS, catering to the immersive AR experience.</p><h4>Passthrough</h4><p>This rendering method leverages the headset’s internal monitor to display a live video feed of the physical surroundings, providing users with awareness of their real-world environment while using the headset. Simultaneously, the external monitor takes care of rendering the digital content directly into the user’s eyes. This approach ensures a seamless blending of the virtual and physical worlds, enhancing the overall AR experience of the Shared Space.</p><h4>Dynamic Foveated Rendering</h4><p>To optimize performance and reduce the rendering workload, visionOS incorporates dynamic foveated rendering. This technique utilizes an integrated eye tracker to determine where the user is looking and focuses rendering resources on that area, resulting in higher image quality in the user’s central field of vision. Peripheral areas receive lower-quality rendering, effectively mimicking the way our eyes naturally perceive detail, thus conserving computational resources.</p><figure><img alt="Dynamic foveated rendering explanation" src="https://cdn-images-1.medium.com/max/750/1*93PIGT1VvwFby6zhsqsWGg.jpeg" /><figcaption>picture taken from the <a href="https://research.nvidia.com/publication/2017-09_latency-requirements-foveated-rendering-virtual-reality">nvidia research website</a></figcaption></figure><p>As <a href="https://en.wikipedia.org/wiki/Saccade">wikipedia explains</a>, a “saccade” is:</p><blockquote>a quick, simultaneous movement of both <a href="https://en.wikipedia.org/wiki/Eye_movement_%28sensory%29">eyes</a> between two or more phases of <a href="https://en.wikipedia.org/wiki/Fixation_%28visual%29">fixation</a> in the same direction.</blockquote><h3>Some last thoughts</h3><p>In summary, Apple visionOS applications bring a revolutionary shift in design, input methods, and rendering techniques compared to traditional mobile and desktop devices. These advancements are tailored to the unique capabilities and challenges of augmented reality, paving the way for immersive and interactive experiences on the Apple Vision PRO headset. With the introduction of windows, volumes, and spaces, along with innovative input methods and rendering strategies, VisionOS sets the stage for a new era in augmented reality computing.</p><p>Are you interested in the projects I am working on with Fansea and <a href="https://fansea.io/">Apple Vision Pro</a>?<strong> </strong>Get in touch with us!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b8152691fb99" width="1" height="1" alt=""><hr><p><a href="https://medium.com/fansea/apple-vision-pro-whats-new-for-app-development-b8152691fb99">Apple Vision Pro: what’s new for app development</a> was originally published in <a href="https://medium.com/fansea">Fansea</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Kubernetes ingress: use the GCE built-in nginx controllers in GKE [2/3]]]></title>
            <link>https://medium.com/omnius/draft-kubernetes-ingress-use-the-gce-built-in-nginx-controllers-in-gke-2-3-117653d9f7c3?source=rss-7596d3f1af79------2</link>
            <guid isPermaLink="false">https://medium.com/p/117653d9f7c3</guid>
            <category><![CDATA[kubernetes]]></category>
            <category><![CDATA[gce]]></category>
            <category><![CDATA[ingress]]></category>
            <category><![CDATA[gke]]></category>
            <category><![CDATA[devops]]></category>
            <dc:creator><![CDATA[Damiano Giampaoli]]></dc:creator>
            <pubDate>Thu, 26 Jul 2018 10:39:36 GMT</pubDate>
            <atom:updated>2018-07-26T10:40:38.124Z</atom:updated>
            <content:encoded><![CDATA[<p>In our <a href="https://medium.com/searchink-eng/kubernetes-ingress-gce-vs-nginx-controllers-1-3-d89d6dd3da73">first post about the Kubernetes ingress</a>, we compared 2 different ingress implementations: <strong>GCE</strong> vs <strong>nginx,</strong> highlighting the pros and cons of using one controller instead of the other.</p><p>In this post, we are going to describe all the steps required to setup a <strong>kubernetes ingress</strong> using the Google Kubernetes Engine (<strong>GKE</strong>), which provides a default <strong>ingress-controller</strong> support that relies on Google Container Engine (<strong>GCE</strong>) support.</p><p>GKE and GCE are components of the Google Cloud Platform (<strong>GCP</strong>). So, if you are running ingress on AWS or on premises, the code reported here will not work. But having a look at it could be interesting anyway, if you are new to ingress.</p><p>Let’s start with a diagram:</p><ul><li>the yellow ovals are the components we have to configure ourselves, by applying k8s manifest files</li><li>k8s manifest files are represented by the white sticky notes</li><li>The grey boxes represent GKE and its provided ingress-controller</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/754/1*Z0-vaVX6F5o8TyJwDPUizg.png" /><figcaption>In yellow the components to configure, in grey the support from GKE</figcaption></figure><p>On paper, the only needed step with GCE-controller is to create the ingress configuration itself. But in reality, there are a bunch of other things that must be checked and taken into account, in order to have a fully operational ingress.</p><p>This article assumes that you have already set what is represented with the Backend’s yellow oval. That is,</p><ul><li>a group of webapp or microservices running as <strong>pods</strong> that you want to expose to the internet</li><li>all the pods have a related <strong>NodePort</strong> service exposed</li></ul><blockquote><strong>NOTE </strong>that the <strong>service of type LoadBalancer can’t be used</strong> with the current (April 2018) GCE ingress impementation</blockquote><p>and it explains how to create a basic HTTP API layer for an enterprise system running on Kubernetes.</p><h4>What does “ingress-controller implemented with GCE” mean?</h4><p>An <strong>ingress</strong> can be seen as the kubernetes abstraction of a L7 Load Balancer (where L7 refers to the level 7 of the ISO/OSI model).</p><p>But as explained in the <a href="https://github.com/kubernetes/ingress-gce#overview">overview</a> section of the GCE ingress controller Readme[4] there’s no single resource in GCE representing a L7 Load balancer. So, expect to find some new Global Forwarding Rules and Instances Groups in your GCP dashboard.</p><h4>So, long story short, what needs to be done?</h4><p>Here is a todo list to follow in order to successfully create an ingress:</p><p><strong>Base step</strong>: You need to have some backends to expose using an ingress… if you don’t have them yet, there’s no reason to use an ingress here. If you want a quick basic environment to test, create a new 1.8.x cluster and run <a href="https://github.com/omni-us/blogposts/blob/master/ingress-gce-blogpost/00_backends.yaml">this</a> manifest.</p><p>Then:</p><ol><li>Create a basic ingress with forwarding rules</li><li>Be sure to have properly configured the healthcheck services on the backends</li><li>The default timeout is 30 seconds. In order to increase it, you have to use the GCP console</li></ol><p>… and don’t forget that after each change to the ingress configuration, you have to wait up to 10 minutes before having it fully operational. In the meantime, you can get the 503 error calling the endpoints managed.</p><p>Let’s explain each step in detail now.</p><h3>1. Apply a basic config with forwarding rules only</h3><p>In order to create the scenario to test our ingress, we have created a small test system.</p><p>The test system manifest files can be found at <a href="https://github.com/omni-us/blogposts/blob/master/ingress-gce-blogpost/00_backends.yaml">omni:us on githu</a>b and it is composed of 3+1 backends:</p><ul><li>3 are explicitly configured by us: two instances of echo servers called echo-server and echo-server-2, as well as, an http server called test-webserver</li><li>1 more backend is then created by the GCE ingress-controller: the default backend, handled by k8s and used when the path doesn’t match any of the 3 rules specified.</li></ul><p>Below, we show only the manifest file used to deploy the ingress configuration and its related forwarding rules to our test system. After having connected to our k8s cluster, run the file below called <em>ingress-manifest.yaml</em>:</p><pre>#$ kubectl apply -f ingress-manifest.yaml</pre><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/1b002b51f490066099676371723afe7a/href">https://medium.com/media/1b002b51f490066099676371723afe7a/href</a></iframe><p>Then, to monitor the ingress status, keep a terminal open on:</p><pre>#$ watch kubectl describe ingress</pre><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/4f2a56097ff808db5231296bf8116eb9/href">https://medium.com/media/4f2a56097ff808db5231296bf8116eb9/href</a></iframe><p>The <em>describe </em>command summarizes the status of the deployed ingress. Take note of the <strong>url-map</strong> value because we will use it later for monitoring through GCP dashboard.</p><h3>2. Set healthcheck services on the backends</h3><p>In order to use the ingress feature of kubernetes as reverse proxy, all of the backends <strong>need to provide</strong> a <strong>health service</strong> which <strong>responds “200”</strong> when the host base path is called.</p><p>Without these services, kubernetes marks the backend as UNHEALTHY, and attempting to hit it through the ingress we get a 502 error as reported in [1][2].</p><p>In the last picture of the previous paragraph, we see that all 4 backends are listed in the “describe ingress” command, but one out of the 4 is marked as Unknown. Kubernetes still has to mark it as HEALTHY or UNHEALTHY.</p><p>This constraint can be tedious:</p><ul><li>Imposing to implement a health service on the backend by design, sounds like a good choice. Anyway, sometimes when there is a need to deploy quick-and-dirty containers to run specific experiments, it can so happen that you forget to add the health service.</li><li>For sure, also imposing its interface (response strictly on base path) is too much.</li></ul><h3>3. Configure the timeouts</h3><p>Each backend related to a reverse proxy rule has its own timeout setting.</p><p>By default, that timeout is set to <strong>30 seconds</strong>. At first glance, it sounds like a solidly well-chosen pre-setting value. However, we hit a bottleneck during testing when some of our scientific processes took more than 30 seconds.</p><p>Day after day, we dealt with REST services that trigger a chain of deep learning models, that might end up taking more time than we initially estimated for. Sometimes, this could be as long as a few minutes.</p><p>Have a look at this [3] article to read how to change the timeout using the GCP web interface.</p><h3>Run some requests</h3><p>Okay, now ingress seems to be working. So let’s run some requests with <a href="https://httpd.apache.org/docs/2.4/programs/ab.html">Apache ab</a> against those endpoints and see what happens.</p><p>The test cluster I created has only two very small nodes but I don’t expect great performances under load.</p><p>For each of the 3 backends run some requests like</p><p>#$ ab -n 100 -c 3 http://35.186.233.211/echo</p><p>and playing a bit with the number of concurrent requests -c</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/02e52d4c4be64c2b45f72c1bcf000ec2/href">https://medium.com/media/02e52d4c4be64c2b45f72c1bcf000ec2/href</a></iframe><p>After running some benchmarks, go to the Load Balancer section on the GCP dashboard and search for the load balancer using the <strong>url-map</strong> id we got at end of Step 1.</p><pre>k8s-um-default-ingress — e940260f95a267b9</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/823/1*3-lFDnbxcLps30Y_9hR7PA.jpeg" /><figcaption>Chart of the number of requests per second supported by the system, grouped by backend</figcaption></figure><h3>Conclusions</h3><p><a href="https://medium.com/searchink-eng/kubernetes-ingress-gce-vs-nginx-controllers-1-3-d89d6dd3da73">In our previous post</a>, we gave the nginx ingress-controller a thumbs up, but we would still like to keep an eye on this, especially to see if certain limitations are to be removed. Then, this would present itself as a nifty tool in the toolbox of a tech team that loves Kubernetes (Just like us at <a href="https://omnius.com/">omni:us</a>!).</p><p>Check the GCE ingress-controller github project Readme [4] for all of the documented <a href="https://github.com/kubernetes/ingress-gce#wish-list">limitations and future improvements</a>.</p><h3>References</h3><p>[1] Read the section Remarks in<strong><br></strong><a href="https://cloud.google.com/kubernetes-engine/docs/tutorials/http-balancer"><em>https://cloud.google.com/kubernetes-engine/docs/tutorials/http-balancer</em></a></p><p>[2] About the 502 HTTP error returned by an unhealty backend: <a href="https://stackoverflow.com/questions/42101808/ingress-gives-502-error"><em>https://stackoverflow.com/questions/42101808/ingress-gives-502-error</em></a></p><p>[3] Configure ingress timeouts from the GCP web dashboard<br><a href="https://stackoverflow.com/questions/36200528/how-to-configure-ingress-request-timeouts-on-gke">https://stackoverflow.com/questions/36200528/how-to-configure-ingress-request-timeouts-on-gke</a></p><p>[4] Potential improvements list for ingress-gce<br><a href="https://github.com/kubernetes/ingress-gce#wish-list">https://github.com/kubernetes/ingress-gce</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=117653d9f7c3" width="1" height="1" alt=""><hr><p><a href="https://medium.com/omnius/draft-kubernetes-ingress-use-the-gce-built-in-nginx-controllers-in-gke-2-3-117653d9f7c3">Kubernetes ingress: use the GCE built-in nginx controllers in GKE [2/3]</a> was originally published in <a href="https://medium.com/omnius">omni:us</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Kubernetes ingress: GCE vs nginx controllers [1/3]]]></title>
            <link>https://medium.com/omnius/kubernetes-ingress-gce-vs-nginx-controllers-1-3-d89d6dd3da73?source=rss-7596d3f1af79------2</link>
            <guid isPermaLink="false">https://medium.com/p/d89d6dd3da73</guid>
            <category><![CDATA[devops]]></category>
            <category><![CDATA[reverse-proxy]]></category>
            <category><![CDATA[ingress]]></category>
            <category><![CDATA[kubernetes]]></category>
            <category><![CDATA[https]]></category>
            <dc:creator><![CDATA[Damiano Giampaoli]]></dc:creator>
            <pubDate>Mon, 12 Mar 2018 14:25:12 GMT</pubDate>
            <atom:updated>2018-07-27T07:35:04.694Z</atom:updated>
            <content:encoded><![CDATA[<p>In Kubernetes, the way to deal with the HTTP layer and reverse proxy rules is by using <em>ingress.</em></p><p>According to the official ingress documentation, an <em>ingress</em> is:</p><blockquote>An API object that manages external access to the services in a cluster, typically HTTP.</blockquote><p>And also:</p><blockquote>An Ingress is a collection of rules that allow inbound connections to reach the cluster services.</blockquote><p>Unfortunately, it is still a beta feature. But since it is cool and already rather stable, it can also be considered as a viable option for production.</p><p>This is the first post of a series of 3 articles about k8s ingress, so stay tuned!</p><p>In case you are new to k8s and reverse proxy, it is recommended that you read the <a href="https://kubernetes.io/docs/tutorials/kubernetes-basics/">k8s tutorial</a>[1] and <a href="https://en.wikipedia.org/wiki/Reverse_proxy">wikipedia page for reverse proxy</a>[2].</p><p>The Ingress configuration in kubernetes is a YAML file very similar to the reverse proxy config that you are probably writing in <em>Apache</em> or <em>nginx </em>.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/05c9232157830ca08d7afabe0173c2ce/href">https://medium.com/media/05c9232157830ca08d7afabe0173c2ce/href</a></iframe><p>Other features like IP whitelisting, requesting size limits and even Authentication &amp; Authorization providers can be easily implemented by adding a few more line of configurations called <strong>Annotations</strong>.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/d12a4e53efe7c2606099241429d2d937/href">https://medium.com/media/d12a4e53efe7c2606099241429d2d937/href</a></iframe><p>With the usage of annotations, it starts to get more interesting. Just by writing and applying a few YAML lines, the entry point to your API seems to be in good shape.</p><p>But hey! Wait a minute:</p><p><strong>Where is the documentation for the supported Annonations?</strong> and <strong>Why are there so many variants of them around?</strong></p><p>That’s because the ingress configuration is processed by an <em>ingress controller. </em>Depending on the implementation of the <em>ingress-controller,</em> we use certain Annotations instead of others.</p><p><strong>What’s an ingress-controller implementation?</strong></p><p>Basically it’s a running instance, as a pod, of a http reverse proxy server. Kubernetes keeps its configuration updated, depending on the changes in the <em>ingress</em> configuration file. There are implementations that are using nginx, haproxy and others.</p><p><strong>How to know which <em>ingress-controller</em> I’m running?</strong></p><p>If you are using Kubernetes on a cloud provider (such as Google Cloud Platform or Amazon Web Services), which you probably already have by default, check its reference. In order to use another one you may have to deploy it yourself.</p><p><strong>And so, how does it work on the GKE of the Google Cloud Platform?</strong></p><p>By default, on GKE, you have an <em>ingress-controller</em> implemented with GCE. If you want to use another ingress controller you would have to install it. The installation process consists of deploying a pod, a service, a config map and some secrets if you need TLS support.</p><h3>ngnix vs GCE ingress controllers</h3><p>The default GCE ingress controller has limited functionalities. This includes the lack of support of TLS and for the whitelisting of IP’s. Furthermore, we noticed a massive delay when applying the configuration changes.</p><p>We replaced the default GCE ingress controller with nginx ingress controller, so as to to satisfy our requirements. With this, it also paved the way for the opportunities to use a lot of pre-defined annotations. It is totally worth the effort taken for the manual installation of nginx ingress controller.</p><p>Please note that the Reverse proxy syntax rules vary from one controller to another. Keep in mind that even the usage of “*” on GCE ingress differs from that of nginx ingress.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/705/1*v4YeAaneuCaI0l7V5c3sFA.jpeg" /></figure><h3>TLDR;</h3><ul><li>Ingress is a great tool but you bear the pain of using a beta software in production</li><li>It is important to carefully choose the ingress controller you want to use. Rule of thumb for GKE: use GCE if you only need reverse proxy support, nginx if you also need TLS and A&amp;A</li><li>Additional features are implemented with Annotations. A list of Annotations and their supported controllers are <a href="https://github.com/kubernetes/ingress-gce/blob/master/docs/annotations.md">here</a>[4]. A detailed list only for nginx ingress-controller is <a href="https://github.com/kubernetes/ingress-nginx/blob/master/docs/user-guide/annotations.md">here</a>[5]</li></ul><p>In the next posts we will go into further details of the GCE and nginx configurations. So, stay tuned!</p><h3>Links</h3><p>[1] <strong>Kubernetes tutorial</strong> <a href="https://kubernetes.io/docs/tutorials/kubernetes-basics/">https://kubernetes.io/docs/tutorials/kubernetes-basics/</a></p><p>[2] <strong>Reverse proxy on wikipedia </strong><a href="https://en.wikipedia.org/wiki/Reverse_proxy">https://en.wikipedia.org/wiki/Reverse_proxy</a></p><p>[3] <strong>Ingress official documentation </strong><a href="https://kubernetes.io/docs/concepts/services-networking/ingress/">https://kubernetes.io/docs/concepts/services-networking/ingress/</a></p><p>[4] <strong>Ingress GCE annotations</strong> <a href="https://github.com/kubernetes/ingress-gce/blob/master/docs/annotations.md">https://github.com/kubernetes/ingress-gce/blob/master/docs/annotations.md</a></p><p>[5] <strong>Ingress nginx annotations</strong> <a href="https://github.com/kubernetes/ingress-nginx/blob/master/docs/user-guide/annotations.md">https://github.com/kubernetes/ingress-nginx/blob/master/docs/user-guide/annotations.md</a></p><h3>*** Update ***</h3><p>The second blogpost about GCE ingress-controller is <a href="https://medium.com/omnius/draft-kubernetes-ingress-use-the-gce-built-in-nginx-controllers-in-gke-2-3-117653d9f7c3">here</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d89d6dd3da73" width="1" height="1" alt=""><hr><p><a href="https://medium.com/omnius/kubernetes-ingress-gce-vs-nginx-controllers-1-3-d89d6dd3da73">Kubernetes ingress: GCE vs nginx controllers [1/3]</a> was originally published in <a href="https://medium.com/omnius">omni:us</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>