Reduce default max length to 1024, make it configurable.