---
name: "globus_ftp_client_throughput_nl_plugin_destroy"
section: "3"
platform: "linux"
package: "libglobus-ftp-client-doc"
version: "9.8-4"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/globus_ftp_client_throughput_nl_plugin"
---

# globus\_ftp\_client\_throughput\_nl\_plugin\_destroy(3)

Netlogger Throughput Plugin - Netlogger Throughput Plugin.

Part of [globus\_ftp\_client\_throughput\_nl\_plugin(3)](/globus_ftp_client_throughput_nl_plugin/3.md).

## NAME

globus\_ftp\_client\_throughput\_nl\_plugin - Netlogger Throughput Plugin

 \- Netlogger Throughput Plugin.

## SYNOPSIS

### Macros

\#define **GLOBUS\_FTP\_CLIENT\_THROUGHPUT\_NL\_PLUGIN\_MODULE**   (&globus\_i\_ftp\_client\_throughput\_nl\_plugin\_module)\

### Functions

globus\_result\_t **globus\_ftp\_client\_throughput\_nl\_plugin\_init** (**globus\_ftp\_client\_plugin\_t** \*plugin, const char \*nl\_url, const char \*prog\_name, const char \*opaque\_string)\
 globus\_result\_t **globus\_ftp\_client\_throughput\_nl\_plugin\_init\_with\_handle** (**globus\_ftp\_client\_plugin\_t** \*plugin, NLhandle \*nl\_handle, const char \*opaque\_string)\
 globus\_result\_t **globus\_ftp\_client\_throughput\_nl\_plugin\_destroy** (**globus\_ftp\_client\_plugin\_t** \*plugin)\
 globus\_result\_t **globus\_ftp\_client\_throughput\_nl\_plugin\_set\_callbacks** (**globus\_ftp\_client\_plugin\_t** \*plugin, **globus\_ftp\_client\_throughput\_plugin\_begin\_cb\_t** begin\_cb, **globus\_ftp\_client\_throughput\_plugin\_stripe\_cb\_t** per\_stripe\_cb, **globus\_ftp\_client\_throughput\_plugin\_total\_cb\_t** total\_cb, **globus\_ftp\_client\_throughput\_plugin\_complete\_cb\_t** complete\_cb, void \*user\_specific)\

## Detailed Description

Netlogger Throughput Plugin.

This plugin allows a user to easily use the throughput plugin to log performance data vi Netlogger.

The plugin will log the following Event Types with its coressponding info

TransferPerfTotal : This event type will be sent every time a throughput plugin total callback is received.

- •

  URL.SOURCE \<string\> Source url of transfer

- •

  URL.DEST \<string\> Dest url of transfer

- •

  BYTES \<int\> Total bytes transferred thus far

- •

  BW.CURRENT \<float\> Current (instantaneous) bandwidth

- •

  BW.AVG \<float\> Average (instantaneous) bandwidth

TransferPerfStripe : This event type will be sent every time a throughput plugin stripe callback is received.

- •

  URL.SOURCE \<string\> Source url of transfer

- •

  URL.DEST \<string\> Dest url of transfer

- •

  INDEX \<int\> The stripe index the event applies to

- •

  BYTES \<int\> Total bytes transferred thus far on this stripe

- •

  BW.CURRENT \<float\> Current (instantaneous) bandwidth on this stripe

- •

  BW.AVG \<float\> Average (instantaneous) bandwidth on this stripe

TransferBegin : This event type will be sent every time a throughput plugin begin callback is received.

- •

  URL.SOURCE \<string\> Source url of transfer

- •

  URL.DEST \<string\> Dest url of transfer

TransferEnd : This event type will be sent every time a throughput plugin complete callback is received.

- •

  SUCCESS \<bool\> Completion status

## Macro Definition Documentation

### #define GLOBUS\_FTP\_CLIENT\_THROUGHPUT\_NL\_PLUGIN\_MODULE (&globus\_i\_ftp\_client\_throughput\_nl\_plugin\_module)

