MB-8415 change engine parameter num_shards to num_workers

Change-Id: I5035442233e1208e7a9a7540382a38ba4dec810a
Reviewed-on: http://review.couchbase.org/26776
Tested-by: Jin Lim <jin@couchbase.com>
Reviewed-by: Aliaksey Kandratsenka <alkondratenko@gmail.com>
Revert "MB-8415 change engine parameter num_shards to num_workers"

This reverts commit c84d26d7e27f63f5ad6919d18d8392cd590dd983.

Change-Id: Ic17b36277106f7de77a351e0ce8d8dc45e675e02
Reviewed-on: http://review.couchbase.org/26786
Reviewed-by: Aliaksey Kandratsenka <alkondratenko@gmail.com>
Tested-by: Aliaksey Kandratsenka <alkondratenko@gmail.com>
MB-7363: don't allow stacking of same poor man's alerts

Part of poor man's alerts is alert "key" which is used to prevent
duplicate alerts from reappering too often. We can use that same key
in order for fresher alerts to overwrite older alerts for same key.

This commit also makes metadata overhead and commit failure alerts
have per-bucket keys. So that alerts related to different buckets are
treated as separate alerts.

Change-Id: Ib6146b0a53d2b96c7dd5adf0c9998f3d51855df6
Reviewed-on: http://review.couchbase.org/26802
Reviewed-by: Aliaksey Kandratsenka <alkondratenko@gmail.com>
Tested-by: Aliaksey Kandratsenka <alkondratenko@gmail.com>
MB-8383 Count ret_meta commands as their ordinary counterparts.

And don't count them as xdcr ops.

Change-Id: Ic0eae1f5f9bdb95cfcb1ab78cb0ca22336c5ce0c
Reviewed-on: http://review.couchbase.org/26806
Tested-by: Aliaksey Artamonau <aliaksiej.artamonau@gmail.com>
Reviewed-by: Aliaksey Kandratsenka <alkondratenko@gmail.com>
Merge remote-tracking branch 'origin/2.1.0'

* origin/2.1.0:
  MB-8383 Count ret_meta commands as their ordinary counterparts.
  MB-7363: don't allow stacking of same poor man's alerts
  Revert "MB-8415 change engine parameter num_shards to num_workers"
  MB-8415 change engine parameter num_shards to num_workers

Change-Id: Ifeba39178cac8a9064444d7ac368568abd76f670