Highlighted
matteo.stettner Respected Contributor.
Respected Contributor.
334 views

TimeStamp is not woking with one xml flex but with the other?

I am facing the problem that I have two xml flex connectors from which one is able to parse the TimeStamp of an expression correctly. The other one has problems to parse it correctly, though.

The one which is working looks the following:

Event:

<?xml version="1.0"?>

<Tni:LogEvents xmlns:Tni="urn:swift:Tni:ns_Tni">

<Tni:LogEvent sequence="918" dateTime="2015-08-25T12:03:46.537+00:00">

The timestamp token definition looks the floowing:

token[0].name=EventTime

token[0].type=TimeStamp

token[0].format=yyyy-MM-dd'T'HH:mm:ss.SSSZ

token[0].expression=attribute::dateTime

It is working fine when I write the EventTime token into the endTime field.

On the other hand I have a parse which is identical but somehow it is not being parsed.

Event:

<?xml version="1.0" encoding="UTF-8" ?>

<Events xmlns="urn:olpw:saa:xsd:eventjournal">

<EventReturn xmlns="urn:olpw:swz:xsd:journal" xmlns:ns2="urn:olpw:swz:xsd:archives" xmlns:ns3="urn:olpw:swz:xsd:admin">

<Event>

<Identifier>

<DateTime>2015-08-25T13:00:21.000+00:00</DateTime>

</Identifier>

The token is defined exactly as above (the expression is different, obviously):

token[0].name=EventTime

token[0].type=TimeStamp

token[0].format=yyyy-MM-dd'T'HH:mm:ss.SSSZ

token[0].expression=Event/Identifier/DateTime

As soon as the connector reads the log I get an error message related to the DateTime:

Exception setting event values, please verify that the data type for [EventTime] type [TimeStamp] and value [2015-08-25T13:00:21.000+00:00] matches the data type of [endTime(DateTime)].


Does anyone spot something that could be off?

Thanks a lot in advance!

Labels (2)
0 Likes
Reply
2 Replies
rkent1 Acclaimed Contributor.
Acclaimed Contributor.

Re: TimeStamp is not woking with one xml flex but with the other?

Hmm...


2015-08-25T12:03:46.537+00:00

vs

2015-08-25T13:00:21.000+00:000



Not sure if this is it, but... that second one has a extra 3rd digit at the end. Is that expected?

0 Likes
Reply
matteo.stettner Respected Contributor.
Respected Contributor.

Re: TimeStamp is not woking with one xml flex but with the other?

Sorry, this was a copy and paste typo. No in fact there are only two not three 0s at the end.

0 Likes
Reply
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.