Module descriptor

## Function Documentation

### globus\_result\_t globus\_ftp\_client\_throughput\_nl\_plugin\_destroy (globus\_ftp\_client\_plugin\_t \* plugin)

Destroy netlogger wrapped throughput plugin

Frees up memory associated with plugin

**Parameters**

*plugin* plugin previously initialized with init (above)

**Returns**

- •

  GLOBUS\_SUCCESS

- •

  Error on NULL plugin

### globus\_result\_t globus\_ftp\_client\_throughput\_nl\_plugin\_init (globus\_ftp\_client\_plugin\_t \* plugin, const char \* nl\_url, const char \* prog\_name, const char \* opaque\_string)

Initialize netlogger wrapped throughput plugin

This will initialize a netlogger wrapped throughput plugin. Note that the nl\_url may be NULL. Regardless of what nl\_host is set to, if the env variable NL\_DEST\_ENV is set, logging will always occur to that location.

**Parameters**

*plugin* a plugin to be initialized\
 *nl\_url* the url to log to (May be NULL) Valid urls are: file://tmp/netlog.log x-netlog://host\[:port\] x-syslog://localhost\
 *prog\_name* This is used as the prog name in the NetLoggerOpen call\
 *opaque\_string* this is an opaque string that will be inserted into all logged statements. (may be NULL)

**Returns**

- •

  Error on NULL plugin or failure to init throughput plugin

- •

  Error on NetLogger open

- •

  GLOBUS\_SUCCESS

### globus\_result\_t globus\_ftp\_client\_throughput\_nl\_plugin\_init\_with\_handle (globus\_ftp\_client\_plugin\_t \* plugin, NLhandle \* nl\_handle, const char \* opaque\_string)

Initialize netlogger wrapped throughput plugin

This will initialize a netlogger wrapped throughput plugin. Instead of passing a NetLogger url as in the plain init func, you can pass in a previously 'Open'ed NLhandle. This handle will not be destroyed by this plugin.

**Parameters**

*plugin* a plugin to be initialized\
 *nl\_handle* a previously opened NetLogger handle\
 *opaque\_string* this is an opaque string that will be inserted into all logged statements. (may be NULL)

**Returns**

- •

  Error on NULL plugin or failure to init throughput plugin

- •

  Error on NetLogger open

- •

  GLOBUS\_SUCCESS

### globus\_result\_t globus\_ftp\_client\_throughput\_nl\_plugin\_set\_callbacks (globus\_ftp\_client\_plugin\_t \* plugin, globus\_ftp\_client\_throughput\_plugin\_begin\_cb\_t begin\_cb, globus\_ftp\_client\_throughput\_plugin\_stripe\_cb\_t per\_stripe\_cb, globus\_ftp\_client\_throughput\_plugin\_total\_cb\_t total\_cb, globus\_ftp\_client\_throughput\_plugin\_complete\_cb\_t complete\_cb, void \* user\_specific)

Receive throughput callbacks

You can still get the automatic netlogging of throughput along with receiving the same throughput callbacks that the throughput plugin provides by using this function to set these callbacks. Note that the callbacks are defined the same as in the throughput plugin

**Parameters**

*plugin* \
 *begin\_cb* the callback to be called upon the start of a transfer\
 *per\_stripe\_cb* the callback to be called every time updated throughput info is available for a given stripe\
 *total\_cb* the callback to be called every time updated throughput info is available for any stripe\
 *complete\_cb* the callback to be called to indicate transfer completion\
 *user\_specific* a pointer to some user specific data that will be provided to all callbacks

**Returns**

- •

  Error on NULL or invalid plugin

- •

  GLOBUS\_SUCCESS

**See also**

**Throughput Performance Plugin**

## Author

Generated automatically by Doxygen for globus\_ftp\_client from the source code.
