 core/modules/rdf/rdf.module                                   | 3 ++-
 core/modules/rest/src/Plugin/rest/resource/EntityResource.php | 7 +++++++
 2 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/core/modules/rdf/rdf.module b/core/modules/rdf/rdf.module
index 33a3e92..ceda758 100644
--- a/core/modules/rdf/rdf.module
+++ b/core/modules/rdf/rdf.module
@@ -233,8 +233,9 @@ function rdf_comment_storage_load($comments) {
     $created_mapping = rdf_get_mapping('comment', $comment->bundle())
       ->getPreparedFieldMapping('created');
     $comment->rdf_data['date'] = rdf_rdfa_attributes($created_mapping, $comment->get('created')->first()->toArray());
+    /** @var \Drupal\Core\Entity\EntityInterface $entity */
     $entity = $comment->getCommentedEntity();
-    $comment->rdf_data['entity_uri'] = $entity->url();
+    $comment->rdf_data['entity_uri'] = $entity->toUrl()->toString(TRUE)->getGeneratedUrl();
     if ($comment->hasParentComment()) {
       $comment->rdf_data['pid_uri'] = $comment->getParentComment()->url();
     }
diff --git a/core/modules/rest/src/Plugin/rest/resource/EntityResource.php b/core/modules/rest/src/Plugin/rest/resource/EntityResource.php
index 4b4d027..6428cbb 100644
--- a/core/modules/rest/src/Plugin/rest/resource/EntityResource.php
+++ b/core/modules/rest/src/Plugin/rest/resource/EntityResource.php
@@ -145,7 +145,14 @@ public function patch(EntityInterface $original_entity, EntityInterface $entity
 
     // Overwrite the received properties.
     $langcode_key = $entity->getEntityType()->getKey('langcode');
+    $bundle_key = $entity->getEntityType()->getKey('bundle');
     foreach ($entity->_restSubmittedFields as $field_name) {
+      // \Drupal\serialization\Normalizer\EntityNormalizer::denormalize() needs
+      // the bundle to be able to denormalize the entity.
+      if ($field_name === $bundle_key) {
+        continue;
+      }
+
       $field = $entity->get($field_name);
       // It is not possible to set the language to NULL as it is automatically
       // re-initialized. As it must not be empty, skip it if it is.
