configs for dev and prod

This commit is contained in:
Athou
2014-08-09 19:35:05 +02:00
parent afbbd07a13
commit c5e9e60ab0
5 changed files with 69 additions and 17 deletions

3
.gitignore vendored
View File

@@ -1,6 +1,9 @@
# build directory
target
# log files
log
# node
node
node_modules

51
config.dev.yml Normal file
View File

@@ -0,0 +1,51 @@
app:
publicUrl: http://localhost:8082/
allowRegistrations: true
googleAnalyticsTrackingCode:
googleClientId:
googleClientSecret:
backgroundThreads: 3
databaseUpdateThreads: 1
smtpHost:
smtpPort:
smtpTls: false
smtpUserName:
smtpPassword:
heavyLoad: false
pubsubhubbub: false
imageProxyEnabled: false
queryTimeout: 0
keepStatusDays: 0
refreshIntervalMinutes: 5
cache: noop
announcement:
database:
driverClass: org.h2.Driver
user: sa
password: sa
url: jdbc:h2:./target/example
properties:
charSet: UTF-8
# hibernate.dialect: org.hibernate.dialect.PostgreSQLDialect
maxWaitForConnection: 1s
validationQuery: "/* MyApplication Health Check */ SELECT 1"
minSize: 1
maxSize: 8
checkConnectionWhileIdle: true
server:
applicationConnectors:
- type: http
port: 8083
adminConnectors:
- type: http
port: 8084
logging:
level: WARN
loggers:
com.commafeed: DEBUG
liquibase: INFO
org.hibernate.SQL: ALL
appenders:
- type: console

View File

@@ -15,13 +15,11 @@ app:
pubsubhubbub: false
imageProxyEnabled: false
queryTimeout: 0
crawlingPaused: false
keepStatusDays: 0
refreshIntervalMinutes: 5
cache: noop
announcement:
authenticationCachePolicy: maximumSize=10000, expireAfterAccess=10m
database:
driverClass: org.h2.Driver
user: sa
@@ -39,15 +37,20 @@ database:
server:
applicationConnectors:
- type: http
port: 8083
port: 8082
adminConnectors:
- type: http
port: 8084
logging:
level: WARN
loggers:
com.commafeed: DEBUG
liquibase: INFO
org.hibernate.SQL: ALL
com.commafeed: INFO
appenders:
- type: console
- type: console
- type: file
currentLogFilename: log/commafeed.log
threshold: ALL
archive: true
archivedLogFilenamePattern: log/commafeed-%d.log
archivedFileCount: 5
timeZone: UTC

View File

@@ -87,9 +87,6 @@ public class CommaFeedConfiguration extends Configuration {
@JsonProperty
private int queryTimeout;
@JsonProperty
private boolean crawlingPaused;
@JsonProperty
private int keepStatusDays;

View File

@@ -96,13 +96,11 @@ public class FeedQueues {
}
// add feeds that are up to refresh from the database
if (!config.getApplicationSettings().isCrawlingPaused()) {
int count = batchSize - contexts.size();
if (count > 0) {
List<Feed> feeds = feedDAO.findNextUpdatable(count, getLastLoginThreshold());
for (Feed feed : feeds) {
contexts.add(new FeedRefreshContext(feed, false));
}
int count = batchSize - contexts.size();
if (count > 0) {
List<Feed> feeds = feedDAO.findNextUpdatable(count, getLastLoginThreshold());
for (Feed feed : feeds) {
contexts.add(new FeedRefreshContext(feed, false));
}
}