{@link JpaDistributionSetManagement} bean.

@return a new {@link DistributionSetManagement}
432334
@Bean
    @ConditionalOnMissingBean
    DistributionSetTypeManagement distributionSetTypeManagement(
            final DistributionSetTypeRepository distributionSetTypeRepository,
            final SoftwareModuleTypeRepository softwareModuleTypeRepository,
            final DistributionSetRepository distributionSetRepository,
            final VirtualPropertyReplacer virtualPropertyReplacer, final NoCountPagingRepository criteriaNoCountDao,
            final JpaProperties properties, final QuotaManagement quotaManagement) {
        return new JpaDistributionSetTypeManagement(distributionSetTypeRepository, softwareModuleTypeRepository,
                distributionSetRepository, virtualPropertyReplacer, criteriaNoCountDao, properties.getDatabase(),
                quotaManagement);
    }
427227
@XmlElementDecl(namespace = "http://www.ibm.com/websphere/wim", name = "manager")
    public JAXBElement<IdentifierType> createManager(IdentifierType value) {
        return new JAXBElement<IdentifierType>(_Manager_QNAME, IdentifierType.class, null, value);
    }
859554
@Override
    public Set<BeanDefinitionHolder> doScan(String... basePackages) {
        Set<BeanDefinitionHolder> beanDefinitions = super.doScan(basePackages);

        if (beanDefinitions.isEmpty()) {
            log.warn("No WestCacheable was found in '{}' package. " +
                            "Please check your configuration.",
                    Arrays.toString(basePackages));
            return beanDefinitions;
        }

        for (val holder : beanDefinitions) {
            val definition = (GenericBeanDefinition) holder.getBeanDefinition();
            log.debug("Creating WestCacheableFactoryBean with name '{}' and '{}'",
                    holder.getBeanName(), definition.getBeanClassName());

            // the mapper interface is the original class of the bean
            // but, the actual class of the bean is MapperFactoryBean
            definition.getPropertyValues().add("xyzInterface", definition.getBeanClassName());
            definition.setBeanClass(WestCacheableFactoryBean.class);
        }

        return beanDefinitions;
    }
982055
public static LocalContainerEntityManagerFactoryBean newHibernateEntityManagerFactoryBean(final JpaConfigDataHolder config,
                                                                                              final AbstractJpaProperties jpaProperties) {
        val bean = new LocalContainerEntityManagerFactoryBean();
        bean.setJpaVendorAdapter(config.getJpaVendorAdapter());

        if (StringUtils.isNotBlank(config.getPersistenceUnitName())) {
            bean.setPersistenceUnitName(config.getPersistenceUnitName());
        }
        bean.setPackagesToScan(config.getPackagesToScan().toArray(ArrayUtils.EMPTY_STRING_ARRAY));

        if (config.getDataSource() != null) {
            bean.setDataSource(config.getDataSource());
        }

        val properties = new Properties();
        properties.put(Environment.DIALECT, jpaProperties.getDialect());
        properties.put(Environment.HBM2DDL_AUTO, jpaProperties.getDdlAuto());
        properties.put(Environment.STATEMENT_BATCH_SIZE, jpaProperties.getBatchSize());
        if (StringUtils.isNotBlank(jpaProperties.getDefaultCatalog())) {
            properties.put(Environment.DEFAULT_CATALOG, jpaProperties.getDefaultCatalog());
        }
        if (StringUtils.isNotBlank(jpaProperties.getDefaultSchema())) {
            properties.put(Environment.DEFAULT_SCHEMA, jpaProperties.getDefaultSchema());
        }
        properties.put(Environment.ENABLE_LAZY_LOAD_NO_TRANS, Boolean.TRUE);
        properties.put(Environment.FORMAT_SQL, Boolean.TRUE);
        properties.put("hibernate.connection.useUnicode", Boolean.TRUE);
        properties.put("hibernate.connection.characterEncoding", StandardCharsets.UTF_8.name());
        properties.put("hibernate.connection.charSet", StandardCharsets.UTF_8.name());
        if (StringUtils.isNotBlank(jpaProperties.getPhysicalNamingStrategyClassName())) {
            properties.put(Environment.PHYSICAL_NAMING_STRATEGY, jpaProperties.getPhysicalNamingStrategyClassName());
        }
        properties.putAll(jpaProperties.getProperties());
        bean.setJpaProperties(properties);
        return bean;
    }
849266
public List<FacesConfigManagedBeanType<WebFacesConfigDescriptor>> getAllManagedBean()
   {
      List<FacesConfigManagedBeanType<WebFacesConfigDescriptor>> list = new ArrayList<FacesConfigManagedBeanType<WebFacesConfigDescriptor>>();
      List<Node> nodeList = model.get("managed-bean");
      for(Node node: nodeList)
      {
         FacesConfigManagedBeanType<WebFacesConfigDescriptor>  type = new FacesConfigManagedBeanTypeImpl<WebFacesConfigDescriptor>(this, "managed-bean", model, node);
         list.add(type);
      }
      return list;
   }
