code: function encrypt(kms, params, logger) {
    logger = logger || console;
    const startMs = Date.now();
    return kms.encrypt(params).promise().then(
      result => {
        if (logger.traceEnabled) logger.trace(`KMS encrypt success took ${Date.now() - startMs} ms`);
        return result;
      },
      err => {
        logger.error(`KMS encrypt failure took ${Date.now() - startMs} ms`, err);
        throw err;
      }
    );
  }
docs: Encrypts the plaintext within the given KMS parameters using the given AWS.KMS instance & returns the KMS result.
  @param {AWS.KMS} kms - an AWS.KMS instance to use
  @param {KMSEncryptParams} params - the KMS encrypt parameters to use
  @param {Logger|console|undefined} [logger] - an optional logger to use (defaults to console if omitted)
  @returns {Promise.<KMSEncryptResult>} a promise of the KMS encrypt result