Skip to content

java.lang.ClassCastException occurred. #88

@freest4r

Description

@freest4r

RISE_SECC_log.txt
ChargeParameterDiscoveryReq.txt

Recently I'm working on testing ISO 15118-2.
Thanks to RISE, I can do my research well. thank you.

To test rise-v2g-secc-1.2.6.jar, I implement EVCC that transmits unexpected XMLs.
In this process, I found several errors and today I would like to report the one of the errors.

In "ChargeParameterDiscoveryReq" step,
if "DepartureTime" of "AC_EVChargeParameter" is empty (ns3:DepartureTime</ns3:DepartureTime>),
RuntimeException is occurred in rise-v2g-secc-1.2.6.jar.
but it's OK because rise-v2g-secc-1.2.6.jar send "FAILED_SequenceError" to EVCC.

At this time,
If EVCC connect to rise-v2g-secc-1.2.6.jar and send normal SupportedAppProtocolReq,
then "java.lang.ClassCastException" is occurred.

The exception message is like below:

java.lang.ClassCastException: class com.v2gclarity.risev2g.shared.v2gMessages.appProtocol.AppProtocolType cannot be cast to class javax.xml.bind.JAXBElement (com.v2gclarity.risev2g.shared.v2gMessages.appProtocol.AppProtocolType and javax.xml.bind.JAXBElement are in unnamed module of loader 'app')

Then, rise-v2g-secc-1.2.6.jar send "Failed_NoNegotiation" to the EVCC.
Even though the SupportedAppProtocolReq message was normal.

I'm not sure why it happens,
but I attached logs and ChargeParameterDiscoveryReq.xml files.

In summary, the reproduce process is as follows:

  1. run rise-v2g-secc-1.2.6.jar
  2. EVCC connect to the rise-v2g-secc-1.2.6.jar and continues the process normally until the ChargeParameterDiscoveryReq step.
  3. At ChargeParameterDiscoveryReq step, send attached ChargeParameterDiscoveryReq.xml file to rise-v2g-secc-1.2.6.jar.
  4. java.lang.RuntimeException occurred -> FAILED_SequenceError -> Connection closed
  5. EVCC connect to the rise-v2g-secc-1.2.6.jar again and send normal SupportedAppProtocolReq message.
  6. java.lang.ClassCastException occurred -> Failed_NoNegotiation -> connection closed

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions