- fprintf( stderr, "[DBUG] endpoint: %s open=%d\n", ep->name, ep->open );
+ fprintf( stderr, "[DBUG] RMR sends: target=%s open=%d\n", ep->name, ep->open );
+}
+
+/*
+ Dump counts for an endpoint in the RT. The vid parm is assumed to point to
+ the 'source' information and is added to each message.
+*/
+static void ep_counts( void* st, void* entry, char const* name, void* thing, void* vid ) {
+ endpoint_t* ep;
+ char* id;
+
+ if( (ep = (endpoint_t *) thing) == NULL ) {
+ return;
+ }
+
+ if( (id = (char *) vid) == NULL ) {
+ id = "missing";
+ }
+
+ fprintf( stderr, "[INFO] RMR sends: ts=%lld src=%s target=%s open=%d succ=%lld fail=%lld (hard=%lld soft=%lld)\n",
+ (long long) time( NULL ),
+ id,
+ ep->name,
+ ep->open,
+ ep->scounts[EPSC_GOOD],
+ ep->scounts[EPSC_FAIL] + ep->scounts[EPSC_TRANS],
+ ep->scounts[EPSC_FAIL],
+ ep->scounts[EPSC_TRANS] );