- Newest
- Most votes
- Most comments
I had this problem a long time ago , these are some tips you can consider
Use a time zone that is relevant to your users: If the majority of your users are located in a specific geographical region, it's a good idea to use a time zone that is relevant to them. For example, if most of your users are located in the US, you could use the UTC-5 or UTC-8 time zones, which correspond to the Eastern and Pacific time zones, respectively.
Consider the time zone of your application servers: If your application servers are located in a different time zone than your users, you should consider the impact this may have on the timestamps stored in the database. For example, if your application servers are located in the UTC time zone and your users are located in the US, you may want to use the UTC-5 or UTC-8 time zones to ensure that the timestamps stored in the database match the local time of your users.
Avoid using the local time zone of the database server: It's generally not a good idea to use the local time zone of the database server as the default time zone for your database. This is because the time zone of the server may change if the server is moved to a different location. Instead, it's better to use a time zone that is relevant to your users.
Use the UTC time zone as a fallback: If you are unable to determine a time zone that is relevant to your users, you can use the UTC time zone as a fallback. This time zone is not affected by daylight saving time and is widely accepted as a standard time reference.
In summary, the best practice for selecting a time zone for a MySQL database instance for a SaaS-based cloud application is to use a time zone that is relevant to your users, considering the time zone of your application servers and avoiding using the local time zone of the database server. If necessary, you can use the UTC time zone as a fallback.
Relevant content
- asked 2 months ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated 3 months ago
- AWS OFFICIALUpdated 2 years ago
Hello !!!
Thanks for your response.
As our application is a SaaS application, How can we maintain time of different locations from a single database hosted in RDS. for an example let's say in the same application two clients, one from US and other from Australia has logged in and for both of them I have to show them their local time only, how can we do this???
We have come up with a planning like we will keep both RDS and Nodejs as UTC and angular code will change the time as per the local time setting, that also will come from a config setting. is this approach will work for the above mentioned problem???
Please suggest !!!