| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
lmishell no longer automatically refresh the instance after calling some
method on it. refresh() must be called manually.
Also fix path to the failing.service file when running the test script
directly.
|
|
|
|
|
|
| |
The test for creating socket and http connection get removed, because:
* socket connection might not work on the buildbot
* http(s) connection is tested in the service provider tests anyway
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PG_ComputerSystem has different method how to get hostname than our
providers. In order to create the associations to this class we need to
enumerate it. The downside is that all providers must supply CMPIContext
to the lmi_init function.
New function lmi_get_computer_system returns CMPIObjectPath to the
configured CIM_ComputerSystem subclass instance. This object should be
used in all references with ComputerSystem.
Function lmi_get_system_name has been altered to return same value as
ComputerSystem "Name" property.
|
|
|
|
|
|
|
|
|
|
|
| |
Things are bit harsh in the indication manager when it comes to cancellation.
At certain situation we force-cancel the polling thread, having no chance
for cleanup. The mutex we use to protect memory shared between threads may
be left in undefined state.
The pthread_mutex_unlock() call in im_stop_ind() may be called on already
unlocked mutex which, in default setup, causes a segfault. Setting a mutex
attribute PTHREAD_MUTEX_ERRORCHECK will prevent this, returning proper error.
|
|
|
|
|
|
|
| |
A bit of cleanup, adding "Implemented(true)" qualifiers where applicable,
adding forgotten properties used by the provider and also added and modified
description for the methods we implement. Note that only modified descriptions
have been added, the unchanged ones get inherited just fine.
|
| |
|
|
|
|
|
|
| |
Let's write openlmi version to the main __init__ module of each python
egg at build time. This version information is easily accessible from
setup scripts.
|
|
|
|
| |
Done for: Account, Journald and LogicalFile
|
|
|
|
|
|
|
|
| |
import it in your tests with:
from lmi.test.base import LmiTestCase
For imports to work, run:
export PYTHONPATH=${PROVIDERS_GIT_ROOT}/src/python
before nosetests or before running them individually.
|
|
|
|
|
| |
Added missing 'lmi' package to packages. This fixes installation to
user directory.
|
| |
|
|
|
|
|
|
|
| |
Path to the qualifiers and jobs mofs was hardcoded, now it's a variable.
There is now also a variable for openlmi-mof-register script - this
fixes (un)register-Provider targets.
|
|
|
|
| |
The test is started with undeterministic current working directory.
|
|
|
|
| |
The test must reload service status from CIMOM.
|
|
|
|
| |
It breaks Pegasus.
|
|
|
|
| |
failing.service was removed twice without checking.
|
|
|
|
|
|
|
|
| |
restart.
The test expected that the CIMOM restarts atomically, which is not the case
- there are few seconds of no CIM service and the test must wait until
the CIMOM becomes online.
|
|
|
|
|
| |
We expect that test machines have correct https setup and certificates
are distributed to the right places.
|
| |
|
|
|
|
| |
There is too much noise in TRACE_VERBOSE and exception stack trace is
more important than e.g. entering/leaving messages.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
- Everything is in openlmi-providers/doc/admin directory.
- 'make doc' automatically builds documentation of all
enabled providers.
- Documentation shares one 'conf.py' for sphinx.
- All documentation uses the same directory structure.
There is only one CMakefile.txt to generate all the docs.
|
|
|
|
| |
A fallout from commit b60cd25e366d
|
| |
|
|
|
|
| |
When running nosetest over all tests, modules having same name are not re-imported.
|
| |
|
|
|
|
|
|
| |
Let's not deviate from other providers by having '_build' directory.
Also moved the sources to source directory - just like the other
providers.
|
|
|
|
|
|
|
| |
Preserve the attributes of function being wrapped when creating a
wrapper in decorator.
Also removed redundant logging.
|
|
|
|
|
|
| |
Function wrappers should look like the functions being wrapped. Without
the *wraps()* decorator, the resulting function would not have assigned
doc string, would have wrong name etc.
|
| |
|
|
|
|
|
| |
Big number are displayed as 12,345 which breaks the parsing, with LANG=C
they're displayed as 12345 and parsed correctly.
|
| |
|
| |
|
| |
|
|
|
|
| |
providers.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This change adds ability to report new messages in the journal log.
This is done by the LMI_JournalLogRecord.CreateInstance() method call
taking only CreationClassName, LogCreationClassName, LogName and DataFormat
key properties as mandatory, with no need to specify the MessageTimestamp and
RecordID key properties. The returned instance will contain all the
information with actual RecordID key property of the new record.
As long as sd_journal_send() actually only queues the request, we need
to watch for journal changes in order to find the new record. This is
quite unfortunate as the daemon could be busy and we can't wait forever.
Messages are available immediately usually, a timeout is set to 5 seconds
for the moment.
Record matching is done by comparing the message itself, the origin function
name and PID. This brings sufficient amount of confidence though more
sophisticated approach may be needed in future to ensure full uniqueness.
|
|
|
|
|
| |
The commit c7777bfa1b1114fd9d changed format of the message we expose
to include process name and PID so let's update our tests accordingly.
|
|
|
|
|
|
|
| |
Tests basic iterator operations, assumes accessible journal and several (> 10)
records available.
Also comes with a simple example script for downloading complete journal.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This implements CIM_MessageLog iterator functionality according to
the model. The only limitation, or, let's say shortcoming, is a
free-form output data format from the GetRecord call. Currently we
feed the uint8 array with UTF-8 chars and it's up to the client to
deal with it (as suggested in the model). This may be subject to
change.
Many methods are returning modified iterator that has been passed
in and that allows having persistent iterators. As long as CIMOMs
may destroy the instances and unload providers on inactivity, any
particular delay would cause loss of the iterator. The iterator
string contains journal cursor string, uniquely identifying a
record. When this part of the iterator string is valid, the
provider is able to reopen journal and seek to that position,
allowing seamless continuation of the itearation process. If the
cursor points to non-existing record, an error is returned. This
typically happens when journal is rotated or the cursor is very
old.
The provider keeps track of active iterators during its lifetime,
keeping the journal open for fast access. Clients are supposed to
close the iterator by calling the CancelIteration method.
|
|
|
|
| |
Let's be consistent with traditional syslog message format.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Records in journal may contain syslog-style priority value so let's use
them. Unfortunately mapping the particular values between syslog and CIM
classes is not linear, manual mapping is needed.
The LOG_ERR may also map to PerceivedSeverity = Major but it's kept on
Minor for the moment.
If no such information is provided by the Journal, the CIM property is
left unset for the particular record.
See e.g. http://schemas.dmtf.org/wbem/cim-html/2.34.0/CIM_RecordForLog.html
for valuemap description.
|