aboutsummaryrefslogtreecommitdiff
path: root/weed/command
diff options
context:
space:
mode:
authorChris Lu <chris.lu@gmail.com>2021-01-19 17:21:50 -0800
committerChris Lu <chris.lu@gmail.com>2021-01-19 17:21:50 -0800
commit52a8f1470ef92b9d0075c3dccc76a4170ab30c07 (patch)
tree3bae93297aa57eb9b8c1290927f2582c21b4817d /weed/command
parent93b3adba9864dd278a778ccfe2165bcadb010574 (diff)
downloadseaweedfs-52a8f1470ef92b9d0075c3dccc76a4170ab30c07.tar.xz
seaweedfs-52a8f1470ef92b9d0075c3dccc76a4170ab30c07.zip
filer store: add mysql2
Diffstat (limited to 'weed/command')
-rw-r--r--weed/command/scaffold.go21
1 files changed, 21 insertions, 0 deletions
diff --git a/weed/command/scaffold.go b/weed/command/scaffold.go
index 949f22588..b44bc41c1 100644
--- a/weed/command/scaffold.go
+++ b/weed/command/scaffold.go
@@ -121,6 +121,27 @@ connection_max_open = 100
connection_max_lifetime_seconds = 0
interpolateParams = false
+[mysql2] # or memsql, tidb
+enabled = false
+createTable = """
+ CREATE TABLE IF NOT EXISTS %s (
+ dirhash BIGINT,
+ name VARCHAR(1000),
+ directory TEXT,
+ meta LONGBLOB,
+ PRIMARY KEY (dirhash, name)
+ ) DEFAULT CHARSET=utf8;
+"""
+hostname = "localhost"
+port = 3306
+username = "root"
+password = ""
+database = "" # create or use an existing database
+connection_max_idle = 2
+connection_max_open = 100
+connection_max_lifetime_seconds = 0
+interpolateParams = false
+
[postgres] # or cockroachdb, YugabyteDB
# CREATE TABLE IF NOT EXISTS filemeta (
# dirhash BIGINT,