Provide a common 'shellserver' capability cloned off of 'consoleserver'.
This will enable the concept of per-user shells with option for multiple
shells per. Each user will have their own set of shell sessions rather
than shared across users. Can revisit in future if sharing between
users is desired.
Create a module that does ssh and treats it like
a console. The plan is to have a cliserver.py to
behave in a manner resembling consoleserver.py, but
with option to have multiple distinct sessions per
target.
Expansion of a noderange containing a dynamic group
would erroneously make the dynamic members get promoted
to 'permament' members. Fix this by isolating the
change so that the underlying group config is not changed
just by adding in dynamic nodes.
If only one node was in given noderange, then
the httpapi response would not look similar in
structure to a multi-node response. Force even
single items in this special case to be an array
to allow easier javascript client code.
If confluent gets stuck, provide a debug facility
to sample where it is stuck. Sending confluent
SIGUSR1 will now cause /var/log/confluent/hangtraces
to get written to.
The console API had a 'wait_for_data' which will never be used.
Also change __init__() so that it can be called via super() to
allow working around IDE complaints.
While the client can handle it now, have the server
avoid needless processing of '' data from a console
provider. Address it at the deepest level (the
tlvdata implementation) and a place higher up the stack
to avoid hits to log and such.
When attribute notification is requested, node deletion was not
sent to the watchers. Address the limitation by notifying on all
attributes for a deleted node.
When a rollover event was detected, the offset
of the rollover event itself was being read
from the rolled file erroneously. Skip to
next loop iteration so that the metadata about
the rollover event is properly ignored in building
the text data buffer.
The log format for other pieces of data is JSON.
Change the rollover event to be consistent. Also
do not record the previous name of the log file,
as that isn't used, and the current filename is
likely to change when it too gets rolled over
so there's no practical use of knowing the
no longer valid name for the transaction.
Under windows, we can't use flock. However we can
get locking using msvcrt using different, but related
semantics. Imitate whole file locking by just locking
first byte. We have to make sure we seek() to the same
place when locking and unlocking, as Windows requires
the offset to be same for both operations.
Add TimedAndSizeRotatingFileHandler which mixes together
the RotatingFileHandler and TimedRotatingFileHandler from
python logging module to process the log data.
Add logrollover event to track the renamed information, so
that console session can read the log data from current log
file and last renamed file.
Global configuration is used by the log handler. The format
of the log section in '/etc/confluent/service.cfg' is like:
[log]
when = m
backup_count = 3
max_bytes = 8192
utc = False