Changeset: f5e7f3535f12 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/f5e7f3535f12
Branch: samloader
Log Message:
merge with default
diffs (truncated from 8884 to 300 lines):
diff --git a/.editorconfig b/.editorconfig
--- a/.editorconfig
+++ b/.editorconfig
@@ -24,7 +24,7 @@ indent_style = space
indent_size = 2
trim_trailing_whitespace = true
-[{clients/{mapilib,odbc},gdk}/**.{c,h}{,.in}]
+[{clients/{mapi{lib,client},odbc},common/{options,utils},gdk}/**.{c,h}{,.in}]
tab_width = 8
max_line_length = 72
diff --git a/ChangeLog b/ChangeLog
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog file for devel
# This file is updated with Maddlog
+* Thu Sep 17 2026 Sjoerd Mullender <[email protected]>
+- It is now possible to use --set usr1_outputfile=... to specify a file
+ where the output for the SIGUSR1 signal is to be written. The file
+ is opened (created if it doesn't exist, appended to if it does) every
+ time output is generated, making it easy to rotate the file.
+
* Mon Aug 3 2026 Sjoerd Mullender <[email protected]>
- The hash function used for all internal hash tables has been changed
to xxhash which is therefore now a build requirement.
diff --git a/clients/Tests/exports.stable.out b/clients/Tests/exports.stable.out
--- a/clients/Tests/exports.stable.out
+++ b/clients/Tests/exports.stable.out
@@ -306,7 +306,7 @@ ATOMIC_TYPE GDKlockcontentioncnt;
MT_Lock *volatile GDKlocklist;
ATOMIC_FLAG GDKlocklistlock;
ATOMIC_TYPE GDKlocksleepcnt;
-void GDKlockstatistics(int);
+void GDKlockstatistics(FILE *outf, int);
void *GDKmalloc(size_t size);
size_t GDKmem_cursize(void);
gdk_return GDKmergeidx(BAT *b, BAT **a, int n_ar);
@@ -316,7 +316,7 @@ gdk_return GDKmunmap(void *addr, int mod
int GDKnr_threads;
void GDKprepareExit(void);
void GDKprintinfo(void);
-void GDKprintinforegister(void (*func)(void));
+void GDKprintinforegister(void (*func)(FILE *));
void GDKqsort(void *restrict h, void *restrict t, const void *restrict base,
size_t n, int hs, int ts, int tpe, bool reverse, bool nilslast);
void *GDKrealloc(void *pold, size_t size);
gdk_return GDKrebuild_segment_tree(oid ncount, oid data_size, Heap *st, void
**segment_tree, oid **levels_offset, oid *nlevels);
@@ -559,7 +559,7 @@ gdk_return log_delta(logger *lg, BAT *ui
void log_destroy(logger *lg);
log_bid log_find_bat(logger *lg, log_id id);
gdk_return log_flush(logger *lg, ulng saved_id);
-void log_printinfo(logger *lg);
+void log_printinfo(FILE *outf, logger *lg);
int log_sequence(logger *lg, int seq, lng *id);
gdk_return log_tend(logger *lg);
gdk_return log_tflush(logger *lg, ulng log_file_id, ulng commit_ts);
@@ -842,6 +842,7 @@ const char alter_seqRef[];
const char alter_set_tableRef[];
const char alter_tableRef[];
const char alter_userRef[];
+const char andRef[];
const char appendBulkRef[];
const char appendRef[];
const char assertRef[];
@@ -916,7 +917,7 @@ const char dblRef[];
void debugFunction(stream *fd, MalBlkPtr mb, MalStkPtr stk, int flg, int
first, int size);
const char decompressRef[];
int defConstant(MalBlkPtr mb, int type, ValPtr cst);
-bool default_oahash_enabled;
+bool default_pipeline_mode;
const char defaultpipeRef[];
const char defineRef[];
void delArgument(InstrPtr p, int varid);
diff --git a/clients/mapiclient/ReadlineTools.c
b/clients/mapiclient/ReadlineTools.c
--- a/clients/mapiclient/ReadlineTools.c
+++ b/clients/mapiclient/ReadlineTools.c
@@ -413,7 +413,7 @@ invoke_editor(int cnt, int key) {
return 0;
-bailout:
+ bailout:
if (fp)
fclose(fp);
free(read_buff);
@@ -471,8 +471,8 @@ init_readline(Mapi mid, const char *lang
int len;
if (getenv("HOME") != NULL) {
len = snprintf(_history_file, sizeof(_history_file),
- "%s/.mapiclient_history_%s",
- getenv("HOME"), language);
+ "%s/.mapiclient_history_%s",
+ getenv("HOME"), language);
if (len == -1 || len >= FILENAME_MAX)
fprintf(stderr, "Warning: history filename path
is too large\n");
else
diff --git a/clients/mapiclient/dotmonetdb.c b/clients/mapiclient/dotmonetdb.c
--- a/clients/mapiclient/dotmonetdb.c
+++ b/clients/mapiclient/dotmonetdb.c
@@ -43,12 +43,19 @@ parse_dotmonetdb(DotMonetdb *dotfile)
int len = -1;
cfile = wbuf;
if (xdg != NULL)
- len = _snwprintf(wbuf, sizeof(wbuf),
L"%ls%lcmonetdb", xdg, DIR_SEP);
+ len = _snwprintf(wbuf, sizeof(wbuf),
+ L"%ls%lcmonetdb", xdg,
+ DIR_SEP);
else if (home != NULL)
- len = _snwprintf(wbuf, sizeof(wbuf),
L"%ls%lc.config%lcmonetdb", home, DIR_SEP, DIR_SEP);
- if (len == -1 || len >= FILENAME_MAX || (config =
_wfopen(wbuf, L"r")) == NULL) {
+ len = _snwprintf(wbuf, sizeof(wbuf),
+ L"%ls%lc.config%lcmonetdb",
+ home, DIR_SEP, DIR_SEP);
+ if (len == -1 || len >= FILENAME_MAX ||
+ (config = _wfopen(wbuf, L"r")) == NULL) {
if (home) {
- len = _snwprintf(wbuf, sizeof(wbuf),
L"%ls%lc.monetdb", home, DIR_SEP);
+ len = _snwprintf(wbuf, sizeof(wbuf),
+ L"%ls%lc.monetdb",
+ home, DIR_SEP);
if (len >= 0 && len < FILENAME_MAX)
config = _wfopen(wbuf, L"r");
}
@@ -56,7 +63,7 @@ parse_dotmonetdb(DotMonetdb *dotfile)
}
} else if (*cfile != 0 && (config = _wfopen(cfile, L"r")) == NULL) {
fprintf(stderr, "failed to open file '%ls': %s\n",
- cfile, strerror(errno));
+ cfile, strerror(errno));
}
#else
char *cfile;
@@ -71,12 +78,18 @@ parse_dotmonetdb(DotMonetdb *dotfile)
int len = -1;
cfile = buf;
if (xdg != NULL)
- len = snprintf(buf, sizeof(buf), "%s%cmonetdb",
xdg, DIR_SEP);
+ len = snprintf(buf, sizeof(buf), "%s%cmonetdb",
+ xdg, DIR_SEP);
else if (home != NULL)
- len = snprintf(buf, sizeof(buf),
"%s%c.config%cmonetdb", home, DIR_SEP, DIR_SEP);
- if (len == -1 || len >= FILENAME_MAX || (config =
fopen(buf, "r")) == NULL) {
+ len = snprintf(buf, sizeof(buf),
+ "%s%c.config%cmonetdb",
+ home, DIR_SEP, DIR_SEP);
+ if (len == -1 || len >= FILENAME_MAX ||
+ (config = fopen(buf, "r")) == NULL) {
if (home) {
- len = snprintf(buf, sizeof(buf),
"%s%c.monetdb", home, DIR_SEP);
+ len = snprintf(buf, sizeof(buf),
+ "%s%c.monetdb",
+ home, DIR_SEP);
if (len >= 0 && len < FILENAME_MAX)
config = fopen(buf, "r");
}
@@ -84,7 +97,7 @@ parse_dotmonetdb(DotMonetdb *dotfile)
}
} else if (*cfile != 0 && (config = fopen(cfile, "r")) == NULL) {
fprintf(stderr, "failed to open file '%s': %s\n",
- cfile, strerror(errno));
+ cfile, strerror(errno));
}
#endif
@@ -102,7 +115,7 @@ parse_dotmonetdb(DotMonetdb *dotfile)
continue;
if ((q = strchr(buf, '=')) == NULL) {
fprintf(stderr, CF ":%d: syntax error: %s\n",
- cfile, line, buf);
+ cfile, line, buf);
continue;
}
*q++ = '\0';
@@ -125,8 +138,9 @@ parse_dotmonetdb(DotMonetdb *dotfile)
/* make sure we don't set garbage */
if (strcmp(q, "sql") != 0 &&
strcmp(q, "mal") != 0) {
- fprintf(stderr, CF ":%d: unsupported
language: %s\n",
- cfile, line, q);
+ fprintf(stderr, CF ":%d:"
+ " unsupported language: %s\n",
+ cfile, line, q);
}
dotfile->language = strdup(q);
q = NULL;
@@ -136,7 +150,7 @@ parse_dotmonetdb(DotMonetdb *dotfile)
dotfile->save_history = true;
q = NULL;
} else if (strcmp(q, "false") == 0 ||
- strcmp(q, "off") == 0) {
+ strcmp(q, "off") == 0) {
dotfile->save_history = false;
q = NULL;
}
@@ -151,8 +165,9 @@ parse_dotmonetdb(DotMonetdb *dotfile)
q = NULL;
}
if (q != NULL)
- fprintf(stderr, CF ":%d: unknown property:
%s\n",
- cfile, line, buf);
+ fprintf(stderr,
+ CF ":%d: unknown property: %s\n",
+ cfile, line, buf);
}
fclose(config);
}
diff --git a/clients/mapiclient/dump.c b/clients/mapiclient/dump.c
--- a/clients/mapiclient/dump.c
+++ b/clients/mapiclient/dump.c
@@ -11,7 +11,6 @@
#include "monetdb_config.h"
#include "mapi.h"
#include "stream.h"
-#include "mstring.h"
#include <unistd.h>
#include <string.h>
#include <ctype.h>
@@ -92,11 +91,12 @@ squoted_print(stream *f, const char *s,
return -1;
while (*s) {
size_t n = noescape ? strcspn(s, "'\"") :
- strcspn(s, "\\'\"\177"
- "\001\002\003\004\005\006\007"
- "\010\011\012\013\014\015\016\017"
- "\020\021\022\023\024\025\026\027"
- "\030\031\032\033\034\035\036\037");
+ strcspn(s,
+ "\\'\"\177"
+ "\001\002\003\004\005\006\007"
+ "\010\011\012\013\014\015\016\017"
+ "\020\021\022\023\024\025\026\027"
+ "\030\031\032\033\034\035\036\037");
if (n > 0 && mnstr_write(f, s, 1, n) < 0)
return -1;
s += n;
@@ -240,7 +240,7 @@ get_schema(Mapi mid)
mapi_close_handle(hdl);
return sname;
-bailout:
+ bailout:
if (hdl) {
if (mapi_result_error(hdl))
mapi_explain_result(hdl, stderr);
@@ -284,7 +284,7 @@ has_hugeint(Mapi mid)
answer = (int) ret;
return answer;
-bailout:
+ bailout:
if (hdl) {
if (mapi_result_error(hdl))
mapi_explain_result(hdl, stderr);
@@ -322,7 +322,7 @@ has_schema_max_memory(Mapi mid)
answer = ret;
return ret;
-bailout:
+ bailout:
if (hdl) {
if (mapi_result_error(hdl))
mapi_explain_result(hdl, stderr);
@@ -362,7 +362,7 @@ has_remote_user_info_table(Mapi mid)
answer = ret;
return ret;
-bailout:
+ bailout:
if (hdl) {
if (mapi_result_error(hdl))
mapi_explain_result(hdl, stderr);
@@ -385,9 +385,9 @@ has_check_constraint(Mapi mid)
return answer;
if ((hdl = mapi_query(mid,
- "select id from sys.functions"
- " where schema_id = 2000"
- " and name =
'check_constraint'")) == NULL ||
+ "select id from sys.functions"
+ " where schema_id = 2000"
+ " and name = 'check_constraint'")) == NULL ||
mapi_error(mid))
goto bailout;
ret = mapi_get_row_count(hdl) == 1;
@@ -401,7 +401,7 @@ has_check_constraint(Mapi mid)
answer = ret;
return ret;
-bailout:
+ bailout:
if (hdl) {
if (mapi_result_error(hdl))
mapi_explain_result(hdl, stderr);
@@ -437,33 +437,33 @@ dump_foreign_keys(Mapi mid, const char *
goto bailout;
}
snprintf(query, maxquerylen,
- "SELECT ps.name, " /* 0 */
_______________________________________________
checkin-list mailing list -- [email protected]
To unsubscribe send an email to [email protected]