Creating and editing an external dashboard

I’m trying this new feature about external dasbhoard based on superset

but what is hiding this line

If the system has been configured to support embedded (Superset) dashboards

I understand that we need the gateway running
but is there something to change in dhis.conf or system settings ?

perhaps answering my own question in the system settings the analytics section :wink:

Now check the “Enable embedded dashboards” checkbox in system settings

1 Like

it’s a bit weird to point to the bao page. Shouldn’t dhis2 offer something more open source with clearer release management ?

Note I found this GitHub - hisptz/bao-ap-docker: A docker compose setup for the analytics platform with all its components and dependencies.
but it’s not helping with errors I have for the moment

gateway-1     | 22-12-2025 21:37:16.102 DEBUG o.s.b.d.LoggingFailureAnalysisReporter - Application failed to start due to an exception
gateway-1     | org.springframework.beans.factory.support.BeanDefinitionOverrideException: Invalid bean definition with name 'conventionErrorViewResolver' defined in class path resource [org/springframework/boot/webmvc/autoconfigure/error/ErrorMvcAutoConfiguration$DefaultErrorViewResolverConfiguration.class]: Cannot register bean definition [Root bean: class=null; scope=; abstract=false; lazyInit=null; autowireMode=3; dependencyCheck=0; autowireCandidate=true; primary=false; fallback=false; factoryBeanName=org.springframework.boot.webmvc.autoconfigure.error.ErrorMvcAutoConfiguration$DefaultErrorViewResolverConfiguration; factoryMethodName=conventionErrorViewResolver; initMethodNames=null; destroyMethodNames=[(inferred)]; defined in class path resource [org/springframework/boot/webmvc/autoconfigure/error/ErrorMvcAutoConfiguration$DefaultErrorViewResolverConfiguration.class]] for bean 'conventionErrorViewResolver' since there is already [Root bean: class=null; scope=; abstract=false; lazyInit=null; autowireMode=3; dependencyCheck=0; autowireCandidate=true; primary=false; fallback=false; factoryBeanName=org.springframework.boot.autoconfigure.web.servlet.error.ErrorMvcAutoConfiguration$DefaultErrorViewResolverConfiguration; factoryMethodName=conventionErrorViewResolver; initMethodNames=null; destroyMethodNames=[(inferred)]; defined in class path resource [org/springframework/boot/autoconfigure/web/servlet/error/ErrorMvcAutoConfiguration$DefaultErrorViewResolverConfiguration.class]] bound.
gateway-1     |         at org.springframework.beans.factory.support.DefaultListableBeanFactory.registerBeanDefinition(DefaultListableBeanFactory.java:1263)
gateway-1     |         at org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.loadBeanDefinitionsForBeanMethod(ConfigurationClassBeanDefinitionReader.java:305)
gateway-1     |         at org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.loadBeanDefinitionsForConfigurationClass(ConfigurationClassBeanDefinitionReader.java:144)
gateway-1     |         at org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.loadBeanDefinitions(ConfigurationClassBeanDefinitionReader.java:120)
gateway-1     |         at org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:430)
gateway-1     |         at org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:290)
gateway-1     |         at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:349)
gateway-1     |         at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:118)
gateway-1     |         at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:791)
gateway-1     |         at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:609)
gateway-1     |         at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:146)
gateway-1     |         at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:752)
gateway-1     |         at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:439)
gateway-1     |         at org.springframework.boot.SpringApplication.run(SpringApplication.java:318)
gateway-1     |         at org.springframework.boot.SpringApplication.run(SpringApplication.java:1361)
gateway-1     |         at org.springframework.boot.SpringApplication.run(SpringApplication.java:1350)
gateway-1     |         at com.bao.gateway.conf.Dhis2SupersetGatewayApp.main(Dhis2SupersetGatewayApp.java:76)
gateway-1     |         at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
gateway-1     |         at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
gateway-1     |         at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
gateway-1     |         at java.base/java.lang.reflect.Method.invoke(Method.java:569)
gateway-1     |         at org.springframework.boot.loader.launch.Launcher.launch(Launcher.java:106)
gateway-1     |         at org.springframework.boot.loader.launch.Launcher.launch(Launcher.java:64)
gateway-1     |         at org.springframework.boot.loader.launch.JarLauncher.main(JarLauncher.java:40)
gateway-1     | 22-12-2025 21:37:16.104 ERROR o.s.b.d.LoggingFailureAnalysisReporter -

I think I’ll need to dig a bit deeper within Bitbucket

the dhis2-superset-gateway app is broken due to a dependency upgrade
reverting it the app boot again.

