Product Documentation

ns extension

Sep 12, 2016

The following operations can be performed on "ns extension":

import ns extension

Imports the specified extension to the NetScaler appliance, assigns it the specified name, and stores it in the list of extension objects.

Synopsys

import ns extension <src> <name> [-comment <string>] [-overwrite]

Arguments

src

Local path to and name of, or URL (protocol, host, path, and file name) for, the file in which to store the imported extension.

NOTE: The import fails if the object to be imported is on an HTTPS server that requires client certificate authentication for access.

name

Name to assign to the extension object on the NetScaler appliance.

comment

Any comments to preserve information about the extension object.

overwrite

Overwrites the existing file

Example

import ns extension http://www.example.com/extension.lua my-extension 

rm ns extension

Removes the specified extension object.

Synopsys

rm ns extension <name>

Arguments

name

Name of the extension object to remove.

Example

rm ns extension my-extension

add ns extension

Add the specified extension object.

Synopsys

add ns extension <name> [-comment <string>]

Arguments

name

Name to assign to the extension object on the NetScaler appliance.

comment

Any comments to preserve information about the extension object.

Example

add ns extension my-extension 

update ns extension

Update the specified extension object.

Synopsys

update ns extension <name>

Arguments

name

Name to assign to the extension object on the NetScaler appliance.

Example

update ns extension my-extension 

set ns extension

Modifies properties of the extension, including the comment and tracing. Note that tracing parameters are not preserved by a save config and so do not survive a reboot.

Synopsys

set ns extension <name> [-trace <trace>] [-traceFunctions <string>] [-traceVariables <string>] [-comment <string>]

Arguments

name

Name to assign to the extension object on the NetScaler appliance.

trace

Enables tracing to the NS log file of extension execution:

off - turns off tracing (equivalent to unset ns extension <extension-name> -trace)

calls - traces extension function calls with arguments and function returns with the first return value

lines - traces the above plus line numbers for executed extension lines

all - traces the above plus local variables changed by executed extension lines

Note that the DEBUG log level must be enabled to see extension tracing.

This can be done by set audit syslogParams -loglevel ALL or -loglevel DEBUG.

Possible values: off, calls, lines, all

Default value: off

traceFunctions

Comma-separated list of extension functions to trace. By default, all extension functions are traced.

traceVariables

Comma-separated list of variables (in traced extension functions) to trace. By default, all variables are traced.

comment

Any comments to preserve information about the extension object.

Example

set ns extension <extension name> -tracing all

unset ns extension

Use this command to remove ns extension settings.Refer to the set ns extension command for meanings of the arguments.

Synopsys

unset ns extension <name> [-trace] [-traceFunctions] [-traceVariables] [-comment]

show ns extension

Displays the specified extension object.

Synopsys

show ns extension [<name>] [-detail ( brief | all )]

Arguments

name

Name of the extension object.

detail

Show detail for extension function.

Possible values: brief, all

Outputs

stateflag

src

Local path to and name of, or URL (protocol, host, path, and file name) for, the file in which to store the imported extension.

NOTE: The import fails if the object to be imported is on an HTTPS server that requires client certificate authentication for access.

type

extensionFunctionName

Name of extension function given in the extension.

extensionFunctionLineNumber

Line number of the function in file.

extensionFunctionClassType

Extension function class type.

extensionFunctionClasses

List of classes (including inherited) that the function is present in.

extensionFunctionClassesCount

Number of classes the function is present in.

extensionFunctionReturnType

Extension function return type.

activeExtensionFunction

Extension function is in use or not.

extensionFunctionArgType

List of extension function's arguments types

extensionFunctionAllParams

List of parameters (including promotions) that the function can accept.

extensionFunctionAllParamsCount

Number of parameters (including promotions) that the function can accept.

extensionFuncDescription

Any description to preserve information about the extension function.

extensionFunctionArgCount

Number of parameters in the extension function

comment

Any comments to preserve information about the extension object.

functionHits

Number of time function evaluates successfully.

functionUndefHits

Number of times error occured in evaluating extension function.

functionHaltCount

Number of time function evaluation is halted.

trace

Enables tracing to the NS log file of extension execution:

off - turns off tracing (equivalent to unset ns extension <extension-name> -trace)

calls - traces extension function calls with arguments and function returns with the first return value

lines - traces the above plus line numbers for executed extension lines

all - traces the above plus local variables changed by executed extension lines

Note that the DEBUG log level must be enabled to see extension tracing.

This can be done by set audit syslogParams -loglevel ALL or -loglevel DEBUG.

traceFunctions

Comma-separated list of extension functions to trace. By default, all extension functions are traced.

traceVariables

Comma-separated list of variables (in traced extension functions) to trace. By default, all variables are traced.

devno

count

Example

show ns extension my-extension