Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ExceptionInitializerError #24

Open
cyrilfr opened this issue Oct 4, 2021 · 2 comments
Open

ExceptionInitializerError #24

cyrilfr opened this issue Oct 4, 2021 · 2 comments

Comments

@cyrilfr
Copy link

cyrilfr commented Oct 4, 2021

An exception is thrown when I try to fetch files:

Uncaught error from thread [application-akka.actor.default-dispatcher-3]: null, shutting down JVM since 'akka.jvm-exit-on-fatal-error' is enabled for for ActorSystem[application]
java.lang.ExceptionInInitializerError
at org.kopi.ebics.xml.InitializationResponseElement.build(InitializationResponseElement.java:58)
at org.kopi.ebics.xml.DownloadInitializationResponseElement.build(DownloadInitializationResponseElement.java:62)
at org.kopi.ebics.client.FileTransfer.fetchFile(FileTransfer.java:211)
at org.kopi.ebics.client.EbicsClient.fetchFile(EbicsClient.java:419)
at org.kopi.ebics.client.EbicsClient.fetchFile(EbicsClient.java:431)
at services.payment.EbicsClient.fetchCamt054(EbicsClient.java:100)
at modules.UserChecker.fetchCamt054(UserCheckerModule.java:177)
at modules.UserChecker.checkRefills(UserCheckerModule.java:124)
at akka.actor.LightArrayRevolverScheduler$$anon$2$$anon$1.run(LightArrayRevolverScheduler.scala:102)
at akka.dispatch.TaskInvocation.run(AbstractDispatcher.scala:39)
at akka.dispatch.ForkJoinExecutorConfigurator$AkkaForkJoinTask.exec(AbstractDispatcher.scala:415)
at scala.concurrent.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260)
at scala.concurrent.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1339)
at scala.concurrent.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979)
at scala.concurrent.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:107)
Caused by: java.lang.RuntimeException: java.util.MissingResourceException: Can't find resource for bundle java.util.PropertyResourceBundle, key 091115
at org.kopi.ebics.messages.Messages.getString(Messages.java:71)
at org.kopi.ebics.exception.ReturnCode.create(ReturnCode.java:193)
at org.kopi.ebics.exception.ReturnCode.(ReturnCode.java:186)
... 15 more
Caused by: java.util.MissingResourceException: Can't find resource for bundle java.util.PropertyResourceBundle, key 091115
at java.util.ResourceBundle.getObject(ResourceBundle.java:450)
at java.util.ResourceBundle.getString(ResourceBundle.java:407)
at org.kopi.ebics.messages.Messages.getString(Messages.java:69)
... 17 more
2021-10-04 18:15:02,650 [ERROR] from a.a.ActorSystemImpl - Uncaught error from thread [application-akka.actor.default-dispatcher-3]: null, shutting down JVM since 'akka.jvm-exit-on-fatal-error' is enabled for ActorSystem[application]
java.lang.ExceptionInInitializerError: null

String fileName = "ebics-"
        + configuration.getString("provider.coordinates.name")
        + "-"
        + LocalDateTime.now()
        + ".camt.054.zip";
File c54Zip = new File(C54_DIR, fileName);

EbicsClient client = EbicsClient
        .createEbicsClient("ebics", "file.camt);
client.loadDefaultUser();
client.fetchFile(c54Zip, OrderType.C54, null, null);

I'm using the JitPack maven with the last build.
It used to work with commit 41fbb38

@cyrilfr
Copy link
Author

cyrilfr commented Oct 27, 2021

It seems that the server returns an error code 091115. It's not clear in the Exception output. It means that the orderId created has already been used before.
In fact, if the orderId is not sent (which is the case for DownloadInitializationRequestElement.java if request type is not FDL line 132):

  //FIXME Some banks cannot handle OrderID element in download process. Add parameter in configuration!!!
  orderDetails = EbicsXmlFactory.createStaticHeaderOrderDetailsType(null,//session.getUser().getPartner().nextOrderId(),
                                                                OrderAttributeType.DZHNN,
                                                                orderType,
                                                                standardOrderParamsType);

Thus, the client is not synchronized, leading in this situation...
I perform the request to Credit Suisse.

@cyrilfr
Copy link
Author

cyrilfr commented Sep 23, 2022

Any fix for this issue? This makes the EBICS Java Client unusable basically...

Here is the exception in command line mode for a HPB request:

java.lang.ExceptionInInitializerError
    at org.kopi.ebics.xml.KeyManagementResponseElement.build (KeyManagementResponseElement.java:75)
    at org.kopi.ebics.client.KeyManagement.sendHPB (KeyManagement.java:145)
    at org.kopi.ebics.client.EbicsClient.sendHPBRequest (EbicsClient.java:353)
    at org.kopi.ebics.client.EbicsClient.main (EbicsClient.java:650)
    at org.codehaus.mojo.exec.ExecJavaMojo$1.run (ExecJavaMojo.java:254)
    at java.lang.Thread.run (Thread.java:829)
Caused by: java.lang.RuntimeException: java.util.MissingResourceException: Can't find resource for bundle java.util.PropertyResourceBundle, key 091115
    at org.kopi.ebics.messages.Messages.getString (Messages.java:71)
    at org.kopi.ebics.exception.ReturnCode.create (ReturnCode.java:193)
    at org.kopi.ebics.exception.ReturnCode.<clinit> (ReturnCode.java:186)
    at org.kopi.ebics.xml.KeyManagementResponseElement.build (KeyManagementResponseElement.java:75)
    at org.kopi.ebics.client.KeyManagement.sendHPB (KeyManagement.java:145)
    at org.kopi.ebics.client.EbicsClient.sendHPBRequest (EbicsClient.java:353)
    at org.kopi.ebics.client.EbicsClient.main (EbicsClient.java:650)
    at org.codehaus.mojo.exec.ExecJavaMojo$1.run (ExecJavaMojo.java:254)
    at java.lang.Thread.run (Thread.java:829)
Caused by: java.util.MissingResourceException: Can't find resource for bundle java.util.PropertyResourceBundle, key 091115
    at java.util.ResourceBundle.getObject (ResourceBundle.java:564)
    at java.util.ResourceBundle.getString (ResourceBundle.java:521)
    at org.kopi.ebics.messages.Messages.getString (Messages.java:69)
    at org.kopi.ebics.exception.ReturnCode.create (ReturnCode.java:193)
    at org.kopi.ebics.exception.ReturnCode.<clinit> (ReturnCode.java:186)
    at org.kopi.ebics.xml.KeyManagementResponseElement.build (KeyManagementResponseElement.java:75)
    at org.kopi.ebics.client.KeyManagement.sendHPB (KeyManagement.java:145)
    at org.kopi.ebics.client.EbicsClient.sendHPBRequest (EbicsClient.java:353)
    at org.kopi.ebics.client.EbicsClient.main (EbicsClient.java:650)
    at org.codehaus.mojo.exec.ExecJavaMojo$1.run (ExecJavaMojo.java:254)
    at java.lang.Thread.run (Thread.java:829)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant