HERE Interface configuration
The configuration of HERE interface is set through a subset of information stored in the file:
/opt/ptv-optima-vv.n.xxxxptv-optima-as/standalone/configuration/optima/optima-configuration.xml.
The configuration structure is placed under the tag <configurations>/<configuration>/<datex-interface>/<datex-process>
Example:
<datex-process id="hereDataProvider" name="Traffic State HERE" enabled="false">
<schedule>
<second>0</second>
<minute>*/1</minute>
<hour>*</hour>
<dayOfMonth>*</dayOfMonth>
<month>*</month>
<dayOfWeek>*</dayOfWeek>
<year>*</year>
</schedule>
<provider action="IMPORT" name="here_trafficstate_import" type="com.sistemaits.optima.adi.providers.here.TrafficStateHereProvider">
<hereProviderURL>https://mlreal time.traffic.data.here.com/ver3.2.2/tableE3817/RealtimeFlowE3817.xml.gz</hereProviderURL>
<userName>TBD</userName>
<password>TBD</password>
<appId>TODO</appId>
<appCode>TODO</appCode>
<maxfunctionalclass>2</maxfunctionalclass>
<bulkDimension>200</bulkDimension>
<boundingBox>
<top-left latitude="49.1" longitude="8.2" />
<bottom-right latitude="48.9" longitude="8.6" />
</boundingBox>
<confidenceValue>0.7</confidenceValue>
<timeToLiveMessage>50</timeToLiveMessage>
<validityInterval>300</validityInterval>
</provider>
<provider action="PUBLISH" name="here_trafficstate_save_on_db" type="com.sistemaits.optima.adi.providers.trafficstate.TrafficstateDbProvider">
<sqlAfter>
<query>UPDATE trafficstate_here_rltm as t set strt_shap = s.shap from strt s where s.idno=t.strt and s.tail=t.fsnd</query>
</sqlAfter>
</provider>
</datex-process>

Tag |
Type |
Description |
---|---|---|
datex-process |
XML Object |
It is associated to three attributes:
|
Example:
<datex-process id="hereDataProvider" name="Traffic State HERE" enabled="true">
.....
</datex-process>

Tag |
Type |
Description |
---|---|---|
provider |
XML Object |
It is associated to three attributes:
|
Example:
<datex-process id="hereDataProvider" name="Traffic State HERE" enabled="false">
.....
<provider action="IMPORT" name="here_trafficstate_import" type="com.sistemaits.optima.adi.providers.here.TrafficStateHereProvider">
.....
</provider>
<provider action="PUBLISH" name="here_trafficstate_save_on_db" type="com.sistemaits.optima.adi.providers.trafficstate.TrafficstateDbProvider">
.....
</provider>
</datex-process>

These tags are placed in <datex-process>/<schedule>.
Tag |
Type |
Description |
---|---|---|
second minute hour dayOfMonth month dayOfWeek year |
XML Object |
Contains tags to identify the scheduling time to query the HERE interface. You can not set the scheduler less than 1 minute. The values that you can specify are compliants to the ScheduleExpression class. Please, see the documentation: http://docs.oracle.com/javaee/6/api/javax/ejb/ScheduleExpression.html |
Example:
<datex-process id="hereDataProvider" name="Traffic State HERE" enabled="false">
<schedule>
<second>0</second>
<minute>1</minute>
<hour>*</hour>
<dayOfMonth>*</dayOfMonth>
<month>*</month>
<dayOfWeek>*</dayOfWeek>
<year>*</year>
</schedule>
.....
</datex-process>

Tag |
Type |
Description |
---|---|---|
hereProviderURL> |
String |
Contains the URL endpoint to get GZIP response with the corresponding credentials. There is not any query parameter to filter the request, but all data returned concern the area encoded directly into the URL. In the example, the code tableE3817 is referred to Netherlands. |
Example:
<datex-process id="hereDataProvider" name="Traffic State HERE" enabled="false">
....
<provider action="IMPORT" name="here_trafficstate_import" type="com.sistemaits.optima.adi.providers.here.TrafficStateHereProvider">
<hereProviderURL> https://mlreal time.traffic.data.here.com/ver3.2.2/tableE3817/RealtimeFlowE3817.xml.gz </hereProviderURL>
</provider>
....
</datex-process>

These tags are placed in <datex-process>/<provider>
Tag |
Type |
Description |
---|---|---|
userName password |
Strings |
Contains the user credentials to get data feeds. |
maxfunctionalclass |
Integer |
You can filter the data feed based on functional class, to get results faster. This is an indicator of the maximum functional class that must be matched for a traffic flow item included in the response. All items with functional class lower than or the same as the set value, are included in the response. Admitted values: maxfunctionalclass<=5 In particular:
The default value is 5. |
bulkDimension |
Integer |
In order to reduce the transaction on the DB, the imported data are grouped as a set of objects. Contains the number of the objects stored in the set. The default value is 200. |
confidenceValue |
Real |
Contains a value used to identify whether the data for a location is derived from real time probe sources or from an historical information only. Admitted values:
The default value is 0.70. |
timeToLive |
Integer |
Contains the time to live, measured in milliseconds, of a message put onto a JMS queue. The default value is 50. |
validityInterval |
Integer |
Contains the number of seconds of the time period width (period of measure validity). The default value is 300. |
Example:
<datex-process id="hereDataProvider" name="Traffic State HERE" enabled="false">
.....
<provider.....>
.....
<userName>*****</userName>
<password>*****</password>
<maxfunctionalclass>2</maxfunctionalclass>
<bulkDimension>200</bulkDimension>
<timeToLive>50</timToLive>
<confidenceValue>0.7</confidenceValue>
<validityInterval>300</validityInterval>
.....
</provider>
.....
</datex-process>

This tag is placed in <datex-process>/<provider>/<sqlAfter>
Tag |
Type |
Description |
---|---|---|
query |
String |
Contains the SQL query for updating the table TRAFFICSTATE_HERE_RLTM. Important: You can specify ONLY ONE <sqlAfter> query. |
Example:
<datex-process id="hereDataProvider" name="Traffic State HERE" enabled="false">
.....
<provider action="PUBLISH" name="here_trafficstate_save_on_db" type="com.sistemaits.optima.adi.providers.trafficstate.TrafficstateDbProvider">
<sqlAfter>
<query>UPDATE trafficstate_here_rltm as t set strt_shap = s.shap from strt s where s.idno=t.strt and s.tail=t.fsnd</query>
</sqlAfter>
</provider>
</datex-process>

Important: These tags are not used by the current version of HERE.
These tags are placed in <datex-process>/<provider>
Tag |
Type |
Description |
---|---|---|
appId appCode |
String String |
Tags containing the customer specific application identifier and code identifier. |
Example:
<datex-process id="hereDataProvider" name="Traffic State HERE" enabled="false">
.....
<provider.....>
.....
<appId>ACME_Id</appId>
<appCode>ACME_Code</appCode>
.....
</provider>
.....
</datex-process>

Important: These tags are not used by the current version of HERE.
These tags are placed in <datex-process>/<boundingBox>
Tag |
Type |
Description |
---|---|---|
top-left bottom-right |
String String |
Contains the coordinates of a spatial filter area (bounding-box) specified by two latitude, longitude pairs:
The HERE Traffic API restricts the maximum size of this spatial filter used to retrieve traffic flow data. The width and height of a bounding box must be no greater than 10 degrees of longitude and latitude. Important: Queries using larger spatial filters not result in an error response, but the amount of data returned is according to the limitations specified above. |
Example:
<datex-process id="hereDataProvider" name="Traffic State HERE" enabled="false">
.....
<provider action="IMPORT" name="here_trafficstate_import" type="com.sistemaits.optima.adi.providers.here.TrafficStateHereProvider">
.....
<boundingBox>
<top-left latitude="49.1" longitude="8.2" />
<bottom-right latitude="48.9" longitude="8.6" />
</boundingBox>
</provider>
.....
</datex-process>