Failed to set the local availability replica of availability group '%1!s!' as joined in Windows Server Failover Clustering ...

Failed to set the local availability replica of availability group '%1!s!' as joined in Windows Server Failover Clustering (WSFC) database.  Either the local availability replica is no longer the primary, or the WSFC service is not accessible.  Verify that the local WSFC node is online, and that the local availability replica is the primary replica.  Then retry the operation.