Thanks Lynn, I got what you mean.
Original Message:
Sent: 12-30-2019 01:23 AM
From: Lynn Williams
Subject: CA Gen & SOAP with attachments
... just to be clear you can use CALL EXTERNAL on either Java client or Java server but my main point was that with the pull approach you can be using the Gen client to control the overall processing sequence.
------------------------------
Lynn Williams
Senior Principal Support Engineer
Broadcom
Australia
Original Message:
Sent: 12-30-2019 01:17 AM
From: Lynn Williams
Subject: CA Gen & SOAP with attachments
Hi @Saeed Almutairi,
Yes if the 3rd party can provide a similar style of web service where BLOB data is available as Base64Binary (instead of via file attachment), then per @AMIT KUMAR DWIVEDI 's initial reply the Gen CALL EXTERNAL function could then be used to access it. In that case you can revert to your original plan to pull the 3rd party data from the Gen client application, which is probably simpler in terms of controlling the overall processing sequence because it is all under the control of the Gen client.
Regards,
Lynn
------------------------------
Lynn Williams
Senior Principal Support Engineer
Broadcom
Australia
Original Message:
Sent: 12-30-2019 01:00 AM
From: Saeed Almutairi
Subject: CA Gen & SOAP with attachments
Thanks Lynn.
Things are now clearer for me. But again, if Gen can receive a Base64Binary (BLOB) then I believe I could ask the 3rd party to provide a SOAP web service and I can consume it to receive the image as Base64Binary format in an import view defined as BLOB in Gen client? Is that applicable?
Original Message:
Sent: 12-29-2019 05:39 PM
From: Lynn Williams
Subject: CA Gen & SOAP with attachments
Hi @Saeed Almutairi,
1. There is no support for creating an EJB SOAP Web Service with attachments. I justed checked what the generated wsdl would look like for an EJB with import view containing a BLOB attribute. The BLOB data type is base64Binary per below extract, so the 3rd party would just need to send the binary data and the EJB would then store it in the database as a BLOB:
===
<xs:complexType name="S1Import">
<xs:sequence>
<xs:element minOccurs="0" name="InE1">
<xs:complexType>
<xs:sequence>
<xs:element name="Blob1" type="xs:base64Binary"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
...
</xs:complexType>
===
2. To display the BLOB data as an image on the Java client will probably require online code/EAB. This tutorial section for the egolf model "Using BLOB in Applications" covers reading the BLOB data from server, then using an EAB to write it to a file and finally using an OCX control "Chestysoft csXImage" to display it as an image:
https://techdocs.broadcom.com/content/broadcom/techdocs/us/en/ca-mainframe-software/devops/ca-gen/8-6/tutorial/using-blob-in-applications.html
As stated there are some limitations using OLE/OCX controls with Web Generation Java clients but that method may still be valid
https://techdocs.broadcom.com/content/broadcom/techdocs/us/en/ca-mainframe-software/devops/ca-gen/8-6/distributed-processing/working-with-web-generation/unsupported-features-in-web-generation.html
Other community users might also have experiences they can share on displaying BLOB data as images in Gen Web Generation Java clients.
I hope that information helps.
Regards,
Lynn
------------------------------
Lynn Williams
Senior Principal Support Engineer
Broadcom
Australia
Original Message:
Sent: 12-28-2019 12:36 PM
From: Saeed Almutairi
Subject: CA Gen & SOAP with attachments
@Lynn Williams To keep that approach makes sense, I'm wondering if CA Gen supports creating a SOAP with attachments web service to let the 3rd party consumer to push the image then Gen can receive it in BLOB attribute?
If not, then the 3rd party may encode the image to Base64 string and send it to Gen SOAP web service; but here I should assume that Gen has the capability to decode the Base64 string to image. Is that possible? or we need to write inline code in Java?
Original Message:
Sent: 12-26-2019 06:22 PM
From: Lynn Williams
Subject: CA Gen & SOAP with attachments
Hi Saeed,
In effect yes - in that diagram you have the 3rd Party application providing the input data by calling the Gen server EJB Web Service.
I would assume that prior to Step 1, your Gen client would initially call the Gen server to check if data is already there for the Person_Number (Step 0) and if not present then go to the 3rd Party application (Step 1/2) which will then send the data to the Gen server (Step 3/4).
For Step 5 (after some delay to allow EJB to receive the 3rd Party data) your Gen client would then need to call the Gen server again (repeat Step 0) to get the new data.
Regards,
Lynn
------------------------------
Lynn Williams
Senior Principal Support Engineer
Broadcom
Australia
Original Message:
Sent: 12-26-2019 05:49 PM
From: Saeed Almutairi
Subject: CA Gen & SOAP with attachments
Thanks Lynn,
Please check out the diagram, is that what you meant? Please confirm?
Original Message:
Sent: 12-26-2019 04:56 PM
From: Lynn Williams
Subject: CA Gen & SOAP with attachments
Hi Saeed,
Are you constrained by having to pull this data from the 3rd party external source or can that 3rd party push the data to your Gen application?
If a push is feasible you can create an EJB Web Service for your Gen Java server with in import BLOB view & then provide access to that Web Service to the 3rd party.
Regards,
Lynn
------------------------------
Lynn Williams
Senior Principal Support Engineer
Broadcom
Australia
Original Message:
Sent: 12-26-2019 02:37 PM
From: Saeed Almutairi
Subject: CA Gen & SOAP with attachments
Thanks Amit.
So in this case, what's the best practice to do that; i mean to receive a person's image and display it in CA Gen java web application?
Original Message:
Sent: 12-26-2019 01:48 PM
From: Amit Dwivedi
Subject: CA Gen & SOAP with attachments
Hi Saeed,
No, CA Gen does not support calling a SOAP web service with attachment using call external statement, though you could use blob to send/receive binary data.
Regards,
Amit D
Original Message:
Sent: 12-26-2019 11:23 AM
From: Saeed Almutairi
Subject: CA Gen & SOAP with attachments
Can CA Gen supports calling a SOAP web service with attachments?