Not sure I'd use a cache loader for a memcached implementation in JBossCache. I would
do it as follows:
- Goal (like in JGroups' impl) is to have Java clients sit in the address space of the
server, so no memcached protocol is required
- The memcached protocol is implemented (for remote clients, or clients written in
different languages) in a JBC-memcached server. Here, we can copy JGroups'
implementation, or any server side impl (there aren't many though)
- The server implementation consists of a configuration which replaces the
ReplicationInterceptor with a different interceptor (maybe a subclass ?). That interceptor
forwards calls to certain FQN to different servers, using consisten hashing over the FQN
to always map the same FQN to the same JBC-memcached instance
- L1 cache: the results could be stored in the JBC instance, so it would act as an L1
cache
Hmm, maybe your CacheLoader thought is not such a bad idea ! The CacheLoader acts as L2
cache and uses consistent hashing to fetch items from given hosts, and JBC itself (in
conjunction with evciction) acts as L1 cache...
Whichever implementation we pick, it should fit into the architecture of Data
Partitioning
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4176995#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...