Hi Niclas,
Here is some sort of "getting started" documentation for using de
HazelcastEntityStore.
I wrote something quick, like what's done for others EntityStores on the qi4j
website. I hope it's enough.
============================
The Hazelcast EntityStore is a non-persistent EntityStore leveraging the
Hazelcast in-memory data grid. It can be
used when you need a large in-memory Store with high throughput.
The only thing needed to use the Hazelcast EntityStore, is to do the proper
assembly in a module. We recommend
the usage of the HazelcastEntityStoreAssembler which will add the service to
the module.
Example
public static void main( String args )
{
qi4j = new SingletonAssembler()
{
public void assemble( ModuleAssembly module )
throws AssemblyException
{
module.addAssembler( new HazzelcastEntityStoreAssembler() );
// module.addEntities( ....
}
}.runtime();
}
Once a qi4j Application using the Hazelcast EntityStore is started, the default
Hazelcast instances discovery
mechanism (multicast) is used. You can for example start Hazelcast nodes in
other JVMs :
public static void main( String args )
{
HazelcastInstance h1 = Hazelcast.newHazelcastInstance(null);
}
This allows you to store more than what a single JVM process can allocate in a
single EntityStore.
Plus, you can start multiple instances per JVM.
======================================
For now, it's only an in-memory store but I'm planning to write what's needed
to back it up with another
MapEntityStore so that entities can be persisted. I'm not sure how nor when but
this will come to my todo list one day
or another.
Paul
Le Jeudi 21 Janvier 2010 03:39:50, Niclas Hedhman a écrit :
> On Wed, Jan 20, 2010 at 9:24 PM, Paul MERLIN <[email protected]> wrote:
> > I would like to write documentation for the Hazelcast Store but can't
> > find some sort of howto on the qi4j site to learn how to do it the qi4j
> > way.
> >
> > In other words, would you like to explain the documentation contribution
> > flow ?
>
> We don't have it figured out. The way I see it (since I write most of
> the little docs we have), I think a 2-way approach is suitable;
>
> 1. Direct edit in the SiteVision instance (preferred for continuous
> contributors),
>
> 2. Indirectly, via human-readable form.
>
>
> For the first approach, there is a bit of initial setup on our part
> (need to provide authorization) and learning on the contributor's
> part. SiteVision is not your run-of-the-mill wiki, but a fairly
> sophisticated Content Management System (brain-child of Rickard, with
> COP principles under the hood), where a JRE will execute the Editor,
> and the page is assembled with Portlets, for instance a block of Text
> is a portlet, an Image is a portlet, but there are dozens of other
> types, although we don't use most. The editing is practically WYSIWYG
> (some portlets render differently), and you as the editor don't need
> to worry about "the look".
> Sitevision also supports workflows, meaning it is possible to write a
> page and ask other editors to view and approve prior to publish. This
> is also a feature not yet in use.
>
> My guess is that there are online material on SiteVision's website,
> but I don't have a link laying around.
>
>
> For the second option, where contributions are more sporadic, I don't
> think it is reasonable to require people to learn Sitevision, and the
> easiest thing would be to send in the material in some other form that
> makes sense, ODT files could be one such choice, plain text files or
> even just an email without formal markup and english explanations
> would do.
>
>
> Cheers
_______________________________________________
qi4j-dev mailing list
[email protected]
http://lists.ops4j.org/mailman/listinfo/qi4j-dev