Changes for page Communication between models
Last modified by Erik Bakker on 2024/09/05 14:00
From version 17.1
edited by Erik Bakker
on 2022/07/28 10:54
on 2022/07/28 10:54
Change comment:
There is no comment for this version
To version 8.1
edited by Erik Bakker
on 2022/07/26 12:49
on 2022/07/26 12:49
Change comment:
There is no comment for this version
Summary
-
Page properties (3 modified, 0 added, 0 removed)
Details
- Page properties
-
- Title
-
... ... @@ -1,1 +1,1 @@ 1 - Communicationbetween models1 +Image Transformations - Default language
-
... ... @@ -1,1 +1,0 @@ 1 -en - Content
-
... ... @@ -1,5 +1,5 @@ 1 1 {{container}}{{container layoutStyle="columns"}}((( 2 - When yourintegrationlandscapegrowsthroughtime, youmightdecideto splitfunctionalbusinessprocessesintomultipleeMagizmodels.Inthosecases,the question ofconnectingthesemodels easily,stable,and securelycould arise. Thismicrolearningwillfocusonhatquestionandprovideananswer basedon ourvisionand bestpractices whendealingwiththe platform.2 +In most cases, you will transform XML messages to other XML messages, or you will transform JSON or EDI messages in another of these formats. However, sometimes you want to perform an image transformation. With this image transformation you can transform images in certain formats to another format (i.e. png). This can come in handy when you want to standardize the image format before using it further downstream in your business application(s). 3 3 4 4 Should you have any questions, please get in touch with [[academy@emagiz.com>>mailto:academy@emagiz.com]]. 5 5 ... ... @@ -9,50 +9,51 @@ 9 9 10 10 == 2. Key concepts == 11 11 12 -This microlearning focuses on communicationbetween two eMagizmodels. When communicating to any external party (fromhe viewof a specific model), you should always considerthe following:12 +This microlearning focuses on performing image transformations in eMagiz. 13 13 14 -* Security 15 -* Loose coupling 16 -* Maintainability 17 -* Clarity 14 +With image transformation, we mean transforming the raw data that represents an image to another image format. 18 18 19 -== 3. Communication between models == 16 +* Read the helptext of the component to understand which formats are supported 17 +* Ensure the input image is supplied in the correct format 18 +* Ensure you wrap the output image in something if you want to do additional transformations on the data further downstream 20 20 21 - Inalow-code platformlike eMagiz, you want to preventusing custom scriptingas much as possible. However, sometimes inpractice, you encountersituations that cannot be realized with the standard toolbox provided within the platform. Asaresult, we offer the optionto use a Groovy script in these situations to achieve the desired solution. In this microlearning, we will look at where you can use a Groovy script and discuss the key considerations when implementing a Groovy script within your model.20 +== 3. Image Transformation == 22 22 23 - Mostuserswouldthinkthat communicationviaqueuestoconnecttwoseparateeMagiz models isabrightidea. However, this issomethingthatwedonotencourage.We discourage thisforveralpracticaland technicalreasons alike.22 +In most cases, you will transform XML messages to other XML messages, or you will transform JSON or EDI messages in another of these formats. However, sometimes you want to perform an image transformation. With this image transformation you can transform images in certain formats to another format (i.e. png). This can come in handy when you want to standardize the image format before using it further downstream in your business application(s). 24 24 25 - When looking at the practical side ofthings getting it configuredcorrectlyis time-consuming andan error-prone action (as is evidentby the question). Furthermore,itcan leadto unexpected situationswhere youmake a typo tolisten toa queue onwhich no messages are provided. This queue will, however, beregistered on the JMS level (when you activatethe flow in questionwith the customconfiguration),which can lead toconfusing queue statistics andven moretroublesomefalse-positive alerting basedon missingqueue metrics or missing consumers.24 +Before we dive into the specifics of how to configure this let us first consider the following: 26 26 27 -On top of that, when you allow one model to write and read from queues registered in another model, maintaining both models will become very complex. This holds for the ones working on the project at the moment but also for those working on it at a later stage and does that need to provide (incidental) support on the environments. 26 +* Read the helptext of the component to understand which formats are supported 27 +* Ensure the input image is supplied in the correct format 28 +* Ensure you wrap the output image in something if you want to do additional transformations on the data further downstream 28 28 29 - Anotherpracticalreason forot wantingthisisthat wedo not activelysupport this use case fromMagiz.This means thatwhenweupdate ourtechnicalinfrastructure,wewillnotconsiderthisscenario.Thiscould leadtoadditionalworkintheutureandreducedstabilityof yoursolution.30 +{{warning}}The focus of this microlearning lies on the image transformer component. Ensuring that the input is useful and the output fits the remainder of the process is highly depending on the use case and will therefore not be discussed in this microlearning{{/warning}} 30 30 31 - From the technical pointofview,theconsequenceof thisconstructionisthat both modelsneed toknoweachothercertificatesandcredentials,whicharenotconsideredsecure. Ontopofthat, becauseyou, theoretically,canexchangeatafromanyqueuetoany queue, you could createasituation in whichupdates inonemodel triggerchanges intheothermodel(i.e.,when usingthe same data model) that arenexpected (and frankly unwanted).32 +When turning to the Create phase of eMagiz, we need to open the flow and enter "Start Editing" mode to add the component we need. For example, in the left panel, you can search for "Image". This will yield the following result. 32 32 33 -We advise using functionality that makes it explicit that both models function independently of each other. From eMagiz, we consider two valid alternatives for this: 34 -- Using a web service as a communication layer between the two models. This web service can be REST or SOAP and has been implemented before 35 -- Using the Event Streaming functionality of eMagiz to write and read from topics. 34 +[[image:Main.Images.Microlearning.WebHome@expert-create-your-transformations-image-transformation-image-transformation-component.png]] 36 36 37 -Both alternatives have the benefit that the security can be tight and explicit (i.e., only model A can write/post data to model B). Furthermore, managing the solution becomes much easier as it uses the standard functionality within the platform. Therefore, we have no plans to support this approach in the product. 38 - 39 39 == 4. Assignment == 40 40 41 -C onsiderwhatyourcriteriaarewhencommunicatingbetweenmodels andcomparethemtoourcriteria.42 -This assignment can be completed with the help of the(Academy) project you created/used in the previous assignment.38 +Check out which of the XPaths we have discussed today can be found within your project. 39 +This assignment can be completed within the (Academy) project you created/used in the previous assignment. 43 43 44 44 == 5. Key takeaways == 45 45 46 -* Consider the following when communication between two models 47 -** Security 48 -** Loose coupling 49 -** Maintainability 50 -** Clarity 43 +Some of the very complex XPath options are: 51 51 45 +* matches 46 +* replace 47 +* tokenize 48 + 52 52 == 6. Suggested Additional Readings == 53 53 54 -If you are interested in this topic and want more information, please consultusat[[productmanagement@emagiz.com>>mailto:productmanagement@emagiz.com]]51 +If you are interested in this topic and want more information on it, please read the help text provided by eMagiz and read more information on the following links: 55 55 53 +* http://www.xsltfunctions.com/xsl/fn_matches.html 54 +* http://www.xsltfunctions.com/xsl/fn_replace.html 55 +* http://www.xsltfunctions.com/xsl/fn_tokenize.html 56 + 56 56 == 7. Silent demonstration video == 57 57 58 58 As this is more of theoretical microlearning, there is no video accompanying the microlearning.)))((({{toc/}}))){{/container}}{{/container}}