Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Timezone retrieval issue #11510

Closed
leonkosak opened this issue Jan 31, 2022 · 2 comments
Closed

Timezone retrieval issue #11510

leonkosak opened this issue Jan 31, 2022 · 2 comments
Labels

Comments

@leonkosak
Copy link
Contributor

leonkosak commented Jan 31, 2022

We are experiencing problems with retrieval of Tenant Settings, specifically Abp.Timing.Timezone, from the database. Our application is running on v4.3. with Multitenancy and separate postgres databases for each Tenant.
In the modules, where the timezone settings are needed, we have defined the ModuleSettingDefinitionProvider as the documentation instructs.

public class ModuleSettingDefinitionProvider : SettingDefinitionProvider
    {
        public override void Define(ISettingDefinitionContext context)
        {

            context.Add(
                    new SettingDefinition("Abp.Timing.Timezone", "UTC")
                );
        }
    }

In the AppServices we are using the _settingProvider.GetOrNullAsync("Abp.Timing.Timezone");

On our development enviroment we run into no problems and the correct database defined setting is retrieved and used without problems, whereas on our production we run into the issue, that the correct setting is not retrieved and the default »UTC« Timezone from the SettingDefinitionProvider is used in further operations. We have tried defining the settings:

  • In the host database (public/AbpSettings) where the Theme settings are also defined and are working fine (first row is an example of table entry working fine, other rows are the combinations we have tried to use)
    image

  • In the tenant database (public/AbpSettings) which initially was empty
    image

We are aware, that with the ProviderKey value »null« in the row with the ProviderName »T« (Tenant) is incorrect, but tried it anyway. We have also tried a combination of the above variants (Default, Global, Tenant).

@stale
Copy link

stale bot commented Apr 3, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the inactive label Apr 3, 2022
@stale stale bot closed this as completed Apr 10, 2022
@tinonetic
Copy link

@leonkosak Did you manage to resolve this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants