I have a requirement to modify an existing application which has been written using JPA (with Hibernate, and JBoss Cache is enabled) to support multiple database schemas (Oracle). The idea is to support multiple clients using different schemas, but to have only a single running instance of the application. The application should select the schema dynamically.
This is to support multi-tenancy, but re-designing the application by adding new columns to identify records for each client is not an option at the moment.
My question is, is this possible ? If so, how can I achieve this ?
I took a look at Hibernate Shards, but that does not seem to solve my problem, as what I am after is not horizontal partitioning.