Cardinality aggregation: discrete shards

Hi,

I want to do cardinality aggregation on userNr, which has very high cardinality (> 1.000.000). Since my index has multiple shards and I'm routing based on userNr, the cardinality of the shards can simple be summed to the total cardinality. Is there a way to do this or should I write a custom aggregation?

Cheers,
Joris