Last modified by Martijn Woudstra on 2022/08/30 15:42

Show last authors
1 {{container}}{{container layoutStyle="columns"}}(((
2
3 With the help of the eMagiz Mendix module created by the eMagiz team, you can easily connect between Mendix and eMagiz for data integration. In this microlearning, we will focus on calling a synchronous web service from Mendix.
4
5 Should you have any questions, please get in touch with [[academy@emagiz.com>>mailto:academy@emagiz.com]].
6
7 == 1. Prerequisites ==
8
9 * Intermediate knowledge of the eMagiz platform
10 * Access to a Mendix application
11 * Access to the Deploy phase of your eMagiz project
12 * A connection between Mendix and eMagiz Designed and Created
13 * Using eMagiz Mendix version 5.0.0 or higher.
14
15 == 2. Key concepts ==
16
17 This microlearning centers around calling a synchronous web service from Mendix
18 With eMagiz Mendix Connector, we mean: A Mendix module developed and maintained by eMagiz that simplifies connect a Mendix application to an eMagiz project for data traffic between both systems.
19
20 To call a synchronous web service from Mendix, you need the following:
21
22 * Export object (including mapping)
23 * Name of the queue on which you want to publish the data
24 * Import object (including mapping)
25
26 == 3. Calling a synchronous web service from Mendix ==
27
28 With the help of the eMagiz Mendix module created by the eMagiz team, you can easily connect between Mendix and eMagiz for data integration. In this microlearning, we will focus on calling a synchronous web service from Mendix. For sending data to eMagiz, we offer the following options to send data to the queue:
29
30 * Send a message and receive a single response
31 * Send a message and receive a list response
32
33 === 3.1 Sending synchronous messages and returning a single object ===
34
35 [[image:Main.Images.Microlearning.WebHome@intermediate-mendix-connectivity-calling-an-asynchronous-webservice-from-mendix-send-sync-message-single-object-java.png]]
36
37 === 3.1.1 Request ===
38
39 1. Request Mapping parameter * Mendix Domain Model object to export JSON or XML using specified export mapping
40 2. Request Export mapping * Contains the export mapping from domain model object to XML or JSON
41 3. Validate Request * Whether request should be validated or not
42 4. Request Queue * enter the proper value for the onramp request queue of eMagiz where the request message needs to be put on.
43
44 === 3.1.2 Response ===
45
46 1. Response queue * enter the proper value for the onramp queue of eMagiz where the response message needs to be picked up from
47 2. Validate Response * Whether response should be validated or not
48 3. Response import mapping * Mapping object from XML/JSON to domain model object
49 4. Response Object type * Output domain model object of the import mapping and input for the microflow
50
51 === 3.2 Sending synchronous messages and returning a list ===
52
53 [[image:Main.Images.Microlearning.WebHome@intermediate-mendix-connectivity-calling-an-asynchronous-webservice-from-mendix-send-sync-message-single-object-java.png]]
54
55 === 3.1.1 Request ===
56
57 1. Request Mapping parameter * Mendix Domain Model object to export JSON or XML using specified export mapping
58 2. Request Export mapping * Contains the export mapping from domain model object to XML or JSON
59 3. Validate Request * Whether request should be validated or not
60 4. Request Queue * enter the proper value for the onramp request queue of eMagiz where the request message needs to be put on.
61
62 === 3.1.2 Response ===
63
64 1. Response queue * enter the proper value for the onramp queue of eMagiz where the response message needs to be picked up from
65 2. Validate Response * Whether response should be validated or not
66 3. Response import mapping * Mapping object from XML/JSON to domain model object
67 4. Response Object type * Output domain model object of the import mapping and input for the microflow
68
69 == 4. Assignment ==
70
71 The assignment is simple this time. Configure a microflow that sends data to an onramp. Ideally, work on both options.
72 This assignment can be completed with the help of an associated Mendix project linked to the (Academy) project that you have created/used in the previous assignment.
73
74 == 5. Key takeaways ==
75
76 To call a synchronous web service from Mendix, you need the following:
77
78 * Export object (including mapping)
79 * Name of the queue on which you want to publish the data
80 * Import object (including mapping)
81
82 Note: To make a connection in allowing data to travel between A and B, you need to fill in the correct constants and set up your Keystore and Truststore correctly. For more information check out this [course](novice-mendix-connectivity-index.md)
83
84 == 6. Suggested Additional Readings ==
85
86 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.
87
88 == 7. Silent demonstration video ==
89
90 As most of this configuration occurs in Mendix and not in eMagiz, we have chosen not to make a video on this topic.
91 The pictures and text provided above should give you enough guidance to configure the connection between Mendix and eMagiz.
92
93 )))((({{toc/}}))){{/container}}{{/container}}