Sounds good...for your (b) I see that a traverser would easily do it,
or I may do it client-side to show stubs for hidden comments. I'll
also want (a), a global list of high-rated comments, which is why I'm
thinking I'd maintain a list of the top 1000 or so. Comment ratings
will degrade over time so nodes should drop out of this list.

I'll want to do something like give a user a sum of the points he's
accrued across his comments...assuming worst case of a couple thousand
comments, would I likely be better off updating his sum whenever a
comment of his is rated, or simply traversing his comments and summing
them up when I need to?

In the event that I'm very lucky and need more than 200
transactions/s, would it work better to do updates in batches every
few seconds? (Of course I guess then I'd need to temporarily save the
update instructions somewhere outside the system.)

Getting ahead of myself a bit: anything noteworthy about ram requirements?


On 6/16/09, Johan Svensson <[email protected]> wrote:
> Hi Dennis,
>
> As Neil mentioned a well configured batch inserter typically gives you
> 5x or higher write speed compared to normal writes running in a
> transaction. Batch inserter is there to speed up initial import of
> data but judging from the use-cases you presented you will be running
> in normal transactional mode.
>
> In a large transaction (thousands of node, relationship and/or
> property creates/updates/deletes) you do about 10-100 writes per ms.
> Running small write transactions with just a few updates in each
> transaction the bottleneck will be the flush operations and then you
> typically get around 200 transactions/s (numbers are very hardware
> dependent).
>
> Regarding contention, by default a write will not block a read but
> writes have to wait for each other. Modifying a node's or
> relationship's properties will acquire a write lock on that node or
> relationship holding it until the transaction commits or gets rolled
> back. Deleting or creating a relationship will acquire a write lock on
> the relationship, the start node and the end node.
>
> I think you are on the right track considering using Neo4j for this
> problem :) If you could give us some more information about how
> exactly the rating system is going to work we could advice you on how
> to design your graph. For example:
>
> Does getting the highest rated comments mean:
>
> a) of all the latest comments since time X, give me the ones that had
> the highest rating
>
> or
>
> b) for this topic / thread, only show comments with rating higher then X
>
> Regards,
> Johan
>
_______________________________________________
Neo mailing list
[email protected]
https://lists.neo4j.org/mailman/listinfo/user

Reply via email to