{"id":9279,"date":"2022-03-15T08:19:55","date_gmt":"2022-03-15T12:19:55","guid":{"rendered":"https:\/\/www.redline13.com\/blog\/?p=9279"},"modified":"2022-05-23T12:58:54","modified_gmt":"2022-05-23T16:58:54","slug":"server-index-is-now-a-jmeter-property","status":"publish","type":"post","link":"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/","title":{"rendered":"Server Index is now a JMeter Property"},"content":{"rendered":"<p><strong><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-9280 aligncenter\" src=\"https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image.png\" width=\"400\" height=\"205\" srcset=\"https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image.png 1311w, https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image-300x154.png 300w, https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image-1024x526.png 1024w, https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image-768x394.png 768w, https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image-425x218.png 425w\" sizes=\"auto, (max-width: 400px) 100vw, 400px\" \/><\/strong><\/p>\n<p><a href=\"https:\/\/jmeter.apache.org\/\">JMeter<\/a> tests running on RedLine13 with multiple load generators have visibility to the server \u201cindex\u201d number as a JMeter property.&nbsp; One of our customers was running large scale load tests across multiple servers.&nbsp; They needed a way to correlate test plans running on individual server machines, something akin to the example described below.&nbsp; Sometimes useful features come from our customers solving real-world issues, and this is an example of one such case.<\/p>\n<p>This property \u2013 <span style=\"color: #993300;\"><strong>rl13_agentindex<\/strong> <\/span>\u2013 joins two other similar properties (<span style=\"color: #993300;\"><strong>rl13_serverid<\/strong><\/span> and <span style=\"color: #993300;\"><strong>rl13_testid<\/strong><\/span>) that RedLine13 exposes. Here is a summary of these properties for reference:<\/p>\n<ul>\n<li><span style=\"color: #993300;\"><strong>rl13_agentindex:<\/strong><\/span>\n<ul>\n<li>Zero-based index of load generator (<em>e.g.<\/em>, \u201c0\u201d, \u201c1\u201d, <em>etc<\/em>.)<\/li>\n<\/ul>\n<\/li>\n<li><span style=\"color: #993300;\"><strong>rl13_serverid:<\/strong><\/span>\n<ul>\n<li>AWS-assigned unique identifier for a load generator instance<\/li>\n<\/ul>\n<\/li>\n<li><span style=\"color: #993300;\"><strong>rl13_testid:<\/strong><\/span>\n<ul>\n<li>The test ID number that is assigned by RedLine13<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p>In order to take advantage of these properties, you may use JMeter property variable notation in your request handlers or within your scripts.&nbsp; The preferred shorthand for this notation is via use of the <strong>__P()<\/strong> function <a href=\"https:\/\/jmeter.apache.org\/usermanual\/functions.html#functions\">covered here in JMeter\u2019s documentation<\/a> and used as follows:<\/p>\n<pre><strong><span style=\"color: #993300;\">${__P(property_name,default_value)}<\/span>\n<\/strong>\n<em>or, if no default value is needed:<\/em>\n\n<span style=\"color: #993300;\"><strong>${__P(property_name)}<\/strong><\/span><\/pre>\n<p>If for instance we wanted to access the <span style=\"color: #993300;\"><strong>rl13_agentindex<\/strong><\/span> property, we could include the expression <span style=\"color: #993300;\"><strong>${__P(rl13_agentindex)}<\/strong><\/span> in an <a href=\"https:\/\/jmeter.apache.org\/usermanual\/component_reference.html#HTTP_Request\">HTTP request sampler<\/a> or any <a href=\"https:\/\/jmeter.apache.org\/usermanual\/component_reference.html#BeanShell_PostProcessor\">BeanShell Post-processor script<\/a>.<\/p>\n<p>One useful case might be to match a specific load generator to a specific request.&nbsp; In the following example we are passing <strong>rl13_agentindex<\/strong> to an API call to be correlated with application logs:<\/p>\n<figure id=\"attachment_9281\" class=\"wp-caption alignnone\" style=\"max-width: 1352px\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-9281\" src=\"https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image-1.png\" alt=\"Passing rl13_agentindex through to an API endpoint.\" width=\"1352\" height=\"569\" srcset=\"https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image-1.png 1352w, https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image-1-300x126.png 300w, https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image-1-1024x431.png 1024w, https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image-1-768x323.png 768w, https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image-1-425x179.png 425w\" sizes=\"auto, (max-width: 1352px) 100vw, 1352px\" \/><figcaption class=\"wp-caption-text\">Passing rl13_agentindex through to an API endpoint.<\/figcaption><\/figure>\n<p>In our JMeter output we find this translates to the following request:<\/p>\n<p><strong><span style=\"color: #993300;\">https:\/\/api.webservice.com\/v1\/widget?item_code=101&amp;request_origin=3<\/span><\/strong><\/p>\n<p>From there we can find \u201c<span style=\"color: #993300;\"><strong>request_origin=3<\/strong><\/span>\u201d in our application logs, and also compare to output files generated for load agent server \u201c<span style=\"color: #993300;\"><strong>3<\/strong><\/span>\u201d:<\/p>\n<figure id=\"attachment_9282\" class=\"wp-caption aligncenter\" style=\"max-width: 750px\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-9282\" src=\"https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image-2.png\" alt=\"server index is now a JMeter property\" width=\"750\" height=\"275\" srcset=\"https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image-2.png 750w, https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image-2-300x110.png 300w, https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image-2-425x156.png 425w\" sizes=\"auto, (max-width: 750px) 100vw, 750px\" \/><figcaption class=\"wp-caption-text\">Output files for load generator server number \u201c3\u201d can be downloaded individually.<\/figcaption><\/figure>\n<p>This can be immensely useful for both troubleshooting a test plan in development, as well as root cause analysis of a problem uncovered as a result of a performance test.<\/p>\n<p>Did you know that RedLine13 offers a full-featured free trial?&nbsp; <a href=\"https:\/\/www.redline13.com\/Service\">Sign up now<\/a> and follow these steps in your first cloud test with us today.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>JMeter tests running on RedLine13 with multiple load generators have visibility to the server \u201cindex\u201d number as a JMeter property.&nbsp; One of our customers was running large scale load tests across multiple servers.&nbsp; They needed a way to correlate test plans running on individual server machines, something akin to the example described below.&nbsp; Sometimes useful features come from our customers solving real-world issues, and this is an example of one such case. This property \u2013 rl13_agentindex<a class=\"more-link\" href=\"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/\">Read More &rarr;<\/a><\/p>\n","protected":false},"author":11,"featured_media":9280,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2,7],"tags":[165,283,318],"class_list":{"0":"entry","1":"post","2":"publish","3":"author-dkoziel","4":"post-9279","6":"format-standard","7":"has-post-thumbnail","8":"category-blog","9":"category-jmeter","10":"post_tag-customer","11":"post_tag-jmeter","12":"post_tag-load-testing"},"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.12 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Server Index is now a JMeter Property - RedLine13<\/title>\n<meta name=\"description\" content=\"JMeter load tests with multiple load generators run on RedLine13 feature server \u201cindex\u201d as a JMeter property.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Server Index is now a JMeter Property - RedLine13\" \/>\n<meta property=\"og:description\" content=\"JMeter load tests with multiple load generators run on RedLine13 feature server \u201cindex\u201d as a JMeter property.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/\" \/>\n<meta property=\"og:site_name\" content=\"RedLine13\" \/>\n<meta property=\"article:published_time\" content=\"2022-03-15T12:19:55+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2022-05-23T16:58:54+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1311\" \/>\n\t<meta property=\"og:image:height\" content=\"673\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"David Koziel\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"David Koziel\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/\"},\"author\":{\"name\":\"David Koziel\",\"@id\":\"https:\/\/www.redline13.com\/blog\/#\/schema\/person\/51d282221e3230ab35f964f98ada9b20\"},\"headline\":\"Server Index is now a JMeter Property\",\"datePublished\":\"2022-03-15T12:19:55+00:00\",\"dateModified\":\"2022-05-23T16:58:54+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/\"},\"wordCount\":384,\"publisher\":{\"@id\":\"https:\/\/www.redline13.com\/blog\/#organization\"},\"keywords\":[\"customer\",\"JMeter\",\"Load Testing\"],\"articleSection\":[\"Blog\",\"JMeter\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/\",\"url\":\"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/\",\"name\":\"Server Index is now a JMeter Property - RedLine13\",\"isPartOf\":{\"@id\":\"https:\/\/www.redline13.com\/blog\/#website\"},\"datePublished\":\"2022-03-15T12:19:55+00:00\",\"dateModified\":\"2022-05-23T16:58:54+00:00\",\"description\":\"JMeter load tests with multiple load generators run on RedLine13 feature server \u201cindex\u201d as a JMeter property.\",\"breadcrumb\":{\"@id\":\"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.redline13.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Server Index is now a JMeter Property\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.redline13.com\/blog\/#website\",\"url\":\"https:\/\/www.redline13.com\/blog\/\",\"name\":\"RedLine13\",\"description\":\"(Almost) Free Load Testing in the Cloud\",\"publisher\":{\"@id\":\"https:\/\/www.redline13.com\/blog\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.redline13.com\/blog\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.redline13.com\/blog\/#organization\",\"name\":\"RedLine13\",\"url\":\"https:\/\/www.redline13.com\/blog\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.redline13.com\/blog\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2013\/06\/cropped-rl13-header-logo.jpg\",\"contentUrl\":\"https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2013\/06\/cropped-rl13-header-logo.jpg\",\"width\":300,\"height\":68,\"caption\":\"RedLine13\"},\"image\":{\"@id\":\"https:\/\/www.redline13.com\/blog\/#\/schema\/logo\/image\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.redline13.com\/blog\/#\/schema\/person\/51d282221e3230ab35f964f98ada9b20\",\"name\":\"David Koziel\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.redline13.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/2babf644e0993fc86893c24d7525f1e3be114a8746c01249797f25587ae1697a?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/2babf644e0993fc86893c24d7525f1e3be114a8746c01249797f25587ae1697a?s=96&d=mm&r=g\",\"caption\":\"David Koziel\"},\"url\":\"https:\/\/www.redline13.com\/blog\/author\/dkoziel\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Server Index is now a JMeter Property - RedLine13","description":"JMeter load tests with multiple load generators run on RedLine13 feature server \u201cindex\u201d as a JMeter property.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/","og_locale":"en_US","og_type":"article","og_title":"Server Index is now a JMeter Property - RedLine13","og_description":"JMeter load tests with multiple load generators run on RedLine13 feature server \u201cindex\u201d as a JMeter property.","og_url":"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/","og_site_name":"RedLine13","article_published_time":"2022-03-15T12:19:55+00:00","article_modified_time":"2022-05-23T16:58:54+00:00","og_image":[{"width":1311,"height":673,"url":"https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2022\/03\/word-image.png","type":"image\/png"}],"author":"David Koziel","twitter_card":"summary_large_image","twitter_misc":{"Written by":"David Koziel","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/#article","isPartOf":{"@id":"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/"},"author":{"name":"David Koziel","@id":"https:\/\/www.redline13.com\/blog\/#\/schema\/person\/51d282221e3230ab35f964f98ada9b20"},"headline":"Server Index is now a JMeter Property","datePublished":"2022-03-15T12:19:55+00:00","dateModified":"2022-05-23T16:58:54+00:00","mainEntityOfPage":{"@id":"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/"},"wordCount":384,"publisher":{"@id":"https:\/\/www.redline13.com\/blog\/#organization"},"keywords":["customer","JMeter","Load Testing"],"articleSection":["Blog","JMeter"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/","url":"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/","name":"Server Index is now a JMeter Property - RedLine13","isPartOf":{"@id":"https:\/\/www.redline13.com\/blog\/#website"},"datePublished":"2022-03-15T12:19:55+00:00","dateModified":"2022-05-23T16:58:54+00:00","description":"JMeter load tests with multiple load generators run on RedLine13 feature server \u201cindex\u201d as a JMeter property.","breadcrumb":{"@id":"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.redline13.com\/blog\/2022\/03\/server-index-is-now-a-jmeter-property\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.redline13.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Server Index is now a JMeter Property"}]},{"@type":"WebSite","@id":"https:\/\/www.redline13.com\/blog\/#website","url":"https:\/\/www.redline13.com\/blog\/","name":"RedLine13","description":"(Almost) Free Load Testing in the Cloud","publisher":{"@id":"https:\/\/www.redline13.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.redline13.com\/blog\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.redline13.com\/blog\/#organization","name":"RedLine13","url":"https:\/\/www.redline13.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.redline13.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2013\/06\/cropped-rl13-header-logo.jpg","contentUrl":"https:\/\/www.redline13.com\/blog\/wp-content\/uploads\/2013\/06\/cropped-rl13-header-logo.jpg","width":300,"height":68,"caption":"RedLine13"},"image":{"@id":"https:\/\/www.redline13.com\/blog\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/www.redline13.com\/blog\/#\/schema\/person\/51d282221e3230ab35f964f98ada9b20","name":"David Koziel","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.redline13.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/2babf644e0993fc86893c24d7525f1e3be114a8746c01249797f25587ae1697a?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/2babf644e0993fc86893c24d7525f1e3be114a8746c01249797f25587ae1697a?s=96&d=mm&r=g","caption":"David Koziel"},"url":"https:\/\/www.redline13.com\/blog\/author\/dkoziel\/"}]}},"_links":{"self":[{"href":"https:\/\/www.redline13.com\/blog\/wp-json\/wp\/v2\/posts\/9279","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.redline13.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.redline13.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.redline13.com\/blog\/wp-json\/wp\/v2\/users\/11"}],"replies":[{"embeddable":true,"href":"https:\/\/www.redline13.com\/blog\/wp-json\/wp\/v2\/comments?post=9279"}],"version-history":[{"count":10,"href":"https:\/\/www.redline13.com\/blog\/wp-json\/wp\/v2\/posts\/9279\/revisions"}],"predecessor-version":[{"id":9299,"href":"https:\/\/www.redline13.com\/blog\/wp-json\/wp\/v2\/posts\/9279\/revisions\/9299"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.redline13.com\/blog\/wp-json\/wp\/v2\/media\/9280"}],"wp:attachment":[{"href":"https:\/\/www.redline13.com\/blog\/wp-json\/wp\/v2\/media?parent=9279"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.redline13.com\/blog\/wp-json\/wp\/v2\/categories?post=9279"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.redline13.com\/blog\/wp-json\/wp\/v2\/tags?post=9279"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}