I am using a 4 core processor. I am implementing a scenario with Parallel.Foreach concept. I have a large record set in database. Using this parallel processing concept I am trying to update some values in those records.
I have divided the record collection into small subset and updating.
Approach 1:- I divided the collection to 4 subset (as I have 4 cores) and did the parallel processing.
But I was thinking if I divide the collection into more number of subsets (say 100), whether my records will update faster?
My understanding is the record will not update faster as I have only 4 cores and also this approach uses the context switching concept. So the resulting time will be more compared to first approach.
Please confirm.
2 core CPU, 1Gb net, 32 cpu superdome (with Oracle 11.2 RDBMS on it) shows the best performance with about 30 threads at night and about 10 during the day