Changes for page Volume Mapping (On-premise)
Last modified by Erik Bakker on 2024/08/26 12:37
From version 51.1
edited by Erik Bakker
on 2022/12/29 12:33
on 2022/12/29 12:33
Change comment:
There is no comment for this version
Summary
-
Page properties (5 modified, 0 added, 0 removed)
-
Attachments (0 modified, 4 added, 0 removed)
Details
- Page properties
-
- Title
-
... ... @@ -1,1 +1,0 @@ 1 -Volume Mapping (On-premise) - Parent
-
... ... @@ -1,1 +1,0 @@ 1 -WebHome - Author
-
... ... @@ -1,1 +1,1 @@ 1 -XWiki. ebakker1 +XWiki.marijn - Default language
-
... ... @@ -1,1 +1,0 @@ 1 -en - Content
-
... ... @@ -1,123 +1,97 @@ 1 -{{container}}{{container layoutStyle="columns"}}((( 1 +{{html wiki="true"}} 2 +<div class="ez-academy"> 3 + <div class="ez-academy_body"> 2 2 3 -{{warning}} 4 -Please note that this microlearning is for the new monitoring stack only. 5 -{{/warning}} 5 +<div class="doc"> 6 6 7 -When you need to read and write files from an on-premise disk, you need to know the path in which the data is stored and make sure that the docker container in your runtime(s) running has access to this path. There are several ways of dealing with this challenge. First, this microlearning will discuss the various alternatives and best approaches in these scenarios. 8 8 9 -Should you have any questions, please contact [[academy@emagiz.com>>mailto:academy@emagiz.com]]. 10 10 11 -= =1. Prerequisites==9 += Annotations = 12 12 13 - *Basicknowledge of the eMagizplatform11 +In this microlearning, we will focus on using annotations to clarify your thought process. In the annotation, you either describe a best practice everyone should follow when they change that flow (i.e. within the asynchronous routing), describe how the (more complex) parts of the flow work or describe (parts of) of your message definitions (i.e. CDM, API Gateway Data model, system message, etc.). This will help yourself and others every time changes are needed. 14 14 15 - ==2.Key concepts==13 +Should you have any questions, please contact academy@emagiz.com. 16 16 17 -This microlearning centers around learning how to set up your volume mapping correctly so you can exchange file-based data on-premise. 15 +* Last update: May 9th, 2021 16 +* Required reading time: 5 minutes 18 18 19 - Byvolumemapping, wemean: Creating a configuration through which the docker container can read and write data on aspecific path on an on-premisemachine.18 +== 1. Prerequisites == 20 20 21 -There are several options for volume mapping for your on-premise machine. 22 -* Volume 23 -* Bind mount 24 -* Temporary file system 25 -* Named pipe 20 +* Basic knowledge of the eMagiz platform 26 26 27 -== 3.VolumeMapping (On-premise)==22 +== 2. Key concepts == 28 28 29 -When you need to read and write files from an on-premise disk, you need to know the path in which the data is stored and make sure that the docker container in your runtime(s) running has access to this path. There are several ways of dealing with this challenge. First, this microlearning will discuss the various alternatives and best approaches in these scenarios. 24 +This microlearning centers around using annotations. 25 +With annotations, we mean: A piece of text to explain something to yourself and others 30 30 31 -There are several options for volume mapping for your on-premise machine. 32 -* Volume 33 -* Bind mount 34 -* Temporary file system 35 -* Named pipe 27 +Annotations can be used for: 36 36 37 -Below we will explain the differences between the various options available for your volume mapping. But before we do, we first explain how to set up this configuration within eMagiz. Then, you must navigate to Deploy -> Architecture on the model level. In this overview, you can access the Volume mapping per runtime deployed on-premise. To do so, you can right-click on the runtime to access the context menu. 29 +* Describing a best practice everyone should follow 30 +* Describing (more complex) parts of the flow 31 +* Describe (parts of) your message definitions 38 38 39 -[[image:Main.Images.Microlearning.WebHome@novice-file-based-connectivity-volume-mapping-on-premise--volume-option-context-menu.png]] 40 40 41 -When you click this option, you will see the following pop-up. In this pop-up, you can define the machine-level and runtime-level volumes. More on that later. This is the starting point for configuring your volume mapping. We will walk through each available option and explain how they work and should be configured. 42 42 43 - [[image:Main.Images.Microlearning.WebHome@novice-file-based-connectivity-volume-mapping-on-premise--volume-mapping-pop-up.png]]35 +== 3. Annotations == 44 44 45 - {{info}}Notethat youshouldbein"Start editing"modetomakeany changesto the configuration of yourvolume mapping.{{/info}}37 +In this microlearning, we will focus on using annotations on the flow level to clarify our thought process. In the annotation, you either describe a best practice everyone should follow when they change that flow (i.e. within the asynchronous routing) or describe how the (more complex) parts of the flow work. This will help yourself and others every time changes are needed within the flow. 46 46 47 - ===3.1Volume===39 +Annotations can be used for: 48 48 49 -The first Type available to you is Volume. With this option, you create one or more folders on Docker relevant to that runtime to read and write **persistent** data. To configure this Type, you need to link the runtime volume to a machine volume you can create within the same pop-up. This means you can re-use a "Machine volume" over multiple runtimes (i.e., containers). 41 +* Describing a best practice everyone should follow 42 +* Describing (more complex) parts of the flow 43 +* Describe (parts of) your message definitions 50 50 51 - So,wefirstopenthetabcalled"Machinevolume."Then,bypressingthe"New"button,wecan defineanew"Machinevolume."In thepop-upthatfollows,wecan specifythe nameof amachinevolume and tellwhethertheVolumealreadyexistsonyour dockerinstallation ornot.45 +To clarify the use cases let us take a look at how annotations can be added within the eMagiz platform. In our first example, we will take a look at asynchronous routing. In many eMagiz projects, a best practice is followed on how to add something to the asynchronous routing (or change something within the asynchronous routing). Because the best practice contains multiple steps it makes sense to use the annotation functionality of eMagiz to define all these steps and register them at the place you need them (i.e. the asynchronous routing). Having done so will result in something like this: 52 52 53 - [[image:Main.Images.Microlearning.WebHome@novice-file-based-connectivity-volume-mapping-on-premise--machine-volumes-configuration.png]]47 +<p align="center">[[image:novice-devops-perspectives-annotations--annotation-best-practice-async-routing.png||]]</p> 54 54 55 - Onceyouhavedoneso,wepress"Save"andswitchbackto the"Runtime volumes"tab. Then, wepushthe"New" button to createa new"Runtimevolume."Inthefollowing pop-up,wefirst needtoselectthe Typewewanttouse.Forthisexample, weuse theType called "Volume." Basedonyourselection,therelevant inputfields willchange.49 +The second example is about using annotations on the flow level to describe parts of the flow. In this example, we will use the annotation to describe that we use a filter to determine which messages are picked up from a local directory and how we filter. That way anyway opening the flow has to merely read the annotation to get the context. Having done so will result in something like this: 56 56 57 - [[image:Main.Images.Microlearning.WebHome@novice-file-based-connectivity-volume-mapping-on-premise--runtime-volumes-configuration-type-volume.png]]51 +<p align="center">[[image:novice-devops-perspectives-annotations--describe-parts-of-flow.png||]]</p> 58 58 59 -The firstthingweneedtoselectisthe"Machinevolume."Oncewehavechosen our"Machinevolume,"wemust settheTargetspecificforthisruntime.Thistargetdefinesthe secondpart ofthe pathtowhichtheruntimewill gainccess.Forexample, whenyoufillin"/target",we cancombinethiswithhe"Machinevolume" nametoarrive atthecorrectdirectoryfromwhich eMagiz needsto readdata(orwrite data to).Soin our case,this wouldbe"/file-directory/target."53 +The third example does not take place on the flow level but the message definition level. Therefore instead of going to Create, we go to Design. In Design when you navigate to the CDM, API Gateway Data model, Event Streaming Data model, message definitions, etc. you have the option to add annotations to the canvas. In this example, we want to make clear to all that make changes that a certain part of our CDM is used by a lot of integrations within eMagiz and therefore everyone should be careful and think twice before adjusting anything related to that part. Having done so will result in something like this: 60 60 61 - Thelast settingweneed toconfigureisto define whichrights wewill grantour runtimeon theVolumewe arereating. Thedefaultsetting isread/writerightsforthe runtime, which is sufficient in most cases. The resultfollowing these steps will be the following.55 +<p align="center">[[image:novice-devops-perspectives-annotations--describe-crucial-part-of-cdm.png||]]</p> 62 62 63 - [[image:Main.Images.Microlearning.WebHome@novice-file-based-connectivity-volume-mapping-on-premise--runtime-volumes-configuration-type-volume-filled-in.png]]57 +Now that we saw some examples let us turn our attention to the how. How can I add an annotation and how can I link it. Adding the annotation is simple. You drag the annotation icon from the left context menu onto the canvas. As a result, an empty annotation will be shown on the canvas. By double-clicking on it you can type whatever you want. Note that you need to be in "Start Editing" mode to change anything, including annotations. 64 64 65 - {{warning}}Notethat when you use the Volume option, theexternal system with which you exchangedata on-premisevia a file-basedmethod needsto beableto writeor readthe data from the Volume (i.e., directory) you have configured inDocker. Shouldthis beaproblem,the Bind mount alternative discussed below should beconsidered.{{/warning}}59 +<p align="center">[[image:novice-devops-perspectives-annotations--annotation-icon-context-menu.png||]]</p> 66 66 67 - ===3.2Bind mount===61 +When you are satisfied with what you have written down you can press the Save button. After you have done so you can rescale the annotation to ensure that the complete text is visible. To link the annotation to a component (on flow level) or an entity (on message definition level) you hover over the annotation until your mouse indicator changes to a + icon, execute a right-click and drag from the annotation to the component in question. 68 68 69 - An alternativeoptiontoread andwrite**persistent** datais to use the "Bind mount"option. In general, we advise usingthe "Volume" optionbecausethey have betterperformance,and bind mountsdependon the host machine's directorystructureandOS. However,onlysomeexternal systemscan adapttothisthateasily.Forexample, the "Bindmount" option can interest youruse case.63 +Now you know what annotations are good for and how you can add them within the eMagiz platform. 70 70 71 - [[image:Main.Images.Microlearning.WebHome@novice-file-based-connectivity-volume-mapping-on-premise--runtime-volumes-configuration-type-bind-mount.png]]65 +===== Practice ===== 72 72 73 -To configure a "Bind mount," you need to define a source and a target directory linked to each other. The source directory represents the directory on your local system (that might already be used currently to exchange files). The target directory defines a directory on your docker installation that the runtime can access. 74 - 75 -{{warning}}Note that when the source directory does not exist, the runtimes cannot be deployed correctly. One of the following two configurations displayed below are needed to find the source directory: 76 -* /mnt/host/{local-directory} 77 -* /run/desktop/mnt/host/{local-directory}{{/warning}} 78 - 79 -[[image:Main.Images.Microlearning.WebHome@novice-file-based-connectivity-volume-mapping-on-premise--runtime-volumes-configuration-type-bind-mount-filled-in.png]] 80 - 81 -{{info}}Note that when you use this option, your directory reference in your flow should refer to the "target" directory configured here.{{/info}} 82 - 83 -=== 3.3 Temporary file system === 84 - 85 -The temporary file system option is for you if you do not want to work with **persistent** data but require **non-persistent** data. This way, you can increase the container's performance by avoiding writing into the container's writable layer. 86 - 87 -[[image:Main.Images.Microlearning.WebHome@novice-file-based-connectivity-volume-mapping-on-premise--runtime-volumes-configuration-type-temp-file-storage.png]] 88 - 89 -To configure this option, you need a target location. On top of that, you can define the maximum size of the temporary file system. 90 - 91 -[[image:Main.Images.Microlearning.WebHome@novice-file-based-connectivity-volume-mapping-on-premise--runtime-volumes-configuration-type-temp-file-storage-filled-in.png]] 92 - 93 -{{warning}}We strongly advise you to define this number so that you can limit the potential impact this solution can have on the stability of your machine.{{/warning}} 94 - 95 -=== 3.4 Named pipe === 96 - 97 -The named pipe option can be selected, but we yet have to see a valid use case within the context of eMagiz for using this option. Therefore we won't discuss this option further in this microlearning. 98 - 99 99 == 4. Assignment == 100 100 101 - Navigate to Deploy ->Architectureand look atthe Volume mappingoptions,readthehelptexts, and playaround withhesettings (ifitis notacustomerenvironment).102 -This assignment can be completed with the help of the (Academy) project you created/used in the previous assignment. 69 +Add annotation on the flow level that describes how (a part of) a flow works. 70 +This assignment can be completed with the help of the (Academy) project that you have created/used in the previous assignment. 103 103 104 104 == 5. Key takeaways == 105 105 106 -* File-based communication on-premise changes in the new runtime architecture 107 -* There are two ways to store **persistent** data 108 - ** Volume 109 - ** Bind mount 110 -* The Volume option is considered the best alternative because they have better performance, and bind mounts are dependent on the directory structure and OS of the host machine 111 -* When you want to deal with **non-persistent** data, the Temporary file storage option is the way to go. 74 +* Annotations can be used for: 75 + * Describing a best practice everyone should follow 76 + * Describing (more complex) parts of the flow 77 + * Describe (parts of) your message definitions 78 +* You can add annotations by dragging and dropping the annotation icon on the canvas. 112 112 80 + 81 + 113 113 == 6. Suggested Additional Readings == 114 114 115 - Ifyouareinterested inthis topic and wantmoreinformation, pleasereadthehelptext provided by eMagiz.84 +There are no suggested additional readings on this topic 116 116 117 117 == 7. Silent demonstration video == 118 118 119 -This video demonstrates how you could have handled the assignment and gives context to what you have just learned.88 +This video demonstrates how you could have handled the assignment and gives you some context on what you have just learned. 120 120 121 - TBA90 +<iframe width="1280" height="720" src="../../vid/microlearning/novice-devops-perspectives-annotations.mp4" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe> 122 122 123 -)))((({{toc/}}))){{/container}}{{/container}} 92 +</div> 93 + 94 +</div> 95 +</div> 96 + 97 +{{/html}}
- novice-devops-perspectives-annotations--annotation-best-practice-async-routing.png
-
- Author
-
... ... @@ -1,0 +1,1 @@ 1 +XWiki.marijn - Size
-
... ... @@ -1,0 +1,1 @@ 1 +25.7 KB - Content
- novice-devops-perspectives-annotations--annotation-icon-context-menu.png
-
- Author
-
... ... @@ -1,0 +1,1 @@ 1 +XWiki.marijn - Size
-
... ... @@ -1,0 +1,1 @@ 1 +774 bytes - Content
- novice-devops-perspectives-annotations--describe-crucial-part-of-cdm.png
-
- Author
-
... ... @@ -1,0 +1,1 @@ 1 +XWiki.marijn - Size
-
... ... @@ -1,0 +1,1 @@ 1 +15.5 KB - Content
- novice-devops-perspectives-annotations--describe-parts-of-flow.png
-
- Author
-
... ... @@ -1,0 +1,1 @@ 1 +XWiki.marijn - Size
-
... ... @@ -1,0 +1,1 @@ 1 +18.9 KB - Content