Luke, Interesting. I am so used to thinking of Geode as an Enterprise framework. Are you thinking of this concept in terms of a external small cache and not embedded like a peer-to-peer without the peer?? - And is I think a locator is not useful for a single node as pointed out earlier.
Thinking some more, why not abandon a Geode Java client and use REST instead? On Sat, Aug 15, 2015 at 12:25 PM, Luke Shannon <[email protected]> wrote: > Hi All, > > Curious about what everyone thinks about usage of Geode as a single > process rather than a full cluster. Before you respond to that alone, lets > me review why I would want to do this :-) > > I like the Geode programming model for CRUD operations, function > executions and listeners. Its CacheWriter and Reader are also really > useful. I find the Client/Server approach really powerful, interests, > client side listeners and expiration provide some really powerful features > for powerful client applications. > > So lets say I want all of this but don't need a distributed system (for a > smaller website lets say). I also don't want to mess with GFSH and making > any changes at the OS level. I just want something I can start. > > I obvious thought was to use Redis, but I wanted to see if I could do > something with Geode as I am already pretty familiar with it. > > As an experiment I built Spring Boot application with an embedded Locator > and Server (sample config below) that contains the Server config and any > dependancies my functions and listeners needed. Whats nice here is I have a > jar file I can copy somewhere, start up and be instantly ready for a client > to connect too. I have 4 clients and they get fast responses to Key/Value > operations, execute functions, receive interests, etc. I monitor it with > Monit. > > Although I have not tried, I am pretty sure I can even run it on > run.pivotal.io. > > Thoughts on this approach? Should I really just be using Redis for a > single cache? > > Snippet from cache-config.xml > > <util:properties id="singleCacheConfigurationSettings"> > > <prop key="name">singleCache</prop> > > <prop key="locators">127.0.0.1[11235]</prop> > > <prop key="log-level">config</prop> > > <prop key="mcast-port">0</prop> > > <prop key="start-locator">127.0.0.1[11235]</prop> > > </util:properties> > > <gfe:cache id="gemfireCache" pdx-serializer-ref= > "reflection-pdx-serializer" > > properties-ref="singleCacheConfigurationSettings" /> > > <gfe:cache-server port="0" cache-ref="gemfireCache" /> > -- Regards, Jim Bedenbaugh Advisory Data Engineer Pivotal Software
