Y-lib
Loadrunner libraries
Functions
y_vts.c File Reference

VTS functions for LR 11.5 and above. More...

Go to the source code of this file.

Functions

void y_vts_report_error (char *message)
 
int y_vts_process_returncode (int returncode)
 Error translation and reporting facility for VTS return codes. This will emit VTS errors using lr_error_message() in human readable form, if the code represents a VTS error. More...
 

Detailed Description

VTS functions for LR 11.5 and above.

Library wrapperrs for talking to a VTS-server. This is part of LR 11.5 and needs to be installed seperately. For LR versions older than 11.5, see the old y_vts.c.

Warning
This y_vts.c is NOT compatible with the vts version that was shipped before LR 11.5, and the older y_vts.c is NOT compatible with the version in LR 11.5 either.

Definition in file y_vts.c.

Function Documentation

int y_vts_process_returncode ( int  returncode)

Error translation and reporting facility for VTS return codes. This will emit VTS errors using lr_error_message() in human readable form, if the code represents a VTS error.

Parameters
returncodeAn error code as returned by VTS
Returns
the returncode

This is what the header file vts2.h tells us about error codes:

1 //VTS Error Codes
2 #define VTCERR_OK 0
3 #define VTCERR_INVALID_CONNECTION_INFO -10000
4 #define VTCERR_FAILED_TO_RESOLVE_ADDR -10001
5 #define VTCERR_FAILED_TO_CREATE_SOCKET -10002
6 #define VTCERR_FAILED_TO_CONNECT -10003
7 
8 #define VTCERR_INCOMPLETE_REQUEST -10100
9 #define VTCERR_FAILED_TO_RECV_RESPONSE -10101
10 #define VTCERR_INCOMPLETE_RESPONSE -10102
11 #define VTCERR_RESPONSE_ARGS_UNMATCH -10103
12 
13 // --- Operation Error Base
14 #define VTCERR_OPERATION_ERROR_BASE -11000
15 #define VTCERR_SERVER_IS_BUSY (VTCERR_OPERATION_ERROR_BASE - 0xFF)
16 #define VTCERR_CLIENT_REQUEST_ERROR (VTCERR_OPERATION_ERROR_BASE - 0xFE)

Loadrunner 11.52 expanded that a little, to the following definition in the help files:

1 VTCERR_OK 0 Success
2 VTCERR_INVALID_CONNECTION_INFO -10000 The corresponding handle does not exist or the connection information is corrupted. Disconnect and reconnect.
3 VTCERR_FAILED_TO_RESOLVE_ADDR -10001 Failed to find server.
4 VTCERR_FAILED_TO_CREATE_SOCKET -10002 Failed to create socket.
5 VTCERR_FAILED_TO_CONNECT -10003 Failed to connect. Check the server name, port number, network connectivity, and whether server is on line.
6 VTCERR_INVALID_API_CALL -10004 Failed to get the API entry. <-- NEW
7 
8 VTCERR_INCOMPLETE_REQUEST -10100 Communications packet from client is invalid.
9 VTCERR_FAILED_TO_RECV_RESPONSE -10101 No response received from server.
10 VTCERR_INCOMPLETE_RESPONSE -10102 Communications packet from server is invalid.
11 VTCERR_RESPONSE_ARGS_UNMATCH -10103 Unexpected count of arguments in server response.
12 VTCERR_INVALID_ARGUMENT -10104 Invalid argument. <-- NEW
13 VTCERR_HANDLE_NOT_EXIST -10105 Connection handle does not exist. <-- NEW
14 VTCERR_INNER_JSON_CONVERT -10106 Cannot parse server response. <-- NEW
15 VTCERR_INNER_UTF8_CONVERT -10107 Cannot convert between UTF8 and Locale. <-- NEW
16 VTCERR_COL_FORMAT_ERROR -10108 Invalid or empty column name. <-- NEW
17 VTCERR_COL_VALUE_NO_MATCH -10109 Column names list and messages list do not have the same number of values. Check delimiters. <-- NEW
18 VTCERR_EVAL_STRING -10110 Error evaluating parameter value. <-- NEW
19 VTCERR_DATA_NOT_EXIST -10111 There is no data at the specified column and row. <-- NEW

.. note however that the "Operation Error Base" codes are gone.

Author
Floris Kraak

Definition at line 103 of file y_vts.c.

void y_vts_report_error ( char *  message)

Definition at line 42 of file y_vts.c.