code: @Override
    public String encrypt(String plainText) {
      this.encryptionLock.lock();
      try{
        byte[] cipherBytes = null;
        try {
          cipherBytes = encryptCipher.doFinal(plainText.getBytes(charset));
        } catch (UnsupportedEncodingException | IllegalBlockSizeException | BadPaddingException e) {
          logger.error("DefaultAESCBCCipher failed to encrypt text", e);
          throw new JsonDBException("DefaultAESCBCCipher failed to encrypt text", e);
        }
        return Base64.getEncoder().encodeToString(cipherBytes);
      } finally{
        this.encryptionLock.unlock();
      }
  
    }
docs: This method is used to encrypt(Symmetric) plainText coming in input using AES algorithm
  @param plainText the plain text string to be encrypted
  @return Base64 encoded AES encrypted cipher text