ebics-java-client icon indicating copy to clipboard operation
ebics-java-client copied to clipboard

Control OrderIDs

Open acekorg opened this issue 3 years ago • 3 comments
trafficstars

Hi Uwe

I'm trying to use your code as a dependancy and fully automate execution of EBICS orders in a batch process... I wonder if there is possibility to control OrderIDs generated in Partner.java. Bank requires unique ID for each order but each time I instantiate new EbicsClient() the value orderId starts over from "A001" which leads to orders being rejected by the bank as duplicates. Possible solution is to create bean EbicsClient and let it live as much as possible so it generates new OrderIDs successfully... but eventually the java container might be restarted and the value to start again over "A001" so this doesn't look like the safest solution.

Am I maybe missing something or this functionality isn't there yet ?

acekorg avatar Mar 04 '22 20:03 acekorg

There is a quit() method on the EbicsClient. When you call this method it will persist the state and this includes the orderId. So the best is to create the EbicsClient, then do the orders and then call quit(), to persist the state.

uwemaurer avatar Mar 05 '22 13:03 uwemaurer

There is a problem with more userId within the same partnerId. The first userId can be initialized, HIA, HPB, the other userId get error EBICS_ORDER_ID_ALREADY_EXISTS. How can the start value of orderId individually set for each userId?

jkirste avatar Jun 20 '22 11:06 jkirste

I have the same issue.

cyrilfr avatar Sep 26 '22 07:09 cyrilfr