taler-typescript-core

Wallet core logic and WebUIs for various components
Log | Files | Refs | Submodules | README | LICENSE

commit ddec9cf2faa774fd12a3b9cc0f1414198e52baa8
parent 5a8d880ebd53d6436e78c9f242d20bfa3f50b8b8
Author: Florian Dold <florian.dold@gmail.com>
Date:   Tue, 12 Dec 2017 23:06:13 +0100

only run crypto worker on half of available threads

Diffstat:
Msrc/crypto/cryptoApi.ts | 1+
1 file changed, 1 insertion(+), 0 deletions(-)

diff --git a/src/crypto/cryptoApi.ts b/src/crypto/cryptoApi.ts @@ -203,6 +203,7 @@ export class CryptoApi { // only works in the browser // tslint:disable-next-line:no-string-literal concurrency = (navigator as any)["hardwareConcurrency"]; + concurrency = Math.max(1, Math.ceil(concurrency / 2)); } catch (e) { // ignore }