My Photo

Become a Fan

DailyMile

Google Ad Skyscraper

« Database invalidation and caches | Main | Day 2, large Java heaps »

February 28, 2007

Comments

Patrick Mueller

Wow. 26Gb of data. Wow.

So, one thing you don't talk about is how the data moves, from presumably object form (since you are trying to avoid byte formats), between the 'server' and the 'client'. If the server really is storing 'objects', then you're doing some kind of byte-oriented serialization, no? Over a pipe. So I'd have to ask, why is the server storing objects in the first place instead of byte arrays ready for serialization to the client? And if you're on a single box, shmem may be a better way to handle this than pipes anyway (avoid copying data at the expense of managing your shmem).

Yes, I'm an ObjectGrid n00b, more or less.

Billy

It stores objects because a lot of ObjectGrid type applications run business logic against the data directly, as in this case. If it was like a client/server setup then byte[]s would work well but we have the equivalent of stored procedures also which would then pay a big cost and for some applications, e.g. a 1000 server grid hosting 500GB of data, all data would only be accessed locally using the data grid apis.

Andy

Something is wrong. I've had heaps of nearly that size on Solaris with fewer CPUs and achieved far better performance. It could just be the VM or AIX or the memory architecture or something. I've never been able to get as good of performance out of the AIX JVM as the Sun or BEA VMs. I've never tried this big of a heap on AIX...

If the stuff is staying in memory what about a concurrent collector?

Billy

26GB is staying in memory. We're keeping what amounts to an inmemory database occupying about 26GB of memory (7 million objects). It's always there. I think you'd see the same issue on Solaris, it just takes time to scan the heap.

Robert Greig

Just to clarify, I take it you mean that when you say "it takes 8 seconds for a normal GC", you mean that the mark and remark phases stop the world for 8 seconds? I presume you are using a CMS collector?

Does IBM have a parallel remark phase in their Java 5 JVM?

--Robert

Billy

I'm using a generational garbage collector. IBM has concurrent mark. The mark phase happens in parallel with existing work as a GC nears, once the GC hits then it's parallelized as best it can. I've tested GC time versus # CPUs and the IBM Java 5 is basically linear with the number of CPUs.

Robert Greig

Sorry I was not being entirely precise, I meant "initial mark" and "re-mark" phases. The Sun JVM also has concurrent and parallel mark.

I presume the IBM JVM also stops the world in the initial mark and re-mark phases?

What I was getting at was that with boxes with multiple cores/CPUs you will reduce the "stop the world" time if you can have a parallel remark phase - Sun 1.6 introduces a parallel remark phase whereas with 1.5 it was serial. Does IBM 1.5 have parallel re-mark?

I think it is important to differentiate between the stop the world pause time and the overall GC time which includes concurrent time. On a small heap the initial mark and remark phases may not be worth worrying about but with larger heaps they may well be.

--Robert

The comments to this entry are closed.