diff --git a/dhis2-superset-gateway/pom.xml b/dhis2-superset-gateway/pom.xml
index 736f8d2..681581b 100644
--- a/dhis2-superset-gateway/pom.xml
+++ b/dhis2-superset-gateway/pom.xml
@@ -23,7 +23,7 @@
     <dhis2-java-client.version>2.5.0</dhis2-java-client.version>
     <google-java-format.version>1.26.0</google-java-format.version>
     <spotless.version>3.1.0</spotless.version>
-    <springdoc-openapi.version>3.0.0</springdoc-openapi.version>
+    <springdoc-openapi.version>2.8.14</springdoc-openapi.version>
   </properties>

   <dependencies>

Hi

Yes, your answer was correct, it needs to be enabled from the Settings app (no dhis.conf changes or anything).

It’s not clear, what do you mean by hiding? :grinning_face:

I’d like to quote the “Embedded dashboards” ticket (@jan),

The app will be responsible for fetching and embedding external Superset dashboards coming from an external service and storing them as DHIS2 Dashboard objects.

As you can see, the “Superset Connector” provided by BAO Systems is a contribution to make it easier for developers/implementers to connect with Superset dashboards. However, the Embedded dashboards feature is not restricted to the BAO connector. Other developers can probably develop other utilities if needed.

This doesn’t seem relevant to the feature we’re talking about?

Could you share more where you’re seeing errors?

Thanks!

  • The error at startup is the one with the duplicated BeanDefinitionOverrideException
    reverting the dependency I see the logs but the app continue to start. I guess a transitive dependency problem with multiple

  • The repo has a superset gateway dockerized which is my end goal, so it was a bit helping to have urls for the jar path for the conf (which well hidden in the bao documentation)

  • To disambiguate the “If the system has been configured to support embedded (Superset) dashboards” I would add a link to the global system settings app or the admin part of the doc.

  • I would have hoped the gateway to become a repo in the dhis2 organisation, with clearer release management

  • my current status is I do have a guest token but superset refuse to display it, still investigating what is going on

    • some choices in the config to disable csrf are bit annoying to me

finally found the previous error was from the allowed domains

I have the dashboard showing up now !

Is there a place where I can look at the contract to implement an alternative implementation ?
is there other endpoint then /superset-gateway/api/guestTokens/dhis2/dashboards/eO2PeJVRmCA ? Do you a link to the original jira ?

Thanks for looking into it. Season’s greetings and best wishes for 2026 !

I see, thanks for the hint! It looks like HISP Tanzania included several analytics packages as well. :+1: :slight_smile:

I agree, thanks for the suggestion! Would you like to make a docs PR here: dashboard-app/docs/dashboards.md at master · dhis2/dashboard-app · GitHub ?

So great to see that you’ve navigated all that, found the solution, and set up a Superset dashboard! :clap: Thanks for sharing all that from zero-to-hero experience in the CoP :grin:

As far as I can see, the URL superset/dashboard/{id}/?standalone=true&username={username}&locale={locale} is needed to retrieve the external dashboard.

DHIS2 has an open space for contributions. As long as it’s not the same implementation as (Bitbucket) then you’re welcome to fix something if there’s a use-case not being covered. Please check out this page with some helpful resources: Extend - DHIS2

These are the main relevant Jira tickets that I found, Jira - Jira - Jira

I hope this is helpful .. :slight_smile:

Thank you! To you too! :clap: :tada:

Hello @Stephan_Mestach

Glad you got the setup working for you. I just wanted to point out that the dhis2-gateway in the bao-ap-docker setup is a part of setting up the analytics platform to work with DHIS2 using the Super BI app.

You can check how the Super BI app interacts with the gateway in its source code. You can also view the gateway API documentation through the Swagger UI available in your hosted gateway at http://your-hosted-gateway-url/superset-gateway/swagger-ui/index.html

Regards.

2 Likes

from my understanding “Super BI app” is no more necessary ?
it’s what has been contributed to dhis2 “core” no : to show a modal to create “external” dashboards ?

from my small test the only call I saw from dhis2 modal/dashboards : it does a post to /superset-gateway/api/guestTokens/dhis2/dashboards/<dashboard_uuid> to create the guest token

I made some modifications to the gateway on my laptop to support CSRF enabled on superset
Would you be interested by a contribution/pull request ?

1 Like

I’m not part of the team maintaining the gateway repository, but I think you can create a pull request and contribute to it. :pray:

Regards.

1 Like

The issue with the dhis2-superset-gateway service has been fixed. Please re-download the JAR file.

2 Likes