diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2009-11-26 17:35:54 +0100 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2009-11-26 17:35:54 +0100 |
commit | f77dc853ed217e824d86bf8feb0c6e75cc0f230e (patch) | |
tree | 95b6b6dc8afe4ddcfb547675e67ee9fdcd5bb00c | |
parent | 809c7e3cdcba3bef8d29702f37c3c8b580c3d1bd (diff) | |
parent | e5fe270bdbcfbdd22cf9dcc71e7a83b6cc88a979 (diff) | |
download | rsyslog-f77dc853ed217e824d86bf8feb0c6e75cc0f230e.tar.gz rsyslog-f77dc853ed217e824d86bf8feb0c6e75cc0f230e.tar.xz rsyslog-f77dc853ed217e824d86bf8feb0c6e75cc0f230e.zip |
Merge branch 'beta' into master
Conflicts:
ChangeLog
action.c
configure.ac
doc/manual.html
doc/rsyslog_conf_modules.html
tests/sndrcv_drvr.sh
-rw-r--r-- | ChangeLog | 8 | ||||
-rw-r--r-- | action.c | 17 | ||||
-rw-r--r-- | runtime/nsd_gtls.c | 5 | ||||
-rwxr-xr-x | tests/sndrcv_drvr.sh | 2 |
4 files changed, 24 insertions, 8 deletions
@@ -8,6 +8,8 @@ Version 5.5.1 [DEVEL] (rgerhards), 2009-11-?? proves well in practice AND there is demand. - bugfix: enabling GSSServer crashes rsyslog startup Thanks to Tomas Kubina for the patch [imgssapi] +- bugfix (kind of): check if TCP connection is still alive if using TLS + Thanks to Jonathan Bond-Caron for the patch. --------------------------------------------------------------------------- Version 5.5.0 [DEVEL] (rgerhards), 2009-11-18 - moved DNS resolution code out of imudp and into the backend processing @@ -24,8 +26,12 @@ Version 5.5.0 [DEVEL] (rgerhards), 2009-11-18 Version 5.3.6 [BETA] (rgerhards), 2009-11-?? - bugfix: omfile output was only written when buffer was full, not at end of transaction +- bugfix: commit transaction was not properly conveyed to message layer, + potentially resulting in non-message destruction and thus hangs - bugfix: enabling GSSServer crashes rsyslog startup Thanks to Tomas Kubina for the patch [imgssapi] +- bugfix (kind of): check if TCP connection is still alive if using TLS + Thanks to Jonathan Bond-Caron for the patch. --------------------------------------------------------------------------- Version 5.3.5 [BETA] (rgerhards), 2009-11-13 - some light performance enhancement by replacing time() call with much @@ -319,6 +325,8 @@ Version 4.5.7 [v4-beta] (rgerhards), 2009-11-18 be generated only after the process has started, but not right from the beginning. This is assumed to be useful for hard-to-find bugs. Also improved the doc on the debug system. +- bugfix (kind of): check if TCP connection is still alive if using TLS + Thanks to Jonathan Bond-Caron for the patch. - bugfix [imported from 4.4.3]: $ActionExecOnlyOnceEveryInterval did not work. --------------------------------------------------------------------------- @@ -760,8 +760,9 @@ finalize_it: * rgerhards, 2008-01-28 */ static rsRetVal -finishBatch(action_t *pThis) +finishBatch(action_t *pThis, batch_t *pBatch) { + int i; DEFiRet; ASSERT(pThis != NULL); @@ -769,14 +770,17 @@ finishBatch(action_t *pThis) if(pThis->eState == ACT_STATE_RDY) FINALIZE; /* nothing to do */ -DBGPRINTF("finishBatch was called\n"); CHKiRet(actionPrepare(pThis)); if(pThis->eState == ACT_STATE_ITX) { iRet = pThis->pMod->mod.om.endTransaction(pThis->pModData); -DBGPRINTF("finishBatch returned %d for endTransaction\n", iRet); +dbgprintf("XXX: finishBatch, result of endTranscation %d\n", iRet); switch(iRet) { case RS_RET_OK: actionCommitted(pThis); + /* flag messages as committed */ + for(i = 0 ; i < pBatch->nElem ; ++i) { + pBatch->pElem[i].state = BATCH_STATE_COMM; + } break; case RS_RET_SUSPENDED: actionRetry(pThis); @@ -844,11 +848,12 @@ tryDoAction(action_t *pAction, batch_t *pBatch, int *pnElem, int *pbShutdownImme pBatch->pElem[iCommittedUpTo++].state = BATCH_STATE_COMM; } pBatch->pElem[i].state = BATCH_STATE_SUB; - } else if(localRet == RS_RET_PREVIOUS_COMMITTED) { + } else if(localRet == RS_RET_DEFER_COMMIT) { pBatch->pElem[i].state = BATCH_STATE_SUB; } else if(localRet == RS_RET_DISCARDMSG) { pBatch->pElem[i].state = BATCH_STATE_DISC; } else { + dbgprintf("tryDoAction: unexpected error code %d, finalizing\n", localRet); iRet = localRet; FINALIZE; } @@ -895,7 +900,7 @@ dbgprintf("submitBatch: state of tryDoAction %d\n", localRet); /* try commit transaction, once done, we can simply do so as if * that return state was returned from tryDoAction(). */ - localRet = finishBatch(pAction); + localRet = finishBatch(pAction, pBatch); // TODO: careful, do we need the elem counter? } if( localRet == RS_RET_OK @@ -945,7 +950,7 @@ processAction(action_t *pAction, batch_t *pBatch, int *pbShutdownImmediate) assert(pBatch != NULL); pBatch->iDoneUpTo = 0; CHKiRet(submitBatch(pAction, pBatch, pBatch->nElem, pbShutdownImmediate)); - iRet = finishBatch(pAction); + iRet = finishBatch(pAction, pBatch); finalize_it: RETiRet; diff --git a/runtime/nsd_gtls.c b/runtime/nsd_gtls.c index 74c142f2..0ee70e56 100644 --- a/runtime/nsd_gtls.c +++ b/runtime/nsd_gtls.c @@ -1327,7 +1327,10 @@ finalize_it: static void CheckConnection(nsd_t __attribute__((unused)) *pNsd) { - /* dummy, do nothing */ + nsd_gtls_t *pThis = (nsd_gtls_t*) pNsd; + ISOBJ_TYPE_assert(pThis, nsd_gtls); + + nsd_ptcp.CheckConnection(pThis->pTcp); } diff --git a/tests/sndrcv_drvr.sh b/tests/sndrcv_drvr.sh index e154b70a..63afd6b5 100755 --- a/tests/sndrcv_drvr.sh +++ b/tests/sndrcv_drvr.sh @@ -35,7 +35,7 @@ source $srcdir/diag.sh wait-startup 2 # now inject the messages into instance 2. It will connect to instance 1, # and that instance will record the data. source $srcdir/diag.sh tcpflood 127.0.0.1 13514 1 $2 1 -sleep 2 # ensure all messages reach the input module +sleep 2 # make sure all data is received in input buffers # shut down sender when everything is sent, receiver continues to run concurrently # may be needed by TLS (once we do it): sleep 60 source $srcdir/diag.sh shutdown-when-empty 2 |