How to extract Cookie Data from Jmeter Request 119 more words
Tags » JMeter
Here is a Beanshell script that will add a cookie to the cookies sent in every HTTP request.
import org.apache.jmeter.protocol.http.control.Cookie; // Retrieve the cookie value from a JMeter variable called "myCookieValue" String cookieValue = vars.get("myCookieValue"); // Create a new Cookie and add it to the cookie manager Cookie cookie = new Cookie("cookieName", cookieValue , "localhost", "/", false, -1); ctx.getCurrentSampler().getCookieManager().add(cookie); log.info("Cookie added: "+cookie); … 13 more words
One of the challenges I faced recently was the ability to autoscale my containers on my Kubernetes cluster. I realised I had not written yet about this concept and thought I would share how this can be done and what the pitfalls there were for me. 964 more words