Switch JSONEncoded from VARCHAR to TEXT
The JSON fields are really "dumb stuff in here" fields. They are not intended to get indexed or anything. And they can get large. For example the exif_all field in one of my simple tests is nearly 7 kB large. Although VARCHAR might work, TEXT feels just better as the storage type.
This commit is contained in:
parent
98853c63fd
commit
1e3a0e0ca0
@ -15,7 +15,7 @@
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
|
||||
from sqlalchemy.types import TypeDecorator, Unicode, VARCHAR
|
||||
from sqlalchemy.types import TypeDecorator, Unicode, TEXT
|
||||
import json
|
||||
|
||||
|
||||
@ -50,7 +50,7 @@ class PathTupleWithSlashes(TypeDecorator):
|
||||
class JSONEncoded(TypeDecorator):
|
||||
"Represents an immutable structure as a json-encoded string."
|
||||
|
||||
impl = VARCHAR
|
||||
impl = TEXT
|
||||
|
||||
def process_bind_param(self, value, dialect):
|
||||
if value is not None:
|
||||
|
Loading…
x
Reference in New Issue
Block a user