use of io.quarkus.arc.deployment.UnremovableBeanBuildItem in project camel-quarkus by apache.
the class GooglePubsubProcessor method markObjectMapperUnremovable.
@BuildStep
public void markObjectMapperUnremovable(BuildProducer<UnremovableBeanBuildItem> unremovable) {
unremovable.produce(new UnremovableBeanBuildItem(new UnremovableBeanBuildItem.BeanClassNameExclusion(ObjectMapper.class.getName())));
unremovable.produce(new UnremovableBeanBuildItem(new UnremovableBeanBuildItem.BeanClassNameExclusion(ObjectMapperProducer.class.getName())));
}
use of io.quarkus.arc.deployment.UnremovableBeanBuildItem in project camel-quarkus by apache.
the class CamelUnremovableBeansProcessor method unremovableCamelBeans.
@BuildStep
UnremovableBeanBuildItem unremovableCamelBeans(BuildTimeCamelCatalogBuildItem camelCatalogBuildItem) {
BuildTimeCamelCatalog catalog = camelCatalogBuildItem.getCatalog();
Set<DotName> unremovableClasses = catalog.getAllOptions().stream().filter(option -> option.getType().equals("object")).filter(option -> !option.getJavaType().startsWith("java.lang")).map(BaseOptionModel::getJavaType).map(DotName::createSimple).collect(Collectors.toSet());
if (LOGGER.isDebugEnabled()) {
unremovableClasses.stream().forEach(unremovableClass -> LOGGER.debug("Registering camel unremovable bean class: {}", unremovableClass));
}
return UnremovableBeanBuildItem.beanTypes(unremovableClasses);
}
Aggregations