Changeset: c2ffe3136c5d for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=c2ffe3136c5d
Modified Files:
        sql/backends/monet5/datacell/receptor.c
        sql/backends/monet5/datacell/receptor.h
Branch: default
Log Message:

receptor: update global event stats from (worker) copies


diffs (33 lines):

diff --git a/sql/backends/monet5/datacell/receptor.c 
b/sql/backends/monet5/datacell/receptor.c
--- a/sql/backends/monet5/datacell/receptor.c
+++ b/sql/backends/monet5/datacell/receptor.c
@@ -480,6 +480,10 @@ parse:
                                }
                                cnt++;
                        }
+                       /* update global struct */
+                       rc->parent->cycles = rc->cycles;
+                       rc->parent->received = rc->received;
+                       rc->parent->pending = rc->pending;
                        BSKTunlock(&rc->lck, &rc->name);
                        if (rc->table.error) {
                                mnstr_printf(GDKerr, "%s", rc->table.error);
@@ -662,6 +666,7 @@ RCstartThread(Receptor rc)
 #endif
                        trc = GDKmalloc(sizeof(RCrecord));
                        memcpy(trc, rc, sizeof(RCrecord));
+                       trc->parent = rc;
                        trc->error = socket_server_listen(rc->sockfd, 
&rc->newsockfd);
                        if (trc->error) {
                                mnstr_printf(RCout, "Receptor listen fails: 
%s\n", rc->error);
diff --git a/sql/backends/monet5/datacell/receptor.h 
b/sql/backends/monet5/datacell/receptor.h
--- a/sql/backends/monet5/datacell/receptor.h
+++ b/sql/backends/monet5/datacell/receptor.h
@@ -57,6 +57,7 @@ typedef struct RECEPTOR {
        int received;
        Tablet table;   /* tuple input structure */
        struct RECEPTOR *nxt, *prv;
+       struct RECEPTOR *parent;   /* used for multiple streams connected to 
the same receptor */
 } RCrecord, *Receptor;
 
 #ifdef WIN32
_______________________________________________
Checkin-list mailing list
Checkin-list@monetdb.org
http://mail.monetdb.org/mailman/listinfo/checkin-list

Reply via email to