RPC protocol based on memcached implementation.

Register redis service address

RegistryFactory registryFactory = ExtensionLoader.getExtensionLoader(RegistryFactory.class).getAdaptiveExtension();
Registry registry = registryFactory.getRegistry(URL.valueOf("zookeeper://"));

Use in client

get service reference:

<dubbo:reference id="store" interface="java.util.Map" group="member" />

or direct access by IP:

<dubbo:reference id="store" interface="java.util.Map" url="redis://" />

you can also use a custom interface:

<dubbo:reference id="store" interface="" url="redis://" />

The method name is the same as the standard method name of memcached, just like get(key), set(key, value), delete(key)。

If the method name and the memcached standard method name are not the same, you need to configure the mapping

<dubbo:reference id="cache" interface="" url="memcached://" p:set="putFoo" p:get="getFoo" p:delete="removeFoo" />

results matching ""

    No results matching ""