July 22, 2018 at 6:50 pm #3815AnonymousInactive
There definitely seems to be some error here – On one of the pairs I have listed, some offers and bids are still showing up even though all open orders have been cancelled.
This is not happening on all the pairs, only on some of them.July 23, 2018 at 7:12 am #3825
Do the orders still show up after you refresh the page?
Normally after you place an order the orderbook view is refreshed with a new JSON API call to the orderbook API endpoint.
If this call fails due to network issues the view might not be updated.
But the bids and asks views only display orderbook data and the query for orderbook data only retrieves open orders.
Can you check if the orders remain after a page refresh please?
kind regardsJuly 23, 2018 at 7:25 am #3827AnonymousInactive
Yes, I have refreshed several times. New orders are not showing up on this pair.
Trades on other pairs are still showing up and are still clearing. I have also tried deleting the pair and creating it again.
Old trades just stay there even after cancelling all open orders, refreshing the page does not do anything.July 23, 2018 at 7:28 am #3828
To be clear, it is normal for already performed trades to remain in the history views, even after cancelling the open trades.
I believe you mean that open orders remain in the orderbook views? Is that what you are saying?July 23, 2018 at 7:29 am #3829
Also, is the market pair set to “enabled”?July 23, 2018 at 8:22 am #3838AnonymousInactive
1. Yes the order book does not clear or show up any new orders
2. Yes the pair is enabledJuly 23, 2018 at 9:08 am #3842
This sounds like it could be due to the calls being cached.
If so, I will fix this in the next patch.
Does the problem resolve if you clear your browser’s cache?July 23, 2018 at 9:25 am #3845AnonymousInactive
Yes, I have tried clearing the browser cache, it is still not clearing.
Also tried on another PC.July 23, 2018 at 2:09 pm #3859AnonymousInactive
Is your plugin creating cached data somehow? And if so is there a way to manually clear it?July 23, 2018 at 2:12 pm #3860
Yes, I already thought about this.
The JSON API does indeed cache the data on WordPress transients, but only for a few seconds.
Normally transients are stored on the options table in the database, but if you have a solution such as memcached installed, the transients can be stored there.
Does clearing your server cache resolve your problem?July 23, 2018 at 3:54 pm #3862AnonymousInactive
Let me just understand in a bit more detail. I checked the wp options table and I found a lot of transients in there related to exchange transactions. Are they all supposed to clear after a couple of seconds? They don’t seem to clear at all in my wp options table.July 24, 2018 at 9:36 am #3866
For some public API endpoints there is a few-seconds cache based on transients. For example, if you check
json-api.phpyou will see that some responses are cached for the amount of seconds specified by the
When there is no object cache installed, WordPress falls back to storing the transients on the options table. If there is an object cache installed the transients are stored on that. This is not the first time I see someone with an object cache experience problems with transients not expiring. After a quick search on the web it seems this is caused by misconfiguration of the object cache, although I’m not sure.
To check, can you clear your W3 Total Cache, or memcached, or whatever it is you’re using? Does this refresh the output of the APIs?
You should also be aware that DB rows of transients do not necessarily get deleted just because they are expired. WordPress does some garbage collection but it is not perfect, so third-party solutions exist to clear expired transients from the DB to save space. In any case, the WordPress transients API should not return expired transients even if they exist on the DB, assuming this is where they are stored on your system.
I can always add a switch to disable cache, but we should at least have some idea of what is going on here. The question is why your transients are not expiring. For example, the transient that stores output of the
wallets_exchange_summariesand by default should be cached for 5 seconds.
Please do let me know if you find anything about this.
kind regardsJuly 26, 2018 at 3:59 pm #3913AnonymousInactive
I was running W3Cache and adjusted database and object cache settings. Problem seems to be resolved.July 27, 2018 at 8:04 am #3918
Glad your problem was resolved.
I will add this to the troubleshooting instructions.
- You must be logged in to reply to this topic.