Thank you for getting back to me.
Azure Database for MySQL flexible server with Public access (allowed IP addresses), make sure that the firewall is configured to allow connections from your client. Refer to Create and manage Azure Database for MySQL flexible server firewall rules using the Azure portal.
Client firewall configuration: The firewall on your client must allow connections to your Azure Database for MySQL flexible server instance. IP addresses and ports of the server that you connect to must be allowed as well as application names such as MySQL in some firewalls.
Please let us know the result.
Are you connecting using managed identity.?
Regards,
Oury