Removed obsolete compile options introduced in 6.1:
`NETCONF_DEFAULT_RETRIEVAL_REPORT_ALL` and `AUTOCLI_DEPRECATED_HIDE`
This commit is contained in:
parent
bd5b51d860
commit
e8a8b17e1b
5 changed files with 11 additions and 59 deletions
|
|
@ -43,6 +43,12 @@
|
||||||
## 6.3.0
|
## 6.3.0
|
||||||
Expected: July 2023
|
Expected: July 2023
|
||||||
|
|
||||||
|
### Minor features
|
||||||
|
|
||||||
|
* Removed obsolete compile options introduced in 6.1:
|
||||||
|
* `NETCONF_DEFAULT_RETRIEVAL_REPORT_ALL`
|
||||||
|
* `AUTOCLI_DEPRECATED_HIDE`
|
||||||
|
|
||||||
### Corrected Bugs
|
### Corrected Bugs
|
||||||
|
|
||||||
* Fixed autocli edit modes for schema mounts
|
* Fixed autocli edit modes for schema mounts
|
||||||
|
|
|
||||||
|
|
@ -866,13 +866,7 @@ get_common(clicon_handle h,
|
||||||
withdefaults_type wdef;
|
withdefaults_type wdef;
|
||||||
char *wdefstr;
|
char *wdefstr;
|
||||||
|
|
||||||
#ifdef NETCONF_DEFAULT_RETRIEVAL_REPORT_ALL
|
|
||||||
/* Clixon 6.0 backward compatibly for NETCONF get/get-config behavior */
|
|
||||||
wdef = WITHDEFAULTS_REPORT_ALL;
|
|
||||||
#else
|
|
||||||
wdef = WITHDEFAULTS_EXPLICIT;
|
wdef = WITHDEFAULTS_EXPLICIT;
|
||||||
#endif
|
|
||||||
|
|
||||||
clicon_debug(CLIXON_DBG_DETAIL, "%s", __FUNCTION__);
|
clicon_debug(CLIXON_DBG_DETAIL, "%s", __FUNCTION__);
|
||||||
username = clicon_username_get(h);
|
username = clicon_username_get(h);
|
||||||
if ((yspec = clicon_dbspec_yang(h)) == NULL){
|
if ((yspec = clicon_dbspec_yang(h)) == NULL){
|
||||||
|
|
|
||||||
|
|
@ -37,6 +37,7 @@
|
||||||
* cli-edit-mode - This is the api-path of the current cli mode in the loaded yang context
|
* cli-edit-mode - This is the api-path of the current cli mode in the loaded yang context
|
||||||
* cli-edit-cvv - These are the assigned cligen list of variables with values at the edit-mode
|
* cli-edit-cvv - These are the assigned cligen list of variables with values at the edit-mode
|
||||||
* cli-edit-filter - Label filters for this mode
|
* cli-edit-filter - Label filters for this mode
|
||||||
|
* cli-edit-mtpoint - If edit modes are used, which mountpoint to use if any
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef HAVE_CONFIG_H
|
#ifdef HAVE_CONFIG_H
|
||||||
|
|
|
||||||
|
|
@ -146,11 +146,7 @@ cli_expand_var_generate(clicon_handle h,
|
||||||
cv = yang_cv_get(yspec);
|
cv = yang_cv_get(yspec);
|
||||||
if (yang_extension_value(ys, "hide", CLIXON_AUTOCLI_NS, &extvalue, NULL) < 0)
|
if (yang_extension_value(ys, "hide", CLIXON_AUTOCLI_NS, &extvalue, NULL) < 0)
|
||||||
goto done;
|
goto done;
|
||||||
if (extvalue
|
if (extvalue || yang_find(ys, Y_STATUS, "deprecated") != NULL) {
|
||||||
#ifdef AUTOCLI_DEPRECATED_HIDE
|
|
||||||
|| yang_find(ys, Y_STATUS, "deprecated") != NULL
|
|
||||||
#endif
|
|
||||||
) {
|
|
||||||
retval = 1;
|
retval = 1;
|
||||||
goto done;
|
goto done;
|
||||||
}
|
}
|
||||||
|
|
@ -832,11 +828,7 @@ yang2cli_leaf(clicon_handle h,
|
||||||
cprintf(cb, " ");
|
cprintf(cb, " ");
|
||||||
if (yang_extension_value(ys, "hide", CLIXON_AUTOCLI_NS, &hideext, NULL) < 0)
|
if (yang_extension_value(ys, "hide", CLIXON_AUTOCLI_NS, &hideext, NULL) < 0)
|
||||||
goto done;
|
goto done;
|
||||||
if (hideext
|
if (hideext || yang_find(ys, Y_STATUS, "deprecated") != NULL){
|
||||||
#ifdef AUTOCLI_DEPRECATED_HIDE
|
|
||||||
|| yang_find(ys, Y_STATUS, "deprecated") != NULL
|
|
||||||
#endif
|
|
||||||
){
|
|
||||||
cprintf(cb, ", hide"); /* XXX ensure always { */
|
cprintf(cb, ", hide"); /* XXX ensure always { */
|
||||||
}
|
}
|
||||||
if (extralevel){
|
if (extralevel){
|
||||||
|
|
@ -929,11 +921,7 @@ yang2cli_container(clicon_handle h,
|
||||||
goto done;
|
goto done;
|
||||||
if (yang_extension_value(ys, "hide", CLIXON_AUTOCLI_NS, &extvalue, NULL) < 0)
|
if (yang_extension_value(ys, "hide", CLIXON_AUTOCLI_NS, &extvalue, NULL) < 0)
|
||||||
goto done;
|
goto done;
|
||||||
if (extvalue
|
if (extvalue || yang_find(ys, Y_STATUS, "deprecated") != NULL){
|
||||||
#ifdef AUTOCLI_DEPRECATED_HIDE
|
|
||||||
|| yang_find(ys, Y_STATUS, "deprecated") != NULL
|
|
||||||
#endif
|
|
||||||
){
|
|
||||||
cprintf(cb, ", hide");
|
cprintf(cb, ", hide");
|
||||||
}
|
}
|
||||||
#ifdef NYI /* This is for the mode extension, not yet supported */
|
#ifdef NYI /* This is for the mode extension, not yet supported */
|
||||||
|
|
@ -1009,11 +997,7 @@ yang2cli_list(clicon_handle h,
|
||||||
}
|
}
|
||||||
if (yang_extension_value(ys, "hide", CLIXON_AUTOCLI_NS, &exist, NULL) < 0)
|
if (yang_extension_value(ys, "hide", CLIXON_AUTOCLI_NS, &exist, NULL) < 0)
|
||||||
goto done;
|
goto done;
|
||||||
if (exist
|
if (exist || yang_find(ys, Y_STATUS, "deprecated") != NULL){
|
||||||
#ifdef AUTOCLI_DEPRECATED_HIDE
|
|
||||||
|| yang_find(ys, Y_STATUS, "deprecated") != NULL
|
|
||||||
#endif
|
|
||||||
){
|
|
||||||
cprintf(cb, ",hide");
|
cprintf(cb, ",hide");
|
||||||
}
|
}
|
||||||
/* Loop over all key variables */
|
/* Loop over all key variables */
|
||||||
|
|
|
||||||
|
|
@ -164,36 +164,3 @@
|
||||||
* Consider moving to configure.ac(compile-time) or to clixon-config.yang(run-time)
|
* Consider moving to configure.ac(compile-time) or to clixon-config.yang(run-time)
|
||||||
*/
|
*/
|
||||||
#define PRETTYPRINT_INDENT 3
|
#define PRETTYPRINT_INDENT 3
|
||||||
|
|
||||||
/*! Set backward compatibility for NETCONF get/get-config <with-defaults> parameter behavior
|
|
||||||
*
|
|
||||||
* This option sets backward-compability that has to do with an inconsistency
|
|
||||||
* between the two following concepts defined in RFC 6243:
|
|
||||||
* - Default-Handling Basic Modes (Section 2 in RFC 6243)
|
|
||||||
* - Retrieval of Default Data (Section 3 in RFC 6243)
|
|
||||||
*
|
|
||||||
* Before Clixon 6.0 RFC 6243 Clixon had a non-RFC with-defaults behavior:
|
|
||||||
* - Default-Handling Basic Mode is "explicit" (it does not store default values)
|
|
||||||
* - Retrieval of Default data is "report-all" (all default values are filled in)
|
|
||||||
*
|
|
||||||
* After the RFC6243 implementation introduced in 6.0, Clixon implemented the <with-defaults>
|
|
||||||
* parameter for all get/config but retained the pre-6.0 default get/get-config behaviour.
|
|
||||||
* - Default-Handling Basic Mode is "explicit" (announced as a capability)
|
|
||||||
* - Retrieval of Default data is "report-all"
|
|
||||||
*
|
|
||||||
* The 6.0 behaviour is inconsistent and therefore in Clixon 6.1 the default retrieval data
|
|
||||||
* is changed to "explicit" to be consistent with the basic mode:
|
|
||||||
* - Default-Handling Basic Mode is "explicit"
|
|
||||||
* - Retrieval of Default data is "explicit" <---
|
|
||||||
*
|
|
||||||
* This may lead to changes in behavior for clients retrieving configs without an explicit
|
|
||||||
* <with-defaults> parameter.
|
|
||||||
* To keep the previous behavior (as in 6.0) set this option with #define
|
|
||||||
* Introduced in 6.1, remove in 6.3
|
|
||||||
*/
|
|
||||||
#undef NETCONF_DEFAULT_RETRIEVAL_REPORT_ALL
|
|
||||||
|
|
||||||
/*! Temporary backward-compatible option for hiding CLI for deprecated YANG
|
|
||||||
* Introduced in 6.1, remove in 6.3
|
|
||||||
*/
|
|
||||||
#define AUTOCLI_DEPRECATED_HIDE
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue