| | |
| | | model.addOwners(ArrayUtils.fromString(getConfig(config, "owner", "")));
|
| | | model.useTickets = getConfig(config, "useTickets", false);
|
| | | model.useDocs = getConfig(config, "useDocs", false);
|
| | | model.useIncrementalRevisionNumbers = getConfig(config, "useIncrementalRevisionNumbers", false);
|
| | | model.allowForks = getConfig(config, "allowForks", true);
|
| | | model.accessRestriction = AccessRestrictionType.fromName(getConfig(config,
|
| | | "accessRestriction", settings.getString(Keys.git.defaultAccessRestriction, null)));
|
| | |
| | | config.setString(Constants.CONFIG_GITBLIT, null, "owner", ArrayUtils.toString(repository.owners));
|
| | | config.setBoolean(Constants.CONFIG_GITBLIT, null, "useTickets", repository.useTickets);
|
| | | config.setBoolean(Constants.CONFIG_GITBLIT, null, "useDocs", repository.useDocs);
|
| | | config.setBoolean(Constants.CONFIG_GITBLIT, null, "useIncrementalRevisionNumbers", repository.useIncrementalRevisionNumbers);
|
| | | config.setBoolean(Constants.CONFIG_GITBLIT, null, "allowForks", repository.allowForks);
|
| | | config.setString(Constants.CONFIG_GITBLIT, null, "accessRestriction", repository.accessRestriction.name());
|
| | | config.setString(Constants.CONFIG_GITBLIT, null, "authorizationControl", repository.authorizationControl.name());
|
| | |
| | | }
|
| | |
|
| | | // schedule lucene engine
|
| | | boolean luceneIndexing = settings.getBoolean(Keys.web.allowLuceneIndexing, true);
|
| | | logger.info("Lucene indexing is " + (luceneIndexing ? "" : "not") + " activated");
|
| | | |
| | | if (luceneIndexing) {
|
| | | scheduledExecutor.scheduleAtFixedRate(luceneExecutor, 1, 2, TimeUnit.MINUTES);
|
| | | logger.info("Lucene executor is scheduled to process indexed branches every 2 minutes."); |
| | | }
|
| | | enableLuceneIndexing();
|
| | |
|
| | |
|
| | | // schedule gc engine
|
| | |
| | | }
|
| | | }
|
| | |
|
| | | protected void enableLuceneIndexing() {
|
| | | scheduledExecutor.scheduleAtFixedRate(luceneExecutor, 1, 2, TimeUnit.MINUTES);
|
| | | logger.info("Lucene executor is scheduled to process indexed branches every 2 minutes.");
|
| | | }
|
| | | |
| | | protected final Logger getLogger() {
|
| | | return logger;
|
| | | }
|
| | | |
| | | protected final ScheduledExecutorService getScheduledExecutor() {
|
| | | return scheduledExecutor;
|
| | | }
|
| | |
|
| | | protected final LuceneExecutor getLuceneExecutor() {
|
| | | return luceneExecutor;
|
| | | }
|
| | | |
| | | private void logTimezone(String type, TimeZone zone) {
|
| | | SimpleDateFormat df = new SimpleDateFormat("z Z");
|
| | | df.setTimeZone(zone);
|