0

I'm working on a JSF application in which I have used a Firebird database. There are large datasets and application performance is decreased so I have separated database year wise like DB2011.FDB,DB2012.FDB,DB......,DB2019.FDB. We also have a desktop application where the user can select a database to access old years data. But now in a web application, Is it possible to switch database without restarting the server that is defined in the standalon.xml file?

I have check this Edit standalone.xml while running WildFly 8.2 but the requirement is different they said reload needed after changes and changes should be done by CLI or web console.

Database property in standalon.xml file is as follows :-

Database property in the standalon.xml file is as follows:-

<datasource jta="true" jndi-name="java:/jdbc/test" pool-name="test" enabled="true" use-ccm="true">
                <connection-url>jdbc:firebirdsql://localhost:3050//home/test/Documents/Test/Firebird_DB/DB2019.FDB?encoding=WIN1254</connection-url>
                <driver-class>org.firebirdsql.jdbc.FBDriver</driver-class>
                <driver>firebird</driver>
                <security>
                    <user-name>SYSDBA</user-name>
                    <password>****</password>
                </security>
            </datasource>

If it's possible then please let me know, how to achieve this?

INDRAJITH EKANAYAKE
  • 3,894
  • 11
  • 41
  • 63
Nitin Upadhyay
  • 113
  • 1
  • 15
  • As far as I'm aware, you will need to reload your application. If you need to access multiple database, then you should come up with another scheme to allow users to select a database. Because changing these settings will affect **all** users, not just the user that wants to look at a different database. Also, if you need to shard your database per year, that might be a sign that its structure or indexing might need to be scrutinized. – Mark Rotteveel May 08 '19 at 14:20
  • @MarkRotteveel thanks for your suggestion, Yes you are right. I think this application should be SAAS based (Software as a service) need to implement multi-tenancy for group of users years wise. – Nitin Upadhyay May 15 '19 at 09:22

0 Answers0