Drupal 8 : Get content owner or author name of a node using node id.

To load the author name or owner from a node entity object we can use getOwner(). The below example show how to load a node object using node id and to get the Author name from it.