@Test public void verifyExpiredMetadataHandler() { HiveClientFactory hiveClientFactory = Mockito.mock(HiveClientFactory.class); ExpiredMetadataHandler expiredMetadataHandler = commonBeans.expiredMetadataHandler(hiveClientFactory, metadataRepository, metadataCleaner, pathCleaner); assertThat(expiredMetadataHandler).isInstanceOf(ExpiredMetadataHandler.class); }
@Bean(name = "expiredMetadataHandler") public ExpiredMetadataHandler expiredMetadataHandler( @Qualifier("hiveClientFactory") CleanerClientFactory cleanerClientFactory, HousekeepingMetadataRepository housekeepingMetadataRepository, @Qualifier("hiveTableCleaner") MetadataCleaner metadataCleaner, @Qualifier("s3PathCleaner") PathCleaner pathCleaner) { return new ExpiredMetadataHandler(cleanerClientFactory, housekeepingMetadataRepository, metadataCleaner, pathCleaner); }
CommonBeans { @Bean(name = "expiredMetadataHandler") public ExpiredMetadataHandler expiredMetadataHandler( @Qualifier("hiveClientFactory") CleanerClientFactory cleanerClientFactory, HousekeepingMetadataRepository housekeepingMetadataRepository, @Qualifier("hiveTableCleaner") MetadataCleaner metadataCleaner, @Qualifier("s3PathCleaner") PathCleaner pathCleaner) { return new ExpiredMetadataHandler(cleanerClientFactory, housekeepingMetadataRepository, metadataCleaner, pathCleaner); } }
CommonBeans { @Bean(name = "expiredMetadataHandler") public ExpiredMetadataHandler expiredMetadataHandler( @Qualifier("hiveClientFactory") CleanerClientFactory cleanerClientFactory, HousekeepingMetadataRepository housekeepingMetadataRepository, @Qualifier("hiveTableCleaner") MetadataCleaner metadataCleaner, @Qualifier("s3PathCleaner") PathCleaner pathCleaner) { return new ExpiredMetadataHandler(cleanerClientFactory, housekeepingMetadataRepository, metadataCleaner, pathCleaner); }  }
CommonBeans { @Bean(name = "expiredMetadataHandler") public ExpiredMetadataHandler expiredMetadataHandler( @Qualifier("hiveClientFactory") CleanerClientFactory cleanerClientFactory, HousekeepingMetadataRepository housekeepingMetadataRepository, @Qualifier("hiveTableCleaner") MetadataCleaner metadataCleaner, @Qualifier("s3PathCleaner") PathCleaner pathCleaner) { return new ExpiredMetadataHandler(cleanerClientFactory, housekeepingMetadataRepository, metadataCleaner, pathCleaner); }  @Bean HiveConf hiveConf(@Value("${properties.metastore-uri}") String metastoreUri); @Bean CloseableMetaStoreClientFactory metaStoreClientFactory(); @Bean(name = "hiveClientFactory") CleanerClientFactory clientFactory(
      Supplier<CloseableMetaStoreClient> metaStoreClientSupplier,
      @Value("${properties.dry-run-enabled}") boolean dryRunEnabled); @Bean DeletedMetadataReporter deletedMetadataReporter(
      MeterRegistry meterRegistry,
      @Value("${properties.dry-run-enabled}") boolean dryRunEnabled); @Bean @Profile("default") AmazonS3 amazonS3(); @Bean S3Client s3Client(AmazonS3 amazonS3, @Value("${properties.dry-run-enabled}") boolean dryRunEnabled); @Bean(name = "expiredMetadataHandler") ExpiredMetadataHandler expiredMetadataHandler(
      @Qualifier("hiveClientFactory") CleanerClientFactory cleanerClientFactory,
      HousekeepingMetadataRepository housekeepingMetadataRepository,
      @Qualifier("hiveTableCleaner") MetadataCleaner metadataCleaner,
      @Qualifier("s3PathCleaner") PathCleaner pathCleaner); }
CommonBeans { @Bean(name = "expiredMetadataHandler") public ExpiredMetadataHandler expiredMetadataHandler( @Qualifier("hiveClientFactory") CleanerClientFactory cleanerClientFactory, HousekeepingMetadataRepository housekeepingMetadataRepository, @Qualifier("hiveTableCleaner") MetadataCleaner metadataCleaner, @Qualifier("s3PathCleaner") PathCleaner pathCleaner) { return new ExpiredMetadataHandler(cleanerClientFactory, housekeepingMetadataRepository, metadataCleaner, pathCleaner); }  @Bean HiveConf hiveConf(@Value("${properties.metastore-uri}") String metastoreUri); @Bean CloseableMetaStoreClientFactory metaStoreClientFactory(); @Bean(name = "hiveClientFactory") CleanerClientFactory clientFactory(
      Supplier<CloseableMetaStoreClient> metaStoreClientSupplier,
      @Value("${properties.dry-run-enabled}") boolean dryRunEnabled); @Bean DeletedMetadataReporter deletedMetadataReporter(
      MeterRegistry meterRegistry,
      @Value("${properties.dry-run-enabled}") boolean dryRunEnabled); @Bean @Profile("default") AmazonS3 amazonS3(); @Bean S3Client s3Client(AmazonS3 amazonS3, @Value("${properties.dry-run-enabled}") boolean dryRunEnabled); @Bean(name = "expiredMetadataHandler") ExpiredMetadataHandler expiredMetadataHandler(
      @Qualifier("hiveClientFactory") CleanerClientFactory cleanerClientFactory,
      HousekeepingMetadataRepository housekeepingMetadataRepository,
      @Qualifier("hiveTableCleaner") MetadataCleaner metadataCleaner,
      @Qualifier("s3PathCleaner") PathCleaner pathCleaner);  }