\label{doc_news_2014-09-02_0_8_8_md_md_doc_news_2014_09_02_0_8_8}%
\Hypertarget{doc_news_2014-09-02_0_8_8_md_md_doc_news_2014_09_02_0_8_8}%

\begin{DoxyItemize}
\item guid\+: eca69e19-\/5ddb-\/438c-\/ac06-\/57c20b1a9160
\item author\+: Markus Raab
\item pub\+Date\+: Tue, 02 Sep 2014 17\+:31\+:42 +0200
\item short\+Desc\+: adds 3-\/way merging, reworked documentation \& improved kdb tool
\end{DoxyItemize}

In this release we changed 578 files in 473 commits (68596 insertions(+), 59260 deletions(-\/) compared to Elektra 0.\+8.\+7). We assume thats the largest change set for any of Elektra’s releases up to now. It happened only within a bit more than a month up (0.\+8.\+7 was released 28.\+07.\+2014).\hypertarget{doc_news_2014-09-02_0_8_8_md_autotoc_md2821}{}\doxysection{New features}\label{doc_news_2014-09-02_0_8_8_md_autotoc_md2821}
GSoC finished successfully (thanks Ian and Felix) See \href{http://community.libelektra.org/wp}{\texttt{ http\+://community.\+libelektra.\+org/wp}} for the latest results. So Elektra now has a 3-\/way merging framework that is superior to text-\/based merging in many scenarios (e.\+g. moving configuration options within a file or with in-\/line comments) iff a storage plugin creates key names that are not only line numbers. We love to get Feedback!

Writing plugins is now even more comfortable. A plugin writer tutorial was written (thanks Ian)\+: \href{https://github.com/ElektraInitiative/libelektra/blob/master/doc/tutorials/plugins.md}{\texttt{ https\+://github.\+com/\+Elektra\+Initiative/libelektra/blob/master/doc/tutorials/plugins.\+md}} The documentation was completely reworked\+: \href{https://doc.libelektra.org/api/0.8.7/html/group__plugin.html}{\texttt{ https\+://doc.\+libelektra.\+org/api/0.\+8.\+7/html/group\+\_\+\+\_\+plugin.\+html}} And two new macros allow printf formatting for warnings and errors ({\ttfamily ELEKTRA\+\_\+\+ADD\+\_\+\+WARNINGF} and {\ttfamily ELEKTRA\+\_\+\+SET\+\_\+\+ERRORF}).

The ini plugin was greatly improved (tested with samba configurations and added to ALL plugins) and the hosts plugin was rewritten to support ipv6 properly (thanks to Felix).

The constants plugin was added and allows introspection of Elektra’s cmake variables. Because such non-\/file-\/based plugins (e.\+g. also uname) do not need resolving, the plugin noresolver was added. It supersedes the success plugin.

Elektra now allows one to correctly fsync its configuration files (sync plugin) and the folders where files are stored (resolver plugin). Just make sure to add the \char`\"{}sync\char`\"{} plugin using kdb mount. The resolver plugin now reads from passwd and no longer needs environment variables. Additionally, the resolver plugin was prepared to support other variants by so-\/called compilation variants.

The error plugin now allows, next to list all possible errors, to provoke errors when opening plugins. We fixed some issues related to plugins having errors when they initialize themselves.

So following plugins were added\+: sync noresolver line ini constants Nearly all plugins now have a README.\+md for further information (thanks to Ian). An overview of all plugin is on with links to them\+: \href{https://github.com/ElektraInitiative/libelektra/blob/master/src/plugins/}{\texttt{ https\+://github.\+com/\+Elektra\+Initiative/libelektra/blob/master/src/plugins/}}

The kdb tools were greatly improved (thanks to Felix)\+:


\begin{DoxyItemize}
\item added remount tool
\item umount now also accepts mountpath
\item mount allows one to specify different resolvers
\item import now can use merge strategies
\item check without arguments checks key database
\item mount is now more verbose when validation fails
\end{DoxyItemize}

New/improved scripts/make targets (note that scripts can be executed by kdb scriptname)\+:


\begin{DoxyItemize}
\item mounting, unmounting scripts were added
\item generate template for a new plugin was improved
\item configure-\/debian was added
\item added targets {\ttfamily run\+\_\+all} and {\ttfamily run\+\_\+memcheck}
\item bash completion file now installed
\item ucf integration
\item merging scripts were added for the usage with ucf
\item scripts doing internal checks on source of plugins
\end{DoxyItemize}\hypertarget{doc_news_2014-09-02_0_8_8_md_autotoc_md2822}{}\doxysection{Compatibility}\label{doc_news_2014-09-02_0_8_8_md_autotoc_md2822}
This time we had to break compatibility. We did not change the ABI (your application still will be able to use Elektra 0.\+8.\+8) and we did not change the API (your application still will compile against Elektra). We changed the third part of our interface\+: the semantic interface.

The problems were following\+: key\+Add\+Base\+Name/key\+Set\+Base\+Name did something obvious when no special characters were in the base\+Name. But once there were, there are two different interpretations what it should do\+:


\begin{DoxyEnumerate}
\item add/set a basename, so escape characters that are not canonical in the basename
\item add all parts of the name given (with slashes)
\end{DoxyEnumerate}

The methods were used in both ways, so it was obvious that something is very wrong. We decided that it should do what the name says, that is add/set a basename (variant 1).

The variant 2, to add any name was added and is called \mbox{\hyperlink{group__keyname_gaa70593a2c772c4b7bc33423b9b10a270}{key\+Add\+Name()}} and added as proposal.

(Thank Felix for implementations and Manuel for investigations)

When keys are renamed after adding to a keyset is a bad thing because it destroys the order of the keyset. This is now avoided by key\+Lock. Use key\+Dup() to get rid of such locks.

Another, even larger, change is also about ordering of keys in keysets. Elektra now internally has an null-\/terminated unescaped key name. Ordering of keysets will always happen on this name. The {\ttfamily \mbox{\hyperlink{group__keytest_gaf6e66e12fe04d535a5d1c8218ced803e}{key\+Cmp()}}} tool can be used to check this order. It works very efficiently with {\ttfamily memcmp()} and never gets confused by ASCII ordering of / (because / is 0 in the unescaped key name).

The syntax, semantics and conventions of key names is now documented in detail\+: \href{https://doc.libelektra.org/api/0.8.8/html/group__keyname.html}{\texttt{ https\+://doc.\+libelektra.\+org/api/0.\+8.\+8/html/group\+\_\+\+\_\+keyname.\+html}}

\mbox{\hyperlink{group__keyset_ga671e1aaee3ae9dc13b4834a4ddbd2c3c}{ks\+New()}} does now return a keyset with a properly set cursor (ks\+Rewind).

Because its always possible that software relies on bugs the better way to deal with such a situation (as the \mbox{\hyperlink{group__keyname_ga6e804bd453f98c28b0ff51430d1df407}{key\+Set\+Base\+Name()}} situation described above) is to provide the same function twice. Manuel said he will create a prototype to introduce symbol versioning in Elektra. With that, old customers would still receive the old behavior, but people compiling against a new version would get the new behavior. So in one of the next releases we will also avoid semantic interface changes when there is a valid use case for it (there is none if the program e.\+g. crashes).

Symbol versioning also allows one to compile against old versions on purpose if you do not want the new behavior.

We have prepared an ABI-\/test suite, that also checks behavior, for that purpose, but we also improved testing in other parts\+:


\begin{DoxyItemize}
\item (New Test strategy)\mbox{[}/doc/\+TESTING.md\mbox{]}
\item New resolver tests for conflicts (needs tty)
\end{DoxyItemize}

If you try to execute test\+\_\+ks from 0.\+8.\+7 with libelektra 0.\+8.\+8 it will crash, but not because of any incompatibility, but because of {\ttfamily strcmp} in the test itself gets a null pointer. The pointer is now null, because ks\+New correctly rewinds its internal cursor (see above). Amusingly, it says on that line 94 in test\+\_\+ks.\+c\+: // TODO\+: why is the cursor here?\hypertarget{doc_news_2014-09-02_0_8_8_md_autotoc_md2823}{}\doxysection{API Proposals}\label{doc_news_2014-09-02_0_8_8_md_autotoc_md2823}
see above for more information\+:


\begin{DoxyItemize}
\item {\ttfamily key\+Add\+Name} .. add key name without escaping, like key\+Set\+Name
\item {\ttfamily key\+Unescaped\+Name} .. get access to null-\/separated unescaped name
\item {\ttfamily key\+Lock} .. to allow one to secure keys against modifications
\end{DoxyItemize}

some new ideas\+:


\begin{DoxyItemize}
\item {\ttfamily key\+Set\+StringF} .. printf format-\/style changing of the key string
\item {\ttfamily elektra\+Key\+Set\+Name} .. to allow one to set meta + cascading keys
\end{DoxyItemize}

{\ttfamily \mbox{\hyperlink{array_8c_afc46476b8d722d89e07a966e023df317}{elektra\+Array\+Inc\+Name()}}} now works correctly with empty arrays embedded in other arrays (yajl+line plugin)

{\ttfamily \mbox{\hyperlink{array_8c_ac97baa33fb7b7e83192e156827ba2eb5}{elektra\+Array\+Validate\+Name()}}} was also added, thanks to Felix.

These methods are declared in the file {\ttfamily \mbox{\hyperlink{kdbproposal_8h}{kdbproposal.\+h}}} but do not guarantee any forms of compatibility (they might even be removed).\hypertarget{doc_news_2014-09-02_0_8_8_md_autotoc_md2824}{}\doxysection{Issues}\label{doc_news_2014-09-02_0_8_8_md_autotoc_md2824}
Many issues were resolved as you can see in github\+: \href{https://github.com/ElektraInitiative/libelektra/issues}{\texttt{ https\+://github.\+com/\+Elektra\+Initiative/libelektra/issues}} Alone for the milestone 0.\+8.\+8 we closed 17 issues, including those mentioned in \char`\"{}\+Compatibility\char`\"{}. Other issues (not all were tracked on Git\+Hub)\+:


\begin{DoxyItemize}
\item fix undefined errors in {\ttfamily \mbox{\hyperlink{group__kdb_ga844e1299a84c3fbf1d3a905c5c893ba5}{kdb\+Open()}}} or {\ttfamily \mbox{\hyperlink{group__kdb_gadb54dc9fda17ee07deb9444df745c96f}{kdb\+Close()}}}
\item Now Python 2+3 work in parallel
\item python2 interpreter is found correctly (also on Arch)
\item Sentinel now makes sure that you cannot forget {\ttfamily KS\+\_\+\+END} to end {\ttfamily ks\+New}
\item Fixes for architecture-\/specific problems by Pino
\item fix .pc file
\item fix compilation problem with {\ttfamily KDB\+\_\+\+MAX\+\_\+\+PATH\+\_\+\+LENGTH}
\item tmpnam to mkstemp (security)
\item make test data naming consistent (thanks Pino)
\item use {\ttfamily LIB\+\_\+\+SUFFIX for TARGET\+\_\+\+TOOL\+\_\+\+EXEC\+\_\+\+FOLDER} thanks to Kai Uwe
\item Fix search for boost (thank Pino)
\end{DoxyItemize}\hypertarget{doc_news_2014-09-02_0_8_8_md_autotoc_md2825}{}\doxysection{Other Stuff}\label{doc_news_2014-09-02_0_8_8_md_autotoc_md2825}
Thanks to Pino Toscano Elektra 0.\+8.\+7-\/4 is now available in Debian Testing\+: \href{https://packages.debian.org/search?keywords=elektra}{\texttt{ https\+://packages.\+debian.\+org/search?keywords=elektra}} So it is only a matter of time that other (debian-\/based) distributions will follow and replace the dusty Elektra 0.\+7.

Debian Continuous Integration \href{http://ci.debian.net/packages/e/elektra}{\texttt{ http\+://ci.\+debian.\+net/packages/e/elektra}} (thanks Pino) greatly complement our tests running on \href{https://build.libelektra.org/}{\texttt{ https\+://build.\+libelektra.\+org/}}

Elektra’s buildserver also was improved\+:


\begin{DoxyItemize}
\item now also compiles with icc
\item runs {\ttfamily make run\+\_\+memcheck}
\item checks if plugins are added correctly in-\/source
\item runs ABI + behavioral tests
\end{DoxyItemize}

Raffael Pancheri now made a merge request for qt-\/gui \href{https://github.com/ElektraInitiative/libelektra/pull/103/files}{\texttt{ https\+://github.\+com/\+Elektra\+Initiative/libelektra/pull/103/files}} in which copy, paste and delete of keys already works. It is, however, still work in progress.

Manuel Mausz made great progress in script-\/based Elektra plugins. He is also working on glib+gobject-\/introspection based bindings. He investigated some issues, e.\+g. a crash of the python binding which was only triggered if python3 is build with a specific flag/module combination, see\+: \href{https://github.com/ElektraInitiative/libelektra/issues/25}{\texttt{ https\+://github.\+com/\+Elektra\+Initiative/libelektra/issues/25}}\hypertarget{doc_news_2014-09-02_0_8_8_md_autotoc_md2826}{}\doxysection{Get It!}\label{doc_news_2014-09-02_0_8_8_md_autotoc_md2826}
You can download the release from\+:

\href{http://www.markus-raab.org/ftp/elektra/releases/elektra-0.8.8.tar.gz}{\texttt{ http\+://www.\+markus-\/raab.\+org/ftp/elektra/releases/elektra-\/0.\+8.\+8.\+tar.\+gz}}


\begin{DoxyItemize}
\item size\+: 1644441
\item md5sum\+: fe11c6704b0032bdde2d0c8fa5e1c7e3
\item sha1\+: 16e43c63cd6d62b9fce82cb0a33288c390e39d12
\item sha256\+: ae75873966f4b5b5300ef5e5de5816542af50f35809f602847136a8cb21104e2
\end{DoxyItemize}

already built API-\/\+Docu can be found here\+:

\href{https://doc.libelektra.org/api/0.8.8/html/}{\texttt{ https\+://doc.\+libelektra.\+org/api/0.\+8.\+8/html/}}

Best regards, Markus 