You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I just had a look at the cache behaviour for ex_money and it seems it's mixing etag caching with rates caching. For the two built in ets/dets caches this makes no difference as they're simply key/value storages. I'm about to implement one based on ecto and store stuff in the database and there it becomes quite obvious, that those two responsibilities are convoluted. Would be nice if get/1 and put/2 could be replaced more meaningful callback functions.
The text was updated successfully, but these errors were encountered:
Fair call, etagcaching should be separated from rates caching. In which case get/1 and put/2 would be removed from the Money.ExchangeRates.Cache behaviour since they are then just implementation details below the public API.
First thought it to simply use another ets table to cache etags. Would that work for you?
I just had a look at the cache behaviour for ex_money and it seems it's mixing etag caching with rates caching. For the two built in ets/dets caches this makes no difference as they're simply key/value storages. I'm about to implement one based on ecto and store stuff in the database and there it becomes quite obvious, that those two responsibilities are convoluted. Would be nice if
get/1
andput/2
could be replaced more meaningful callback functions.The text was updated successfully, but these errors were encountered: