Search in sources :

Example 1 with FileInfoJsonModule

use of com.google.gerrit.server.change.FileInfoJsonModule in project gerrit by GerritCodeReview.

the class InMemoryModule method configure.

@Override
protected void configure() {
    // Do NOT bind @RemotePeer, as it is bound in a child injector of
    // ChangeMergeQueue (bound via GerritGlobalModule below), so there cannot be
    // a binding in the parent injector. If you need @RemotePeer, you must bind
    // it in a child injector of the one containing InMemoryModule. But unless
    // you really need to test something request-scoped, you likely don't
    // actually need it.
    // For simplicity, don't create child injectors, just use this one to get a
    // few required modules.
    Injector cfgInjector = Guice.createInjector(new AbstractModule() {

        @Override
        protected void configure() {
            bind(Config.class).annotatedWith(GerritServerConfig.class).toInstance(cfg);
        }
    });
    bind(GerritRuntime.class).toInstance(GerritRuntime.DAEMON);
    bind(MetricMaker.class).to(DisabledMetricMaker.class);
    install(cfgInjector.getInstance(GerritGlobalModule.class));
    AuthConfig authConfig = cfgInjector.getInstance(AuthConfig.class);
    install(new AuthModule(authConfig));
    install(new GerritApiModule());
    factory(PluginUser.Factory.class);
    install(new PluginApiModule());
    install(new DefaultPermissionBackendModule());
    install(new SearchingChangeCacheImplModule());
    factory(GarbageCollection.Factory.class);
    install(new AuditModule());
    install(new SubscriptionGraphModule());
    install(new SuperprojectUpdateSubmissionListenerModule());
    bindScope(RequestScoped.class, PerThreadRequestScope.REQUEST);
    // It would be nice to use Jimfs for the SitePath, but the biggest blocker is that JGit does not
    // support Path-based Configs, only FileBasedConfig.
    bind(Path.class).annotatedWith(SitePath.class).toInstance(Paths.get("."));
    bind(Config.class).annotatedWith(GerritServerConfig.class).toInstance(cfg);
    bind(GerritOptions.class).toInstance(new GerritOptions(false, false));
    bind(AllProjectsConfigProvider.class).to(FileBasedAllProjectsConfigProvider.class);
    bind(GlobalPluginConfigProvider.class).to(FileBasedGlobalPluginConfigProvider.class);
    bind(GitRepositoryManager.class).to(InMemoryRepositoryManager.class);
    bind(InMemoryRepositoryManager.class).in(SINGLETON);
    bind(TrackingFooters.class).toProvider(TrackingFootersProvider.class).in(SINGLETON);
    bind(SecureStore.class).to(DefaultSecureStore.class);
    install(new InMemorySchemaModule());
    install(NoSshKeyCache.module());
    install(new GerritInstanceNameModule());
    install(new GerritInstanceIdModule());
    install(new CanonicalWebUrlModule() {

        @Override
        protected Class<? extends Provider<String>> provider() {
            return CanonicalWebUrlProvider.class;
        }
    });
    install(new DefaultUrlFormatterModule());
    // Replacement of DiffExecutorModule to not use thread pool in the tests
    install(new AbstractModule() {

        @Override
        protected void configure() {
        }

        @Provides
        @Singleton
        @DiffExecutor
        public ExecutorService createDiffExecutor() {
            return newDirectExecutorService();
        }
    });
    install(new DefaultMemoryCacheModule());
    install(new H2CacheModule());
    install(new FakeEmailSenderModule());
    install(new SignedTokenEmailTokenVerifierModule());
    install(new GpgModule(cfg));
    install(new LocalMergeSuperSetComputationModule());
    bind(AllAccountsIndexer.class).toProvider(Providers.of(null));
    bind(AllChangesIndexer.class).toProvider(Providers.of(null));
    bind(AllGroupsIndexer.class).toProvider(Providers.of(null));
    String indexTypeCfg = cfg.getString("index", null, "type");
    IndexType indexType = new IndexType(indexTypeCfg != null ? indexTypeCfg : "fake");
    // For custom index types, callers must provide their own module.
    if (indexType.isLucene()) {
        install(luceneIndexModule());
    } else if (indexType.isFake()) {
        install(fakeIndexModule());
    }
    bind(ServerInformationImpl.class);
    bind(ServerInformation.class).to(ServerInformationImpl.class);
    install(new RestApiModule());
    install(new OAuthRestModule());
    install(new DefaultProjectNameLockManagerModule());
    install(new FileInfoJsonModule());
    install(new ConfigExperimentFeaturesModule());
    bind(ProjectOperations.class).to(ProjectOperationsImpl.class);
}
Also used : MetricMaker(com.google.gerrit.metrics.MetricMaker) DisabledMetricMaker(com.google.gerrit.metrics.DisabledMetricMaker) RestApiModule(com.google.gerrit.server.restapi.RestApiModule) AuthConfig(com.google.gerrit.server.config.AuthConfig) DefaultProjectNameLockManagerModule(com.google.gerrit.server.project.DefaultProjectNameLockManager.DefaultProjectNameLockManagerModule) GerritGlobalModule(com.google.gerrit.server.config.GerritGlobalModule) SearchingChangeCacheImplModule(com.google.gerrit.server.git.SearchingChangeCacheImpl.SearchingChangeCacheImplModule) GerritRuntime(com.google.gerrit.server.config.GerritRuntime) FakeEmailSenderModule(com.google.gerrit.testing.FakeEmailSender.FakeEmailSenderModule) Injector(com.google.inject.Injector) SuperprojectUpdateSubmissionListenerModule(com.google.gerrit.server.update.SuperprojectUpdateSubmissionListener.SuperprojectUpdateSubmissionListenerModule) ConfigExperimentFeaturesModule(com.google.gerrit.server.experiments.ConfigExperimentFeatures.ConfigExperimentFeaturesModule) AllProjectsConfigProvider(com.google.gerrit.server.config.AllProjectsConfigProvider) FileBasedAllProjectsConfigProvider(com.google.gerrit.server.config.FileBasedAllProjectsConfigProvider) DefaultPermissionBackendModule(com.google.gerrit.server.permissions.DefaultPermissionBackendModule) FileInfoJsonModule(com.google.gerrit.server.change.FileInfoJsonModule) GerritOptions(com.google.gerrit.server.config.GerritOptions) DefaultSecureStore(com.google.gerrit.server.securestore.DefaultSecureStore) SecureStore(com.google.gerrit.server.securestore.SecureStore) SignedTokenEmailTokenVerifierModule(com.google.gerrit.server.mail.SignedTokenEmailTokenVerifier.SignedTokenEmailTokenVerifierModule) Singleton(com.google.inject.Singleton) AuditModule(com.google.gerrit.server.audit.AuditModule) SitePath(com.google.gerrit.server.config.SitePath) DiffExecutor(com.google.gerrit.server.patch.DiffExecutor) Config(org.eclipse.jgit.lib.Config) GerritServerConfig(com.google.gerrit.server.config.GerritServerConfig) AuthConfig(com.google.gerrit.server.config.AuthConfig) FileBasedGlobalPluginConfigProvider(com.google.gerrit.server.config.FileBasedGlobalPluginConfigProvider) GlobalPluginConfigProvider(com.google.gerrit.server.config.GlobalPluginConfigProvider) LocalMergeSuperSetComputationModule(com.google.gerrit.server.submit.LocalMergeSuperSetComputation.LocalMergeSuperSetComputationModule) TrackingFootersProvider(com.google.gerrit.server.config.TrackingFootersProvider) AllChangesIndexer(com.google.gerrit.server.index.change.AllChangesIndexer) GarbageCollection(com.google.gerrit.server.git.GarbageCollection) AllAccountsIndexer(com.google.gerrit.server.index.account.AllAccountsIndexer) PluginApiModule(com.google.gerrit.server.api.PluginApiModule) GerritInstanceNameModule(com.google.gerrit.server.config.GerritInstanceNameModule) ServerInformation(com.google.gerrit.extensions.systemstatus.ServerInformation) OAuthRestModule(com.google.gerrit.httpd.auth.restapi.OAuthRestModule) GpgModule(com.google.gerrit.gpg.GpgModule) GerritApiModule(com.google.gerrit.server.api.GerritApiModule) IndexType(com.google.gerrit.index.IndexType) ProjectOperations(com.google.gerrit.acceptance.testsuite.project.ProjectOperations) GerritServerConfig(com.google.gerrit.server.config.GerritServerConfig) GitRepositoryManager(com.google.gerrit.server.git.GitRepositoryManager) Provides(com.google.inject.Provides) DefaultUrlFormatterModule(com.google.gerrit.server.config.DefaultUrlFormatter.DefaultUrlFormatterModule) AbstractModule(com.google.inject.AbstractModule) CanonicalWebUrlModule(com.google.gerrit.server.config.CanonicalWebUrlModule) FileBasedGlobalPluginConfigProvider(com.google.gerrit.server.config.FileBasedGlobalPluginConfigProvider) AllUsersNameProvider(com.google.gerrit.server.config.AllUsersNameProvider) CanonicalWebUrlProvider(com.google.gerrit.server.config.CanonicalWebUrlProvider) GerritPersonIdentProvider(com.google.gerrit.server.GerritPersonIdentProvider) GlobalPluginConfigProvider(com.google.gerrit.server.config.GlobalPluginConfigProvider) AllProjectsNameProvider(com.google.gerrit.server.config.AllProjectsNameProvider) GerritServerIdProvider(com.google.gerrit.server.config.GerritServerIdProvider) AllProjectsConfigProvider(com.google.gerrit.server.config.AllProjectsConfigProvider) TrackingFootersProvider(com.google.gerrit.server.config.TrackingFootersProvider) FileBasedAllProjectsConfigProvider(com.google.gerrit.server.config.FileBasedAllProjectsConfigProvider) AnonymousCowardNameProvider(com.google.gerrit.server.config.AnonymousCowardNameProvider) Provider(com.google.inject.Provider) DefaultMemoryCacheModule(com.google.gerrit.server.cache.mem.DefaultMemoryCacheModule) H2CacheModule(com.google.gerrit.server.cache.h2.H2CacheModule) AllGroupsIndexer(com.google.gerrit.server.index.group.AllGroupsIndexer) ListeningExecutorService(com.google.common.util.concurrent.ListeningExecutorService) MoreExecutors.newDirectExecutorService(com.google.common.util.concurrent.MoreExecutors.newDirectExecutorService) ExecutorService(java.util.concurrent.ExecutorService) AuthModule(com.google.gerrit.auth.AuthModule) GerritInstanceIdModule(com.google.gerrit.server.config.GerritInstanceIdModule) SubscriptionGraphModule(com.google.gerrit.server.submit.SubscriptionGraph.SubscriptionGraphModule) PluginUser(com.google.gerrit.server.PluginUser)

Example 2 with FileInfoJsonModule

use of com.google.gerrit.server.change.FileInfoJsonModule in project gerrit by GerritCodeReview.

the class GerritGlobalModule method configure.

@Override
protected void configure() {
    bind(EmailExpander.class).toProvider(EmailExpanderProvider.class).in(SINGLETON);
    bind(IdGenerator.class);
    bind(RulesCache.class);
    bind(BlameCache.class).to(BlameCacheImpl.class);
    install(AccountCacheImpl.module());
    install(BatchUpdate.module());
    install(ChangeKindCacheImpl.module());
    install(ChangeFinder.module());
    install(ConflictsCacheImpl.module());
    install(DefaultPreferencesCacheImpl.module());
    install(GroupCacheImpl.module());
    install(GroupIncludeCacheImpl.module());
    install(MergeabilityCacheImpl.module());
    install(ServiceUserClassifierImpl.module());
    install(PatchListCacheImpl.module());
    install(ProjectCacheImpl.module());
    install(DiffOperationsImpl.module());
    install(SectionSortCache.module());
    install(SubmitStrategy.module());
    install(TagCache.module());
    install(PureRevertCache.module());
    install(CommentContextCacheImpl.module());
    install(SubmitRequirementsEvaluatorImpl.module());
    install(new AccessControlModule());
    install(new AccountModule());
    install(new CmdLineParserModule());
    install(new EmailModule());
    install(new ExternalIdCacheModule());
    install(new ExternalIdModule());
    install(new GitModule());
    install(new GroupDbModule());
    install(new GroupModule());
    install(new NoteDbModule());
    install(new PrologModule());
    install(new DefaultSubmitRuleModule());
    install(new IgnoreSelfApprovalRuleModule());
    install(new ReceiveCommitsModule());
    install(new SshAddressesModule());
    install(new FileInfoJsonModule());
    install(ThreadLocalRequestContext.module());
    install(new ApprovalModule());
    install(new MailSoySauceModule());
    factory(CapabilityCollection.Factory.class);
    factory(ChangeData.AssistedFactory.class);
    factory(ChangeJson.AssistedFactory.class);
    factory(ChangeIsVisibleToPredicate.Factory.class);
    factory(DistinctVotersPredicate.Factory.class);
    factory(DeadlineChecker.Factory.class);
    factory(MergeUtil.Factory.class);
    factory(MultiProgressMonitor.Factory.class);
    factory(PatchScriptFactory.Factory.class);
    factory(PatchScriptFactoryForAutoFix.Factory.class);
    factory(ProjectState.Factory.class);
    factory(RevisionJson.Factory.class);
    factory(InboundEmailRejectionSender.Factory.class);
    factory(ExternalUser.Factory.class);
    bind(PermissionCollection.Factory.class);
    bind(AccountVisibility.class).toProvider(AccountVisibilityProvider.class).in(SINGLETON);
    AccountDefaultDisplayName accountDefaultDisplayName = cfg.getEnum("accounts", null, "defaultDisplayName", AccountDefaultDisplayName.FULL_NAME);
    bind(AccountDefaultDisplayName.class).toInstance(accountDefaultDisplayName);
    factory(ProjectOwnerGroupsProvider.Factory.class);
    factory(SubmitRuleEvaluator.Factory.class);
    bind(AuthBackend.class).to(UniversalAuthBackend.class).in(SINGLETON);
    DynamicSet.setOf(binder(), AuthBackend.class);
    bind(GroupControl.Factory.class).in(SINGLETON);
    bind(GroupControl.GenericFactory.class).in(SINGLETON);
    bind(FileTypeRegistry.class).to(MimeUtilFileTypeRegistry.class);
    bind(ToolsCatalog.class);
    bind(EventFactory.class);
    bind(TransferConfig.class);
    bind(GcConfig.class);
    DynamicSet.setOf(binder(), GerritConfigListener.class);
    bind(ChangeCleanupConfig.class);
    bind(AccountDeactivator.class);
    bind(ApprovalsUtil.class);
    bind(FromAddressGenerator.class).toProvider(FromAddressGeneratorProvider.class).in(SINGLETON);
    bind(Boolean.class).annotatedWith(EnablePeerIPInReflogRecord.class).toProvider(EnablePeerIPInReflogRecordProvider.class).in(SINGLETON);
    bind(PatchSetInfoFactory.class);
    bind(IdentifiedUser.GenericFactory.class).in(SINGLETON);
    bind(AccountControl.Factory.class);
    OptionalBinder.newOptionalBinder(binder(), Ticker.class).setDefault().toInstance(Ticker.systemTicker());
    bind(UiActions.class);
    bind(GitReferenceUpdated.class);
    DynamicMap.mapOf(binder(), new TypeLiteral<Cache<?, ?>>() {
    });
    DynamicSet.setOf(binder(), CacheRemovalListener.class);
    DynamicMap.mapOf(binder(), CapabilityDefinition.class);
    DynamicMap.mapOf(binder(), PluginProjectPermissionDefinition.class);
    DynamicSet.setOf(binder(), GitReferenceUpdatedListener.class);
    DynamicSet.setOf(binder(), AssigneeChangedListener.class);
    DynamicSet.setOf(binder(), ChangeAbandonedListener.class);
    DynamicSet.setOf(binder(), ChangeDeletedListener.class);
    DynamicSet.setOf(binder(), CommentAddedListener.class);
    DynamicSet.setOf(binder(), HashtagsEditedListener.class);
    DynamicSet.setOf(binder(), ChangeMergedListener.class);
    bind(ChangeMergedListener.class).annotatedWith(Exports.named("CreateGroupPermissionSyncer")).to(CreateGroupPermissionSyncer.class);
    DynamicSet.setOf(binder(), ChangeRestoredListener.class);
    DynamicSet.setOf(binder(), ChangeRevertedListener.class);
    DynamicSet.setOf(binder(), PrivateStateChangedListener.class);
    DynamicSet.setOf(binder(), ReviewerAddedListener.class);
    DynamicSet.setOf(binder(), ReviewerDeletedListener.class);
    DynamicSet.setOf(binder(), VoteDeletedListener.class);
    DynamicSet.setOf(binder(), WorkInProgressStateChangedListener.class);
    DynamicSet.setOf(binder(), RevisionCreatedListener.class);
    DynamicSet.setOf(binder(), TopicEditedListener.class);
    DynamicSet.setOf(binder(), AgreementSignupListener.class);
    DynamicSet.setOf(binder(), PluginEventListener.class);
    DynamicSet.setOf(binder(), ReceivePackInitializer.class);
    DynamicSet.setOf(binder(), PostReceiveHook.class);
    DynamicSet.setOf(binder(), PreUploadHook.class);
    DynamicSet.setOf(binder(), PostUploadHook.class);
    DynamicSet.setOf(binder(), AccountActivationListener.class);
    DynamicSet.setOf(binder(), AccountIndexedListener.class);
    DynamicSet.setOf(binder(), ChangeIndexedListener.class);
    DynamicSet.setOf(binder(), GroupIndexedListener.class);
    DynamicSet.setOf(binder(), ProjectIndexedListener.class);
    DynamicSet.setOf(binder(), NewProjectCreatedListener.class);
    DynamicSet.setOf(binder(), ProjectDeletedListener.class);
    DynamicSet.setOf(binder(), GarbageCollectorListener.class);
    DynamicSet.setOf(binder(), HeadUpdatedListener.class);
    DynamicSet.setOf(binder(), UsageDataPublishedListener.class);
    DynamicSet.bind(binder(), GitReferenceUpdatedListener.class).to(ReindexAfterRefUpdate.class);
    DynamicSet.bind(binder(), GitReferenceUpdatedListener.class).to(ProjectConfigEntry.UpdateChecker.class);
    DynamicSet.setOf(binder(), EventListener.class);
    DynamicSet.bind(binder(), EventListener.class).to(EventsMetrics.class);
    DynamicSet.setOf(binder(), UserScopedEventListener.class);
    DynamicSet.setOf(binder(), CommitValidationListener.class);
    DynamicSet.bind(binder(), CommitValidationListener.class).to(SubmitRequirementExpressionsValidator.class);
    DynamicSet.setOf(binder(), CommentValidator.class);
    DynamicSet.setOf(binder(), ChangeMessageModifier.class);
    DynamicSet.setOf(binder(), RefOperationValidationListener.class);
    DynamicSet.setOf(binder(), OnSubmitValidationListener.class);
    DynamicSet.setOf(binder(), MergeValidationListener.class);
    DynamicSet.setOf(binder(), ProjectCreationValidationListener.class);
    DynamicSet.setOf(binder(), GroupCreationValidationListener.class);
    DynamicSet.setOf(binder(), HashtagValidationListener.class);
    DynamicSet.setOf(binder(), OutgoingEmailValidationListener.class);
    DynamicSet.setOf(binder(), AccountActivationValidationListener.class);
    DynamicItem.itemOf(binder(), AvatarProvider.class);
    DynamicSet.setOf(binder(), LifecycleListener.class);
    DynamicSet.setOf(binder(), TopMenu.class);
    DynamicMap.mapOf(binder(), DownloadScheme.class);
    DynamicMap.mapOf(binder(), DownloadCommand.class);
    DynamicMap.mapOf(binder(), CloneCommand.class);
    DynamicMap.mapOf(binder(), ReviewerSuggestion.class);
    DynamicSet.bind(binder(), GerritConfigListener.class).toInstance(SuggestReviewers.configListener());
    DynamicSet.setOf(binder(), ExternalIncludedIn.class);
    DynamicMap.mapOf(binder(), ProjectConfigEntry.class);
    DynamicSet.setOf(binder(), PluginPushOption.class);
    DynamicSet.setOf(binder(), PatchSetWebLink.class);
    DynamicSet.setOf(binder(), ResolveConflictsWebLink.class);
    DynamicSet.setOf(binder(), ParentWebLink.class);
    DynamicSet.setOf(binder(), FileWebLink.class);
    DynamicSet.setOf(binder(), FileHistoryWebLink.class);
    DynamicSet.setOf(binder(), DiffWebLink.class);
    DynamicSet.setOf(binder(), EditWebLink.class);
    DynamicSet.setOf(binder(), ProjectWebLink.class);
    DynamicSet.setOf(binder(), BranchWebLink.class);
    DynamicSet.setOf(binder(), TagWebLink.class);
    DynamicMap.mapOf(binder(), OAuthLoginProvider.class);
    DynamicItem.itemOf(binder(), OAuthTokenEncrypter.class);
    DynamicSet.setOf(binder(), AccountExternalIdCreator.class);
    DynamicSet.setOf(binder(), WebUiPlugin.class);
    DynamicItem.itemOf(binder(), AccountPatchReviewStore.class);
    DynamicSet.setOf(binder(), AssigneeValidationListener.class);
    DynamicSet.setOf(binder(), ActionVisitor.class);
    DynamicItem.itemOf(binder(), MergeSuperSetComputation.class);
    DynamicItem.itemOf(binder(), ProjectNameLockManager.class);
    DynamicSet.setOf(binder(), SubmitRule.class);
    DynamicSet.setOf(binder(), SubmitRequirement.class);
    DynamicSet.setOf(binder(), QuotaEnforcer.class);
    DynamicSet.setOf(binder(), PerformanceLogger.class);
    if (cfg.getBoolean("tracing", "exportPerformanceMetrics", false)) {
        DynamicSet.bind(binder(), PerformanceLogger.class).to(PerformanceMetrics.class);
    }
    DynamicSet.setOf(binder(), RequestListener.class);
    DynamicSet.bind(binder(), RequestListener.class).to(TraceRequestListener.class);
    DynamicSet.setOf(binder(), ChangeETagComputation.class);
    DynamicSet.setOf(binder(), ExceptionHook.class);
    DynamicSet.bind(binder(), ExceptionHook.class).to(ExceptionHookImpl.class);
    DynamicSet.setOf(binder(), MailSoyTemplateProvider.class);
    DynamicSet.setOf(binder(), OnPostReview.class);
    DynamicMap.mapOf(binder(), AccountTagProvider.class);
    DynamicMap.mapOf(binder(), MailFilter.class);
    bind(MailFilter.class).annotatedWith(Exports.named("ListMailFilter")).to(ListMailFilter.class);
    bind(AutoReplyMailFilter.class).annotatedWith(Exports.named("AutoReplyMailFilter")).to(AutoReplyMailFilter.class);
    factory(UploadValidators.Factory.class);
    DynamicSet.setOf(binder(), UploadValidationListener.class);
    bind(CommentValidator.class).annotatedWith(Exports.named(CommentCountValidator.class.getSimpleName())).to(CommentCountValidator.class);
    bind(CommentValidator.class).annotatedWith(Exports.named(CommentSizeValidator.class.getSimpleName())).to(CommentSizeValidator.class);
    bind(CommentValidator.class).annotatedWith(Exports.named(CommentCumulativeSizeValidator.class.getSimpleName())).to(CommentCumulativeSizeValidator.class);
    DynamicMap.mapOf(binder(), DynamicOptions.DynamicBean.class);
    DynamicMap.mapOf(binder(), ChangeQueryBuilder.ChangeOperatorFactory.class);
    DynamicMap.mapOf(binder(), ChangeQueryBuilder.ChangeHasOperandFactory.class);
    DynamicMap.mapOf(binder(), ChangeQueryBuilder.ChangeIsOperandFactory.class);
    DynamicSet.setOf(binder(), ChangePluginDefinedInfoFactory.class);
    install(new GitwebConfig.LegacyModule(cfg));
    bind(AnonymousUser.class);
    factory(AbandonOp.Factory.class);
    factory(AccountMergeValidator.Factory.class);
    factory(GroupMergeValidator.Factory.class);
    factory(RefOperationValidators.Factory.class);
    factory(OnSubmitValidators.Factory.class);
    factory(MergeValidators.Factory.class);
    factory(ProjectConfigValidator.Factory.class);
    factory(NotesBranchUtil.Factory.class);
    factory(MergedByPushOp.Factory.class);
    factory(GitModules.Factory.class);
    factory(VersionedAuthorizedKeys.Factory.class);
    factory(StoreSubmitRequirementsOp.Factory.class);
    factory(FileEditsPredicate.Factory.class);
    bind(AccountManager.class);
    bind(SubscriptionGraph.Factory.class).to(ConfiguredSubscriptionGraphFactory.class);
    bind(new TypeLiteral<List<CommentLinkInfo>>() {
    }).toProvider(CommentLinkProvider.class);
    DynamicSet.bind(binder(), GerritConfigListener.class).to(CommentLinkProvider.class);
    bind(ReloadPluginListener.class).annotatedWith(UniqueAnnotations.create()).to(PluginConfigFactory.class);
    DynamicMap.mapOf(binder(), ExternalIdUpsertPreprocessor.class);
}
Also used : DynamicOptions(com.google.gerrit.server.DynamicOptions) MailSoySauceModule(com.google.gerrit.server.mail.send.MailSoySauceModule) ReceiveCommitsModule(com.google.gerrit.server.git.receive.ReceiveCommitsModule) NoteDbModule(com.google.gerrit.server.notedb.NoteDbModule) GroupModule(com.google.gerrit.server.restapi.group.GroupModule) EmailModule(com.google.gerrit.server.mail.EmailModule) MimeUtilFileTypeRegistry(com.google.gerrit.server.mime.MimeUtilFileTypeRegistry) FileTypeRegistry(com.google.gerrit.server.mime.FileTypeRegistry) ExternalIdCacheModule(com.google.gerrit.server.account.externalids.ExternalIdCacheModule) IgnoreSelfApprovalRuleModule(com.google.gerrit.server.rules.IgnoreSelfApprovalRule.IgnoreSelfApprovalRuleModule) AccountModule(com.google.gerrit.server.account.AccountModule) UniversalAuthBackend(com.google.gerrit.server.auth.UniversalAuthBackend) ApprovalModule(com.google.gerrit.server.query.approval.ApprovalModule) FromAddressGeneratorProvider(com.google.gerrit.server.mail.send.FromAddressGeneratorProvider) FileInfoJsonModule(com.google.gerrit.server.change.FileInfoJsonModule) PatchScriptFactoryForAutoFix(com.google.gerrit.server.patch.PatchScriptFactoryForAutoFix) DefaultSubmitRuleModule(com.google.gerrit.server.rules.DefaultSubmitRule.DefaultSubmitRuleModule) CapabilityCollection(com.google.gerrit.server.account.CapabilityCollection) AbandonOp(com.google.gerrit.server.change.AbandonOp) GitModules(com.google.gerrit.server.submit.GitModules) ChangeData(com.google.gerrit.server.query.change.ChangeData) GitReferenceUpdatedListener(com.google.gerrit.extensions.events.GitReferenceUpdatedListener) CommentCumulativeSizeValidator(com.google.gerrit.server.git.validators.CommentCumulativeSizeValidator) SubmitRuleEvaluator(com.google.gerrit.server.project.SubmitRuleEvaluator) AccountDefaultDisplayName(com.google.gerrit.extensions.common.AccountDefaultDisplayName) PatchScriptFactory(com.google.gerrit.server.patch.PatchScriptFactory) ExternalIdModule(com.google.gerrit.server.account.externalids.ExternalIdModule) MultiProgressMonitor(com.google.gerrit.server.git.MultiProgressMonitor) ProjectState(com.google.gerrit.server.project.ProjectState) CmdLineParserModule(com.google.gerrit.server.CmdLineParserModule) RevisionJson(com.google.gerrit.server.change.RevisionJson) DeadlineChecker(com.google.gerrit.server.DeadlineChecker) ProjectConfigValidator(com.google.gerrit.server.git.validators.MergeValidators.ProjectConfigValidator) DistinctVotersPredicate(com.google.gerrit.server.query.change.DistinctVotersPredicate) TagCache(com.google.gerrit.server.git.TagCache) PureRevertCache(com.google.gerrit.server.git.PureRevertCache) BlameCache(com.google.gitiles.blame.cache.BlameCache) SectionSortCache(com.google.gerrit.server.permissions.SectionSortCache) Cache(com.google.common.cache.Cache) RulesCache(com.google.gerrit.server.rules.RulesCache) PermissionCollection(com.google.gerrit.server.permissions.PermissionCollection) OnSubmitValidators(com.google.gerrit.server.git.validators.OnSubmitValidators) CommentSizeValidator(com.google.gerrit.server.git.validators.CommentSizeValidator) GroupDbModule(com.google.gerrit.server.group.db.GroupDbModule) ChangePluginDefinedInfoFactory(com.google.gerrit.server.change.ChangePluginDefinedInfoFactory) PatchSetInfoFactory(com.google.gerrit.server.patch.PatchSetInfoFactory) ConfiguredSubscriptionGraphFactory(com.google.gerrit.server.submit.ConfiguredSubscriptionGraphFactory) PatchScriptFactory(com.google.gerrit.server.patch.PatchScriptFactory) EventFactory(com.google.gerrit.server.events.EventFactory) InboundEmailRejectionSender(com.google.gerrit.server.mail.send.InboundEmailRejectionSender) SshAddressesModule(com.google.gerrit.server.ssh.SshAddressesModule) UploadValidators(com.google.gerrit.server.git.validators.UploadValidators) ChangeIsVisibleToPredicate(com.google.gerrit.server.query.change.ChangeIsVisibleToPredicate) TypeLiteral(com.google.inject.TypeLiteral) MergeUtil(com.google.gerrit.server.git.MergeUtil) AccountControl(com.google.gerrit.server.account.AccountControl) RefOperationValidators(com.google.gerrit.server.git.validators.RefOperationValidators) EventListener(com.google.gerrit.server.events.EventListener) UserScopedEventListener(com.google.gerrit.server.events.UserScopedEventListener) PluginEventListener(com.google.gerrit.extensions.events.PluginEventListener) MergeValidators(com.google.gerrit.server.git.validators.MergeValidators) ChangeQueryBuilder(com.google.gerrit.server.query.change.ChangeQueryBuilder) AccessControlModule(com.google.gerrit.server.project.AccessControlModule) ChangeJson(com.google.gerrit.server.change.ChangeJson) PerformanceLogger(com.google.gerrit.server.logging.PerformanceLogger) RequestListener(com.google.gerrit.server.RequestListener) TraceRequestListener(com.google.gerrit.server.TraceRequestListener) StoreSubmitRequirementsOp(com.google.gerrit.server.notedb.StoreSubmitRequirementsOp) PrologModule(com.google.gerrit.server.rules.PrologModule) ExternalUser(com.google.gerrit.server.ExternalUser) CommitValidationListener(com.google.gerrit.server.git.validators.CommitValidationListener) GitModule(com.google.gerrit.server.git.GitModule) BlameCache(com.google.gitiles.blame.cache.BlameCache) GroupMergeValidator(com.google.gerrit.server.git.validators.MergeValidators.GroupMergeValidator) ExceptionHook(com.google.gerrit.server.ExceptionHook) AccountVisibilityProvider(com.google.gerrit.server.account.AccountVisibilityProvider) CommentLinkInfo(com.google.gerrit.extensions.api.projects.CommentLinkInfo) NotesBranchUtil(com.google.gerrit.server.git.NotesBranchUtil) VersionedAuthorizedKeys(com.google.gerrit.server.account.VersionedAuthorizedKeys) MergedByPushOp(com.google.gerrit.server.git.MergedByPushOp) CommentCountValidator(com.google.gerrit.server.git.validators.CommentCountValidator) AccountMergeValidator(com.google.gerrit.server.git.validators.MergeValidators.AccountMergeValidator) FileEditsPredicate(com.google.gerrit.server.query.FileEditsPredicate)

Aggregations

FileInfoJsonModule (com.google.gerrit.server.change.FileInfoJsonModule)2 Cache (com.google.common.cache.Cache)1 ListeningExecutorService (com.google.common.util.concurrent.ListeningExecutorService)1 MoreExecutors.newDirectExecutorService (com.google.common.util.concurrent.MoreExecutors.newDirectExecutorService)1 ProjectOperations (com.google.gerrit.acceptance.testsuite.project.ProjectOperations)1 AuthModule (com.google.gerrit.auth.AuthModule)1 CommentLinkInfo (com.google.gerrit.extensions.api.projects.CommentLinkInfo)1 AccountDefaultDisplayName (com.google.gerrit.extensions.common.AccountDefaultDisplayName)1 GitReferenceUpdatedListener (com.google.gerrit.extensions.events.GitReferenceUpdatedListener)1 PluginEventListener (com.google.gerrit.extensions.events.PluginEventListener)1 ServerInformation (com.google.gerrit.extensions.systemstatus.ServerInformation)1 GpgModule (com.google.gerrit.gpg.GpgModule)1 OAuthRestModule (com.google.gerrit.httpd.auth.restapi.OAuthRestModule)1 IndexType (com.google.gerrit.index.IndexType)1 DisabledMetricMaker (com.google.gerrit.metrics.DisabledMetricMaker)1 MetricMaker (com.google.gerrit.metrics.MetricMaker)1 CmdLineParserModule (com.google.gerrit.server.CmdLineParserModule)1 DeadlineChecker (com.google.gerrit.server.DeadlineChecker)1 DynamicOptions (com.google.gerrit.server.DynamicOptions)1 ExceptionHook (com.google.gerrit.server.ExceptionHook)1