code: final public function generateEtag(array $ignoredFields = [])
      {
          if (null === self::$serializer) {
              self::$serializer = new PhpArraySerializer();
          }
          $array = self::$serializer->serialize($this, ['includeAllFields' => true]);
  
          if (empty($ignoredFields)) {
              return md5(json_encode($array));
          }
  
          foreach ($ignoredFields as $field) {
              unset($array[$field]);
          }
  
          return md5(json_encode($array));
      }
docs: {@inheritdoc}
  todo: review performance