[ 
https://issues.apache.org/jira/browse/MNEMONIC-360?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16154621#comment-16154621
 ] 

Niall Gallagher commented on MNEMONIC-360:
------------------------------------------

As the owner of CQEngine I would be happy to allow Mnemonic to adopt or 
integrate it. I did take a look at the documentation for Mnemonic, to figure 
out where I could get started with an integration.

However to be honest I think the documentation for Mnemonic needs to be cleaned 
up significantly. On the main page the example usage looks incredibly complex.

**Example 1**
{quote} 
        /**
         \* setup generic info manually to avoid performance penalty
         \*/
        @Override
        public void setupGenericInfo(EntityFactoryProxy[] efproxies, 
GenericField.GType[] gftypes) \{

        \}
{quote}
... what is this generic info? What are efproxies? What is this performance 
penalty? 
Do I actually need to implement this method, and if so, how?

If this is supposed to show how Mnemonic can be used, why isn't this method in 
the example implemented?

I think Mnemonic needs to hide this complexity from end users by default.

**Example 2**

{quote}        // keep this person on non-volatile handler store
        act.setHandler(keyidx, person.getHandler());

        for (int deep = 0; deep < rand.nextInt(100); ++deep) \{
        
                // create another person as mother
                mother = PersonFactory.create(act);
                mother.setAge((short)(50 + rand.nextInt(50)));
                mother.setName(String.format("Name: \[%s\]", 
UUID.randomUUID().toString()), true);
                
                // set the person's mother
                person.setMother(mother, true);

                person = mother;
        \}{quote}

If I understand it correctly, this example demonstrates non-deterministic 
behavior. 

Why is there a random number generator in the example? What has it got to do 
with Mnemonic?
If it does not directly relate to Mnemonic, then it should not be in the 
example.

What is the 'act' variable? What is keyidx? What is a handler?
Variables should have descriptive names.

**TL;DR**
I think as a fairly experienced developer that if I can't understand how to use 
a project from the front page, then a lot of less experienced developers will 
be put off by it completely.

The front page needs to provide a radically simpler example.
To begin with, I'd suggest to show in no more than a few lines of code, how to 
persist a single object.

I have spent so much time figuring out how to do the simple stuff with Mnemonic 
due to lack of documentation, that I have not made much progress with the 
integration yet. 

I am still interested in integrating as I think Mnemonic is a promising 
technology, though :)
Please clean up the documentation!

> Collection based query feature
> ------------------------------
>
>                 Key: MNEMONIC-360
>                 URL: https://issues.apache.org/jira/browse/MNEMONIC-360
>             Project: Mnemonic
>          Issue Type: Wish
>          Components: Collection, Core, Query
>    Affects Versions: 0.9.0-incubating
>            Reporter: Wang, Gang
>
> This would be a new major feature for Mnemonic.
> Mnemonic would be able to act as a service to process query request.
> This feature is expected to build on top of Durable Collection (DC), Durable 
> Object Model (DOM) and Durable Computing Model (DCM).
> It is inspired by CQEngine [https://github.com/npgall/cqengine]. 
> The significant performance improvement contributed by CQEngine has been 
> proved so we can expect the equivalent effect on Mnemonic.
> We will ask for the agreement to allow Mnemonic to adopt the features of 
> CQEngine.
>  



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to