File: transition_3_4.dox

package info (click to toggle)
libyang 4.7.3-1
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 11,096 kB
  • sloc: ansic: 131,389; xml: 671; sh: 448; tcl: 325; makefile: 19
file content (34 lines) | stat: -rw-r--r-- 2,887 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
/**
 * @page transition3_4 Transition Manual (3.x -> 4.0)
 *
 * There are not that major non-backwards-compatible changes between libyang version 3 and 4 and the version was
 * increased in part due to new functionality. The main new feature, which most of the changes are related to, is the
 * ability to __serialize (print) compiled YANG context__. What is more, such a printed context does not have to be
 * deserialized to be used by applications and they can directly read the printed context in run-time. This saves time
 * when reusing contexts since they do not always have to be created in every process but also potentially a lot of
 * memory since all the processes on the system may share a single printed context. Naturally, such a concept has
 * some limitations that are mentioned in detail in the documentation (@ref howtoPrintedContext).
 *
 * Related to this feature there were lots of minor changes to make sure all the intended functionality works. Most
 * importantly, there are now __2 dictionaries__ for a context. One, read-only for the strings in the compiled context
 * and the other for YANG data that can be written to normally. The main consequence of this is that comparing
 * directly (the addresses) of strings from these 2 dictionaries will not work. Also, it is now possible to __free all
 * the parsed modules__ from the context to save memory. The library functions should all be adjusted and handle such a
 * situation properly. Next, all __plugin references__ were replaced by an `uintptr_t` value but there are functions
 * ::lysc_get_type_plugin() and ::lysc_get_ext_plugin() for getting the actual plugin structures. Then, __default values
 * are stored as strings__ in the schema nodes. To learn their real type or get their canonical value, use
 * ::lyd_value_validate_dflt(). Finally, some new callbacks were required for extension-instance plugins so that they
 * can be printed with the context as well.
 *
 * Other notable changes include major LYB binary data format optimizations. The effect in API is that wherever a size
 * of a value is required, it is now expected in __bits instead of bytes__. Next, there are extension plugin API
 * improvements to account for custom XPath root definitions. Then, __obsolete nodes are not compiled__ and cannot be
 * instantiated in data by default but can be if requested by a context flag. Finally, the __"default" metadata instance__
 * connected to the `ietf-netconf-with-defaults` YANG module is now in the proper namespace, which is not the namespace
 * of this module. Other minor NBC changes should be reported by the compilator and they should be explained in the
 * documentation of the corresponding changed functions.
 *
 * The complete generated list of changes (without any additional notes) can be found in
 * <a href="../compat_report_3_4.html">the compatibility report</a>.
 *
 */