Ewon TechForum
Providing technical solutions to technical requests


Using Java to send IO values to Azure
rnicola Away
Junior Member
#1
Hello Everyone, 

I am completely new to the use of the Ewon Flexy 205 and have a few questions in regards to setting up the Ewon properly to sending JSON formatted files to a Azure database. 

Firstly, I see that there is a MQTT -> Azure JAVA package available that can be FTP transferred to the Flexy 205 and configured. My flexy now has the AZURE IOT IO server running, so that has already been placed within the Flexy.

Second, how do I properly point this IO server at the Azure database? I see that the Flexy receives a unique Certificate and Key, but doe it also need a unique address to be pointed at the Azure instance?

Lastly, this Flexy 205 (per request of the end user) will not be using Talk2M. Since it will be on a different network than their Azure server, how do I setup this connection? Does it need a VPN? How is a third party VPN configured if needed?

If there is any documentation in regards to these topics, that would be greatly appreciated. The end goal is to setup multiple Flexy's across multiple job sites that all communicate back to Azure so that data can be collected off the IO. 


Thank you for your time.
Reply

simon Offline
eWON Support
#2
Hi Micola,

First, if you configure the Flexy to push data to the Azure IOTHub (through MQTT using BASIC or JAVA programs, like my IOServer), you do not need any VPN.
The Azure IOT IOserver uses the URL : IotHubName + ".azure-devices.net"
So the URL depends on the IOT Hub name.

Simon
Reply

LewisH304 Offline
Junior Member
#3
static EventData create(byte[] data)
Construct EventData to Send to EventHubs. Typical pattern to create a Sending EventData is:
i. Serialize the sending ApplicationEvent to be sent to EventHubs into bytes.
ii. If complex serialization logic is involved (for example: multiple types of data) - add a Hint using the getProperties() for the Consumer.

Sample Code:

EventData eventData = EventData.create(telemetryEventBytes);
eventData.getProperties().put("eventType", "com.microsoft.azure.monitoring.EtlEvent");
partitionSender.Send(eventData);

Parameters:
data - the actual payload of data in bytes to be Sent to EventHubs.
Returns:
EventData the created EventData to send to EventHubs.
See Also:
EventHubClient.create(String, ScheduledExecutorService)
Reply



Possibly Related Threads…
04-04-2020, 11:51 AM
Last Post: LewisH304
  Java 1.4 update Started by tomT
12 Replies - 1.745 Views
24-03-2020, 09:08 PM
Last Post: hernfiry
13-03-2020, 01:12 PM
Last Post: simon
05-03-2020, 02:11 PM
Last Post: simon
03-03-2020, 11:35 PM
Last Post: simon
31-01-2020, 05:27 PM
Last Post: simon
  JAVA Azure IOTHub Connector Started by simon
1 Replies - 1.008 Views
11-12-2019, 12:19 PM
Last Post: simon
10-12-2019, 05:50 AM
Last Post: Kanduri Shouri
  Download Java ETK 1.4.3 Started by woodyjon
2 Replies - 401 Views
14-11-2019, 10:13 AM
Last Post: woodyjon
30-10-2019, 07:52 PM
Last Post: IceControls



Users browsing this thread:
1 Guest(s)



Theme © Ewon 2019 - Forum software by © MyBB - Cookie policy