comparison src/main/java/org/monetdb/mcl/net/Parameter.java @ 903:778959b2e0a4

Send ClientInfo on startup Configurable through the client_info=bool, client_application=NAME, client_remark=MESSAGE properties.
author Joeri van Ruth <joeri.van.ruth@monetdbsolutions.com>
date Fri, 14 Jun 2024 15:57:49 +0200 (10 months ago)
parents dc33533e6468
children 2ec67179aa32
comparison
equal deleted inserted replaced
902:65d42db0c831 903:778959b2e0a4
43 DEBUG("debug", ParameterType.Bool, false, "enable tracing of socket communication for debugging", false), 43 DEBUG("debug", ParameterType.Bool, false, "enable tracing of socket communication for debugging", false),
44 LOGFILE("logfile", ParameterType.Str, "", "when debug is enabled its output will be written to this logfile", false), 44 LOGFILE("logfile", ParameterType.Str, "", "when debug is enabled its output will be written to this logfile", false),
45 SO_TIMEOUT("so_timeout", ParameterType.Int, 0, "abort if network I/O does not complete in this many milliseconds, 0 means no timeout", false), 45 SO_TIMEOUT("so_timeout", ParameterType.Int, 0, "abort if network I/O does not complete in this many milliseconds, 0 means no timeout", false),
46 CLOB_AS_VARCHAR("treat_clob_as_varchar", ParameterType.Bool, true, "return CLOB/TEXT data as type VARCHAR instead of type CLOB", false), 46 CLOB_AS_VARCHAR("treat_clob_as_varchar", ParameterType.Bool, true, "return CLOB/TEXT data as type VARCHAR instead of type CLOB", false),
47 BLOB_AS_BINARY("treat_blob_as_binary", ParameterType.Bool, true, "return BLOB data as type BINARY instead of type BLOB", false), 47 BLOB_AS_BINARY("treat_blob_as_binary", ParameterType.Bool, true, "return BLOB data as type BINARY instead of type BLOB", false),
48
49 CLIENT_INFO("client_info", ParameterType.Bool, true, "whether to send ClientInfo when connecting", false),
50 CLIENT_APPLICATION("client_application", ParameterType.Str, "", "application name to send in ClientInfo", false),
51 CLIENT_REMARK("client_remark", ParameterType.Str, "", "application name to send in ClientInfo", false),
48 ; 52 ;
49 53
50 public final String name; 54 public final String name;
51 public final ParameterType type; 55 public final ParameterType type;
52 private final Object defaultValue; 56 private final Object defaultValue;
115 return SO_TIMEOUT; 119 return SO_TIMEOUT;
116 case "treat_clob_as_varchar": 120 case "treat_clob_as_varchar":
117 return CLOB_AS_VARCHAR; 121 return CLOB_AS_VARCHAR;
118 case "treat_blob_as_binary": 122 case "treat_blob_as_binary":
119 return BLOB_AS_BINARY; 123 return BLOB_AS_BINARY;
124 case "client_info":
125 return CLIENT_INFO;
126 case "client_application":
127 return CLIENT_APPLICATION;
128 case "client_remark":
129 return CLIENT_REMARK;
120 default: 130 default:
121 return null; 131 return null;
122 } 132 }
123 } 133 }
124 134