Last modified by Erik Bakker on 2025/03/02 09:21

Show last authors
1 {{container}}{{container layoutStyle="columns"}}(((
2 In this microlearning, we will integrate Mendix with eMagiz using the eMagiz Mendix module. Here, we will guide you through calling a synchronous queue in Mendix, essential for efficient data exchange between your systems.
3
4 Should you have any questions, please get in touch with [[academy@emagiz.com>>mailto:academy@emagiz.com]].
5
6 == 1. Prerequisites ==
7
8 * Intermediate knowledge of the eMagiz platform
9 * Access to a Mendix application (potentially via an external party)
10 * Access to the Deploy phase of your eMagiz project
11 * A connection between Mendix and eMagiz Designed, Created, and in the active release
12 * Using the "eMagiz Connector" in the Mendix Marketplace.
13 * Initial [[installation>>doc:Main.eMagiz Academy.Microlearnings.Novice.Mendix Connectivity.novice-mendix-connectivity-install-emagiz-mendix-connector.WebHome||target="blank"]] done.
14 * Initial [[configuration>>doc:Main.eMagiz Academy.Microlearnings.Novice.Mendix Connectivity.novice-mendix-connectivity-configure-emagiz-mendix-connector.WebHome||target="blank"]] done.
15
16 == 2. Key concepts ==
17
18 This microlearning centers around calling a synchronous queue in Mendix.
19 * With eMagiz Connector, we mean A Mendix module developed and maintained by eMagiz that simplifies connecting a Mendix application to an eMagiz project for data traffic between both systems.
20
21 To call a synchronous queue in Mendix, you need the following:
22
23 * The destination (i.e., the queue from which you want to retrieve the information)
24 * Execute microflow (the microflow that will process the incoming data)
25 * Optionally, you can define an import mapping and subsequent options.
26
27 {{warning}}All changes in eMagiz need to be activated by adding the changes to the eMagiz release and activating said release. When setting up the initial connection, the Mendix system must be **in** the eMagiz release before connecting from Mendix to eMagiz with an **activation key**.{{/warning}}
28
29 == 3. Calling a synchronous queue in Mendix ==
30
31 With the help of the Mendix module (called eMagiz Connector) created by the eMagiz team, you can easily connect between Mendix and eMagiz for data integration. This microlearning will focus on calling a synchronous queue in Mendix. For sending data to Mendix, we offer three options to send data:
32
33 * Using the import and export mapping to send data to Mendix.
34 * Sending a string to and from Mendix without using the import and export mapping.
35
36 Below, we will detail how to configure each option for sending data synchronously to Mendix.
37
38 === 3.1 Sending synchronous messages with import and export mapping ===
39
40 To send data to Mendix, you must define several configuration options in the Mendix project. In this example, we will look at the configuration using the import and export mapping in Mendix. In the subsequent paragraph, we will look at configuring the exit if you do **not** want to use the import and export mapping.
41
42 In eMagiz, you will see a flow in Create that you cannot edit, as the autogenerated functionality provided by eMagiz is all you need. Once done, make sure the flow is transported to Deploy and ready to be used in a Mendix application by adding it to a release.
43
44 {{info}}The exit version must be altered when you change your system messages in Design.{{/info}}
45
46 In parallel, earlier or later, the Mendix application needs to be developed to handle the message's consumption and respond to the request with a response mapping. This is done by adding the following configuration to the existing "After Startup" microflow.
47
48 ==== 3.1.1 Startup action ====
49 In Mendix, you must add the "StartSyncMessageConsumer" Java Action to the after startup flow. The most important configuration items here are the following.
50
51 [[image:Main.Images.Microlearning.WebHome@intermediate-mendix-connectivity-calling-a-synchronous-webservice-in-mendix-start-consumer.png]]
52
53 * The destination (i.e., the queue from which you want to consume the **request** messages). This can be supplied by the eMagiz developer or found under Deploy -> Mendix Connectors should you have access to the eMagiz model in question.
54 * The export and import mapping (based on the system message definitions). These definitions can be determined by the eMagiz developer (and then shared with the Mendix developer) or determined by the Mendix developer (and then shared with the eMagiz developer).
55 * The microflow that handles the incoming message and returns a result.
56
57 [[image:Main.Images.Microlearning.WebHome@intermediate-mendix-connectivity-calling-a-synchronous-webservice-in-mendix-on-receive-microflow-config.png]]
58
59 === 3.2 Sending synchronous messages without import and export mapping ===
60
61 We just saw the example when working with the import and export mapping. Now we turn our attention to an instance without those mappings. In these cases, the string is just passed to the execute microflow, and you can determine in Mendix yourself what to do with it. The same applies to the export part of the logic.
62
63 In eMagiz, you will see a flow in Create that you cannot edit, as the autogenerated functionality provided by eMagiz is all you need. Once done, make sure the flow is transported to Deploy and ready to be used in a Mendix application by adding it to a release.
64
65 {{info}}The version of your exit needs to be altered when you make changes to your system messages in Design.{{/info}}
66
67 In parallel, earlier or later, the Mendix application needs to be developed to handle the consumption of the message and respond to the request with a response mapping. This is done by adding the following configuration to the existing "After Startup" microflow.
68
69 ==== 3.2.1 Startup action ====
70 In Mendix, you must add the "StartSyncStringConsumer" Java Action to the after startup flow. The most important configuration items here are the following.
71
72 [[image:Main.Images.Microlearning.WebHome@intermediate-mendix-connectivity-calling-a-synchronous-webservice-in-mendix-start-consumer-string.png]]
73
74 * The destination (i.e., the queue from which you want to consume the **request** messages). This can be supplied by the eMagiz developer or found under Deploy -> Mendix Connectors should you have access to the eMagiz model in question.
75 * The microflow that handles the incoming message and returns a result.
76
77 [[image:Main.Images.Microlearning.WebHome@intermediate-mendix-connectivity-calling-a-synchronous-webservice-in-mendix-on-receive-microflow-config-string.png]]
78
79 == 4. Key takeaways ==
80
81 To call a synchronous queue in Mendix, you need the following:
82
83 * The destination (i.e., the queue from which you want to retrieve the information)
84 * Execute microflow (the microflow that will process the incoming data)
85 * Optionally, you can define an import mapping and subsequent options.
86
87 {{warning}} To make a connection in allowing data to travel between A and B, you need to [[install>>doc:Main.eMagiz Academy.Microlearnings.Novice.Mendix Connectivity.novice-mendix-connectivity-install-emagiz-mendix-connector.WebHome||target="blank"]] and do a basic [[configuration>>doc:Main.eMagiz Academy.Microlearnings.Novice.Mendix Connectivity.novice-mendix-connectivity-configure-emagiz-mendix-connector.WebHome||target="blank"]] before you can set up this specific communication.{{/warning}}
88
89 == 5. Suggested Additional Readings ==
90
91 If you are interested in this topic and want more information, please read the release notes provided by eMagiz that accompany the eMagiz Mendix Connector version you have selected. Furthermore, check out these links:
92
93 * [[Novice Level (Menu)>>doc:Main.eMagiz Academy.Microlearnings.Novice.WebHome||target="blank"]]
94 ** [[Mendix Connectivity (Navigation)>>doc:Main.eMagiz Academy.Microlearnings.Novice.Mendix Connectivity.WebHome||target="blank"]]
95 * [[Mendix Connectivity (Search Results)>>url:https://docs.emagiz.com/bin/view/Main/Search?sort=score&sortOrder=desc&highlight=true&facet=true&r=1&f_space_facet=0%2FMain.&l_space_facet=10&f_type=DOCUMENT&f_locale=en&f_locale=&f_locale=en&text=%22mendix+connectivity%22||target="blank"]]
96
97 )))((({{toc/}}))){{/container}}{{/container}}