James Netherton created CAMEL-20579:
---------------------------------------

             Summary: camel-xchange: ticker action may throw 
NotYetImplementedForExchangeException
                 Key: CAMEL-20579
                 URL: https://issues.apache.org/jira/browse/CAMEL-20579
             Project: Camel
          Issue Type: Bug
          Components: camel-xchange
            Reporter: James Netherton
            Assignee: James Netherton
             Fix For: 4.5.0


The xchange ticker action invokes this code:

https://github.com/apache/camel/blob/e924867d1a153e3d1bf6af7b01cf1f950cf91ff3/components/camel-xchange/src/main/java/org/apache/camel/component/xchange/XChangeEndpoint.java#L181

Note the cast of 'pair' to 'Instrument'. Conveniently this works for the 
default binance exchange that the component ships with. But for most other 
exchanges, the xchange crypto API implementations still use the deprecated 
MarketDataService.getTicker(CurrencyPair).

So if you try to use the ticker action for the kraken exchange, you get 
NotYetImplementedForExchangeException.

We could do fallback to the older getTicker variant if the initial attempt 
fails.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to