This is not the role of a resource adapter. If you use firebird there is an mbean you can use to create databases dynamically. You could probably write something similar for other dbs if they provide a java interface for database creation.
You don't provide enough info about how other entities decide which database to access. Are you sure it wouldn't be more appropriate to have one database where most tables have a projectid column?