First I will introduce my web application. It is just a simple login form which is consist of username and password.Run JMeter , first create a thread group. We will add requests,cookie manager and regular expression extractor into the thread group.First retrieve the login form so we can get jsessionid and javax.faces.ViewState input.
As you can see I defined servername, serverport and address of page.Then we will add cookie manger for jsessionid.
Cookie Manager is added and rfc2109 is selected as a cookie policy.Now we have to add regular expression extractor for javax.view.state parameter.If you don't retrieve this value and post it , your action will be failed.
Now we have to post username , password and some jsf specific data .It is similar to the first request. Parameter names should be encoded.
Thank you so much! you saved my day :)
YanıtlaSil