aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/org/traccar/config
diff options
context:
space:
mode:
authorAnton Tananaev <atananaev@lyft.com>2020-12-30 10:36:50 -0800
committerAnton Tananaev <atananaev@lyft.com>2020-12-30 10:36:50 -0800
commit6101300ab45882e02e4a0b90d30070cb904378eb (patch)
tree577cb6467644eb138b110f9cb3cb0656ab1936b1 /src/main/java/org/traccar/config
parent31c4daf083e9f4b799d73d4a1ccb9158505aea70 (diff)
downloadtraccar-server-6101300ab45882e02e4a0b90d30070cb904378eb.tar.gz
traccar-server-6101300ab45882e02e4a0b90d30070cb904378eb.tar.bz2
traccar-server-6101300ab45882e02e4a0b90d30070cb904378eb.zip
Migrate more config keys
Diffstat (limited to 'src/main/java/org/traccar/config')
-rw-r--r--src/main/java/org/traccar/config/Keys.java38
1 files changed, 38 insertions, 0 deletions
diff --git a/src/main/java/org/traccar/config/Keys.java b/src/main/java/org/traccar/config/Keys.java
index 598cac66f..6b779baea 100644
--- a/src/main/java/org/traccar/config/Keys.java
+++ b/src/main/java/org/traccar/config/Keys.java
@@ -131,6 +131,13 @@ public final class Keys {
Collections.singletonList(KeyType.GLOBAL));
/**
+ * Protocol configuration. Required for some devices for decoding incoming data.
+ */
+ public static final ConfigSuffix<String> PROTOCOL_CONFIG = new ConfigSuffix<>(
+ ".config",
+ Collections.singletonList(KeyType.GLOBAL));
+
+ /**
* Alarm mapping for Atrack protocol.
*/
public static final ConfigSuffix<String> PROTOCOL_ALARM_MAP = new ConfigSuffix<>(
@@ -454,6 +461,22 @@ public final class Keys {
Collections.singletonList(KeyType.GLOBAL));
/**
+ * List of protocol names to ignore offline status. Can be useful to not trigger status change when devices are
+ * configured to disconnect after reporting a batch of data.
+ */
+ public static final ConfigKey<String> STATUS_IGNORE_OFFLINE = new ConfigKey<>(
+ "status.ignoreOffline",
+ Collections.singletonList(KeyType.GLOBAL));
+
+ /**
+ * Path to the media folder. Server stores audio, video and photo files in that folder. Sub-folders will be
+ * automatically created for each device by unique id.
+ */
+ public static final ConfigKey<String> MEDIA_PATH = new ConfigKey<>(
+ "media.path",
+ Collections.singletonList(KeyType.GLOBAL));
+
+ /**
* Optional parameter to specify network interface for web interface to bind to. By default server will bind to all
* available interfaces.
*/
@@ -500,6 +523,21 @@ public final class Keys {
Collections.singletonList(KeyType.GLOBAL));
/**
+ * Cross-origin resource sharing origin header value.
+ */
+ public static final ConfigKey<String> WEB_ORIGIN = new ConfigKey<>(
+ "web.origin",
+ Collections.singletonList(KeyType.GLOBAL));
+
+ /**
+ * Cache control header value. By default resources are cached for one hour.
+ */
+ public static final ConfigKey<String> WEB_CACHE_CONTROL = new ConfigKey<>(
+ "web.cacheControl",
+ Collections.singletonList(KeyType.GLOBAL),
+ "max-age=3600,public");
+
+ /**
* URL to forward positions. Data is passed through URL parameters. For example, {uniqueId} for device identifier,
* {latitude} and {longitude} for coordinates.
*/