801608
public FacesConfigManagedBeanType<WebFacesConfigDescriptor> getOrCreateManagedBean()
   {
      List<Node> nodeList = model.get("managed-bean");
      if (nodeList != null &&  nodeList.size() > 0)
      {
         return new FacesConfigManagedBeanTypeImpl<WebFacesConfigDescriptor>(this, "managed-bean", model, nodeList.get(0));
      }
      return createManagedBean();
   }
1259409
@Override
    public <T> Producer<T> createProducer(final Bean<X> declaringBean, final Bean<T> bean, DisposalMethod<X, T> disposalMethod) {
        EnhancedAnnotatedField<T, X> enhancedField = getManager().getServices().get(MemberTransformer.class).loadEnhancedMember(field, getManager().getId());
        return new ProducerFieldProducer<X, T>(enhancedField, disposalMethod) {

            @Override
            public AnnotatedField<X> getAnnotated() {
                return field;
            }

            @Override
            public BeanManagerImpl getBeanManager() {
                return getManager();
            }

            @Override
            public Bean<X> getDeclaringBean() {
                return declaringBean;
            }

            @Override
            public Bean<T> getBean() {
                return bean;
            }
        };
    }
261737
public DDF newDDF(DDFManager manager) throws DDFException {
    DDF ddf = this.newDDF(new Class<?>[] { DDFManager.class }, new Object[] { manager });
    ddf.getPersistenceHandler().setPersistable(false);
    return ddf;
  }
1001144
@Bean(name = "beanManager")
    @ClientScope
    protected BeanManager createManager(RemotingContext remotingContext) {
        Assert.requireNonNull(remotingContext, "remotingContext");
        return remotingContext.getBeanManager();
    }
50913
@Bean
    @ConditionalOnMissingBean
    TargetManagement targetManagement(final EntityManager entityManager, final QuotaManagement quotaManagement,
            final TargetRepository targetRepository, final TargetMetadataRepository targetMetadataRepository,
            final RolloutGroupRepository rolloutGroupRepository,
            final DistributionSetRepository distributionSetRepository,
            final TargetFilterQueryRepository targetFilterQueryRepository,
            final TargetTagRepository targetTagRepository, final NoCountPagingRepository criteriaNoCountDao,
            final ApplicationEventPublisher eventPublisher, final BusProperties bus, final TenantAware tenantAware,
            final AfterTransactionCommitExecutor afterCommit, final VirtualPropertyReplacer virtualPropertyReplacer,
            final JpaProperties properties) {
        return new JpaTargetManagement(entityManager, quotaManagement, targetRepository, targetMetadataRepository,
                rolloutGroupRepository, distributionSetRepository, targetFilterQueryRepository, targetTagRepository,
                criteriaNoCountDao, eventPublisher, bus, tenantAware, afterCommit, virtualPropertyReplacer,
                properties.getDatabase());
    }
787701
public static Specification<JpaDistributionSet> byType(final DistributionSetType type) {
        return (targetRoot, query, cb) -> cb.equal(targetRoot.<JpaDistributionSetType> get(JpaDistributionSet_.type),
                type);

    }
376755
public static <T> NewManagedBean<T> of(BeanAttributes<T> attributes, EnhancedAnnotatedType<T> clazz, BeanManagerImpl beanManager) {
        return new NewManagedBean<T>(attributes, clazz, new StringBeanIdentifier(BeanIdentifiers.forNewManagedBean(clazz)), beanManager);
    }
1360142
public void populateTableByDistributionSet(final DistributionSet distributionSet) {
        removeAllItems();
        if (distributionSet == null) {
            return;
        }

        final Container dataSource = getContainerDataSource();
        final List<TargetFilterQuery> filters = distributionSet.getAutoAssignFilters();
        filters.forEach(query -> {
            final Object itemId = dataSource.addItem();
            final Item item = dataSource.getItem(itemId);
            item.getItemProperty(TFQ_NAME).setValue(query.getName());
            item.getItemProperty(TFQ_QUERY).setValue(query.getQuery());
        });

    }
841428
public static Specification<JpaDistributionSetType> byName(final String name) {
        return (targetRoot, query, cb) -> cb.equal(targetRoot.<String> get(JpaDistributionSetType_.name), name);
    }
369825
@VisibleForTesting
  static Distribution createDistribution(io.opencensus.metrics.export.Distribution distribution) {
    Distribution.Builder builder =
        Distribution.newBuilder()
            .setBucketOptions(createBucketOptions(distribution.getBucketOptions()))
            .setCount(distribution.getCount())
            .setMean(
                distribution.getCount() == 0 ? 0 : distribution.getSum() / distribution.getCount())
            .setSumOfSquaredDeviation(distribution.getSumOfSquaredDeviations());
    setBucketCountsAndExemplars(distribution.getBuckets(), builder);
    return builder.build();
  }
358280
public static <T> ManagedBean<T> of(BeanAttributes<T> attributes, EnhancedAnnotatedType<T> clazz, BeanManagerImpl beanManager) {
        return new ManagedBean<T>(attributes, clazz, createId(attributes, clazz), beanManager);
    }
439563
@Bean
	public DaoConfig daoConfig() {
		DaoConfig retVal = new DaoConfig();
		retVal.setAllowMultipleDelete(true);
		return retVal;
	}