"Provides" to ease dependencies?

Hi,

from normal package management systems, I am used to have "Provides"
which allows me to install any of a set of packages to satisfy a
dependency (eg. "Provides: mail-transport-agent"). I was wondering how
to best achieve a similar effect with Ansible, so I do not have to
hardwire all the role names in many places. Eg. if I want to switch
from one role that installs MySQL to one of the dozens of other roles
which do "basically" the same, I would like to just depend on a role
that provides "database-server", then decide later which database engine
I actually want by selecting one role that installs a database server
without having to go back to all the roles which are installing
applications depending on a database server to reference a different
role.

How are you guys tackling this kind of problem?

Kind regards,
Toni

can you provide a more in dept example of how you currently do it?

You could always create a 'virtual role' and symlink the 'providing
role' into that name.