Alt-NewRelic-Agent-FFI-Empty
view release on metacpan or search on metacpan
lib/NewRelic/Agent/FFI.pm view on Meta::CPAN
my $rc = $agent->set_transaction_name($tx, $name);
Sets the transaction name.
=head2 set_transaction_request_url
my $rc = $agent->set_transaction_request_url($tx, $url);
Sets the transaction URL.
=head2 set_transaction_max_trace_segments
my $rc = $agent->set_transaction_max_trace_segments($tx, $max);
Sets the maximum trace section for the transaction.
=head2 set_transaction_category
my $rc = $agent->set_transaction_category($tx, $category);
Sets the transaction category.
=head2 set_transaction_type_web
my $rc = $agent->set_transaction_type_web($tx);
Sets the transaction type to 'web'
=head2 set_transaction_type_other
my $rc = $agent->set_transaction_type_other($tx);
Sets the transaction type to 'other'
=head2 add_transaction_attribute
my $rc = $agent->add_transaction_attribute($tx, $key => $value);
Adds the given attribute (key/value pair) for the transaction.
=head2 notice_transaction_error
my $rc = $agent->notice_transaction_error($tx, $exception_type, $error_message, $stack_trace, $stack_frame_delimiter);
Identify an error that occurred during the transaction. The first identified
error is sent with each transaction.
=head2 end_transaction
my $rc = $agent->end_transaction($tx);
=head2 record_metric
my $rc = $agent->record_metric($key => $value);
Records the given metric (key/value pair). The C<$value> should be a floating point.
=head2 record_cpu_usage
my $rc = $agent->record_cpu_usage($cpu_user_time_seconds, $cpu_usage_percent);
Records the CPU usage. C<$cpu_user_time_seconds> and C<$cpu_usage_percent> are floating point values.
=head2 record_memory_usage
my $rc = $agent->record_memory_usage($memory_megabytes);
Records the memory usage. C<$memory_megabytes> is a floating point value.
=head2 begin_generic_segment
my $seg = $agent->begin_generic_segment($tx, $parent_seg, $name);
Begins a new generic segment. C<$parent_seg> is a parent segment id (C<undef> no parent). C<$name> is a string.
=head2 begin_datastore_segment
my $seg = $agent->begin_datastore_segment($tx, $parent_seg, $table, $operation, $sql, $sql_trace_rollup_name);
Begins a new datastore segment. C<$parent_seg> is a parent segment id (C<undef> no parent).
=head2 begin_external_segment
my $seg = $agent->begin_external_segment($tx, $parent_seg, $host, $name);
Begins a new external segment. C<$parent_seg> is a parent segment id (C<undef> no parent).
=head2 end_segment
my $rc = $agent->end_segment($tx, $seg);
End the given segment.
=head2 get_license_key
my $key = $agent->get_license_key;
Get the license key.
=head2 get_app_name
my $name = $agent->get_app_name;
Get the application name.
=head2 get_app_language
my $lang = $agent->get_app_language;
Get the language name (usually C<perl>).
=head2 get_app_language_version
my $version = $agent->get_app_language_version;
Get the language version.
=head1 CAVEATS
=head2 Platform Limitations
The SDK binaries provided by New Relic only work on Linux x86_64. The binaries are labeled
( run in 1.219 second using v1.01-cache-2.11-cpan-cdf2f3d4e48 )