docs: private BeanDiscoveryMode getBeanDiscoveryMode() {
          if (beanDiscoveryMode == null) {
              BeansXml beansXml = getBeansXml();
  
              beanDiscoveryMode = BeanDiscoveryMode.ANNOTATED;
              if (beansXml != null) {
                  beanDiscoveryMode = beansXml.getBeanDiscoveryMode();
              } else if ((cdiRuntime.isImplicitBeanArchivesScanningDisabled(this.archive) || isExtension())) {
                  // If the server.xml has the configuration of enableImplicitBeanArchives sets to false, we will not scan the implicit bean archives
                  beanDiscoveryMode = BeanDiscoveryMode.NONE;
              }
          }
          return beanDiscoveryMode;
  
      }