code: public void scanConfigurableBeans(String... basePackages) throws BeanRuleException {
          if (basePackages == null || basePackages.length == 0) {
              return;
          }
  
          log.info("Auto component scanning on packages [" + StringUtils.joinCommaDelimitedList(basePackages) + "]");
  
          for (String basePackage : basePackages) {
              BeanClassScanner scanner = new BeanClassScanner(classLoader);
              List<BeanRule> beanRules = new ArrayList<>();
              scanner.scan(basePackage + ".**", (resourceName, targetClass) -> {
                  if (targetClass.isAnnotationPresent(Component.class)) {
                      BeanRule beanRule = new BeanRule();
                      beanRule.setBeanClass(targetClass);
                      beanRule.setScopeType(ScopeType.SINGLETON);
                      beanRules.add(beanRule);
                  }
              });
              for (BeanRule beanRule : beanRules) {
                  saveConfigurableBeanRule(beanRule);
              }
          }
      }
docs: Scans for annotated components.
  
  @param basePackages the base packages to scan for annotated components
  @throws BeanRuleException if an illegal bean rule is found