From 2a52e70a41cd1a196a43fe196960d9ed9d25f43d Mon Sep 17 00:00:00 2001 From: Chris Lu Date: Mon, 1 Apr 2019 12:37:54 -0700 Subject: [PATCH] weed filer: increase default mysql/postgres dir or name length to 65535 --- weed/command/scaffold.go | 10 +++++----- weed/filer2/postgres/README.txt | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/weed/command/scaffold.go b/weed/command/scaffold.go index d72bd6f2f..b21641f6b 100644 --- a/weed/command/scaffold.go +++ b/weed/command/scaffold.go @@ -72,9 +72,9 @@ dir = "." # directory to store level db files [mysql] # CREATE TABLE IF NOT EXISTS filemeta ( -# dirhash BIGINT COMMENT 'first 64 bits of MD5 hash value of directory field', -# name VARCHAR(1000) COMMENT 'directory or file name', -# directory VARCHAR(4096) COMMENT 'full path to parent directory', +# dirhash BIGINT COMMENT 'first 64 bits of MD5 hash value of directory field', +# name VARCHAR(65535) COMMENT 'directory or file name', +# directory VARCHAR(65535) COMMENT 'full path to parent directory', # meta BLOB, # PRIMARY KEY (dirhash, name) # ) DEFAULT CHARSET=utf8; @@ -90,8 +90,8 @@ connection_max_open = 100 [postgres] # CREATE TABLE IF NOT EXISTS filemeta ( # dirhash BIGINT, -# name VARCHAR(1000), -# directory VARCHAR(4096), +# name VARCHAR(65535), +# directory VARCHAR(65535), # meta bytea, # PRIMARY KEY (dirhash, name) # ); diff --git a/weed/filer2/postgres/README.txt b/weed/filer2/postgres/README.txt index ef2ef683b..cb0c99c63 100644 --- a/weed/filer2/postgres/README.txt +++ b/weed/filer2/postgres/README.txt @@ -9,8 +9,8 @@ $PGHOME/bin/psql --username=postgres --password seaweedfs CREATE TABLE IF NOT EXISTS filemeta ( dirhash BIGINT, - name VARCHAR(1000), - directory VARCHAR(4096), + name VARCHAR(65535), + directory VARCHAR(65535), meta bytea, PRIMARY KEY (dirhash, name) );