The purpose of life is not to win. The purpose of life is to grow and to share. When you come to look back on all that you have done in life, you will get more satisfaction from the pleasure you have brought into other people's lives than you will from the times that you outdid and defeated them.

How to freeze Rails to a older version?

Navigate to project directory and issue the below command.

rake rails:freeze:gems VERSION=x.x.x

Send Email with Rails using GMail

Let us use GMail SMTP server for testing.

Step 1:

Please include the below code in environment.rb file under /config folder.

# environment.rb

ActionMailer::Base.delivery_method = :smtp
ActionMailer::Base.default_content_type = "text/html"

ActionMailer::Base.smtp_settings = {
:enable_starttls_auto => true,
:address => "smtp.gmail.com",
:port => "587",
:domain => "localhost",
:authentication => :plain,
:user_name => "google_username",
:password => "google_password",
}

Step 2:

Generate Mailer model using the below command.

ruby script/generate mailer registration

Step 3:

Now your registration.rb model file should like below. Include the method welcome in class Registration.

class Registration < ActionMailer::Base def welcome(name, email) @recipients = "user@host.com" @from = params[:contact][:email] headers "Reply-to" => "#{email}"
@subject = "Welcome to Add Three"
@sent_on = Time.now
@content_type = "text/html"

body[:name] = name
body[:email] = email
end

end

Installing MySQL with Ruby Gem

Most of the official guides would recommend to install MqSQL database as
$gem install mysql

This won't work for sure in Windows platform. First setup your proxy. To know more please visit Rails Sucks. And finally after proxy setting setup issue the below command.

$gem install mysql -- --with-mysql-lib=/usr/local/mysql/lib

DSL for workflow testing

Typically a QA tests the following in a BPM Application Portal.

* Logins into Portal
* Searches for tasks based on some artifact keys.
* Saves/Completes some assigned tasks.
* Creates tasks
* Waits for some tasks.

These are the few of the many items that a tester or a Business Analyst does, not necessarily in the same order except for the first item.

Now the DSL which is to be built abstracts only high level tasks that the user performs and gives the ability to the user to write his own scenario for automated testing.

For example, if the user wants to search a task, create an artifact like Payroll and then complete the task, he would simply write as,

login_into_portal_as_user(prasanna)
tasks[] = search_for_ID(100, ‘Assigned’, ‘Available’)
iterate all tasks
if task is ‘Payroll’
create_HRA (100, current_date, hra_amount, employee_details)
complete.task
end

The above DSL code is very granular, but with further analysis and level of testing required we can build the DSL functions at coarse grained level, which would limit and simplify the number of lines a tester/user have to use to build scenarios.

One of the objectives for building custom DSL is that anybody from non developer community can write test case scenarios making use of DSL. The above mentioned syntaxes are just examples and can be made much simpler or close to readable English.

I believe this can definitely complement performance testing tools as well. The DSL testing code need not be in the above format; even as XML would do and having DSL on top of any other workflow testing tool means that the services alone will be tested for functionality.

But when I thought about DSL for testing my intention was to use it at a UI level which would better comprehend what an actual tester does. Web flow / UI Level automated testing comes with some disadvantages too, due to the fact that DSL objects are highly dependent on HTML source.

DSL’s are evolutionary and the functionality that have to be tested using DSL should be built brick by brick. Dynamic scripting languages are good candidates for building DSL, reason being faster development time opposed to using a high level language. I was looking at Ruby + ‘Watir’ (pronounced as water and is a Ruby gem) for building a DSL with automated UI level test scripts.

Consulting

Solving the Right Problem

Fundamental law of consulting is to be sure that you are solving the right problem. Otherwise, you’re just covering symptoms with a flimsy band-aid that will surely fail—more likely sooner than later. Result: bad reputation of the consultant & the company.

It is a common practice and tempting to conjure up a solution even before the problem is truly understood. Result: a misguided and a potentially failed project. So our responsibility as the service firm should be to identify the problem and define it in meaningful terms.

Set Expectations as clearly as Possible

This is harder than it sounds. Clients are notoriously bad listeners. They want the moon, but they want to pay in loose change. Or sometimes they don’t quite know what they want but they want a super-accurate quote. Your job as a consultant is to explain what you’re going to do and for how much and in what time frame as clearly as you possibly can.

Get a Testimonial or Reference during the Project

You don’t have to wait for the end of the project to ask for a testimonial or reference. Hit when the iron is hot, right up in the middle, when things are going well and you’re getting positive reviews from the client. How do you get a testimonial? You ask. Sounds silly, but unfortunately it’s true.

Client Communication

Managing and communicating actively with clients is critical to success as a consultant. They’ll want updates, status reports, etc. A well-updated client is generally a happier one, even if you’re bringing them bad news, because they’ll feel on top of the situation and more in control.

Networking Within the Organization

It’s is good idea to inculcate yourself as deeply into your client’s organization as possible. Initially it looks like more work. But it helps in situations where your primary contact disappears - maybe they quit, get transferred / promoted, etc. Lots of opportunity is lost by consultants when they’ve only got one contact in an organization & that contact is no longer in a position to hire them.

Document Everything

Written communication protects you in almost every imaginable circumstance. Miscommunications can be minimized and disasters can be contained by documented proof of what’s going on. As well, documentation is a valuable asset for setting clear expectations, defining goals and understanding project scope.

Consultant’s Jargon Generator

"Our holistic approach enables vertical connectivity between the field operations team and the Quality assurance technicians to optimize consumer impact points."

You can hear similar phases very often like the one above. You might be getting surprised how consultants have mastered such a low ratio of meaning to word count. Not only consultants but also business world is equally guilty, including me at times. For those who can't let go, here's a tool just for you: Consultant's Jargon Generator. Use it to spice up your meetings with clients and colleagues, your proposals, or final "deliverables." Find just the right words to describe one of your consulting capabilities or your methodology, or to make a client recommendation. From the table below, choose any word from the left-hand column, then add a word from the middle column plus any word from the final column. Excerpt from this site http://guerrillaconsulting.typepad.com/guerrilla_marketing_for_c/2005/09/consulting_jarg.html

Clients Buy, They're not “Sold”

Don't waste time telling clients how great you are [company’s capability too much]. Get to the heart of the issue they face, and be prepared to prove how you can help them. Don't tell them about the great services you offer, but show them how you can help by suggesting ideas about project objectives, how to organize the project, and how to get it done. You'll sell more work by letting clients buy from you, rather than trying to sell to them.

Consultant Is a Buyer Too

Yes!! They are also buying from the client a set of facts, barriers to completion and definition of success about the project. Get this wrong, and you'll likely end up with an unhappy client and an unprofitable project. Following 3 questions can help you assess if you know enough:

1. Is there consensus among key decision makers that the project scope is well-defined?
2. What level of commitment is the client making to the project?
3. Has success criteria been defined?

A good consulting sales process includes many their qualifying questions, but the three above will get you started.

Sharing Knowledge

Some of the consultants resist sharing their ideas and knowledge [aka intellectual capital] with clients before they're hired to do a project. They fear that clients will take their work and try to complete the project on their own, or worse, give it to another consultant. The world is awash in information and ideas. If you're stingy with yours, it will show. Besides, clients aren't buying your methodology, tools, or your point of view. They're buying your expertise, recommendations, or your perspectives on how to solve a problem.

It's true that clients have been known to hijack information; consultants develop during the sales process so they can try to complete the project without consultants. But that's the exception, not the rule. So being generous with your knowledge, not foolish. Qualify every opportunity before bringing forward your best ideas. But don't hesitate, once you believe you've got a serious opportunity. Consulting is an ideas business. Keeping your best ones locked in your head, or laptop will leave a door open for your competitors to walk through.

Are you listening?

Biggest complaints from the clients as consultants do not listen and are so enamored with their own solutions that they miss the client’s subtle pointers on what they’re really looking for. Result: lack of understanding about the client real needs. Not compatible solution. Before your next client meeting, remind yourself to really listen.

The Myth of Client Pain

There is plenty of information available on net to find a client's "pain". We're advised to ask prospective clients senseless questions like: What keeps you awake at night? What are your pain points? And, if you had a magic wand, what problem would you solve?

Excuse Me !

It reflects 2 fundamental flaws - First, they proclaim that the consultant is fishing for answers, rather than pursuing a substantive discussion. Second, not all clients are looking for "pain" remedies. Maybe they are looking for to improve their operating margins or performance etc.

Mistakes Every Consultant Should Avoid

1. Rely on your pedigree. Academic credentials, brand, or flashy brochure rarely win over a client. They want to know how you work and how you'll fit with their culture.

2. About Asking Questions. Believe me ! It’s very tough. I have learnt it hard ways. Take your time to fully prepare before the meeting. Create ten insightful, open-ended questions that you can't find answers for on the client's Web site.

3. Talk more than you listen. In your first meetings, be sure to give the client plenty of chances to fully describe what needs to be done. Don't even think about selling until you're sure what problem you're trying to solve.

4. Agree to a proposal before qualifying the opportunity. Some clients will ask for a proposal simply to get you out of their office. Don't agree to write a proposal until you're convinced you've got a qualified lead with at least a 40 percent chance of winning the work.

5. Talk about price in the first meeting. Most clients will ask for a price, even if it's just an estimate. Resist the temptation. Politely ask clients to allow you time to absorb the information provided, and set a firm date to get a price back to them.

Think twice before you Answer These Questions

During the sales process with a client, you'll face number of questions about your background, experiences, and project approach. Client is simply trying to decide whether or not to hand you the keys to the project. Mostly you'll handle questions with ease, but seemingly innocent questions can take you to a trip. So try to hold back and think twice while answering the following questions until you're sure you know what you're getting into.

1. How much will the project cost?
2. What is your rate?
3. Will you send us a proposal?
4. How long will the project take to complete?

If you answer these questions eventually without getting a complete flavor of the situation. Result is: potentially unprofitable project or an unhappy client.

So common sense tells you to understand the client's real problem (not just the stated objectives), the complexity of the project, and something about the company's culture, it's tough to say how long it will take to complete a project. Many clients will push you to answer these questions before you should, and you'll be tempted. It's up to you to make clients recognize that it's in their best interests to wait for informed answers. Plus, taking the time to do it right also protects your interests. If the client balks, you should rethink whether or not this is the right client for you.

Your Toughest Competitor

Did you guess! Another Consulting firm ! You are 100% wrong. It is the client who is your toughest competitor. In every opportunity, you have 2 invisible competitors. First is the client who chooses a “do nothing” strategy and abandons the project; Second is the client who decides to do the project without a consultant?

Competing against an undeclared rival is the most complicated selling situation you face because it involves so much uncertainty. You rarely know what will kill the project or what will keep it alive. You also don’t know what will motivate the client’s team to take the project on without you. Your best approach is to explicitly ask the client. You may get a clue about what you’re up against. Suggest innovative ideas on how the client can solve the problem that led to calling a consultant in the first place, and stress your firm’s specific ability to help. If the client decides to go it alone, position yourself for the future. Offer to provide advice, guidance, or assistance during the project if needed. Clients often reverse themselves or change direction in midstream, especially if they encounter roadblocks. When and if they do, you want to be the first one they remember and turn to for help.

Resources:

Resources not limited to: Consulting Academy; Guerilla Consulting & Peak Strategy; Networking with Linkedin peers; IT Governance Insititue; IT World; Consuting Magzine; Secrets of Consulting.

Source: Unknown

I did what I was asked to do

“I did what I was asked to do”. There are quite a few among us who say this after getting poor appraisal ratings or after getting fired. This is not performance. These types of people are the ones who always run near and close to the boss to keep it going. But for organizations when it comes to retain the best, these are the ones who will be weeded out. There is nothing wrong in doing what was asked to do, to retain jobs, but ultimately the best performer is the one who is willing to go the extra mile.

Going for the extra mile is not working hard with extended hours. Employees are paid for 8hrs of work and not for slavery in the name of competitive world.

“A knife which does only one work of cutting needs to be sharpened frequently to work effectively”. Humans being multifaceted, need to work and rest for life not work and work for life. If promotions or growth can’t be fetched by working for 9 hrs a day, then there is some thing wrong in the way work is done or may be someone is not doing work at the right place. Doing that extra work for day and night and for everyday may not actually yield more than what can be collectively achieved by working peacefully everyday.

'either or' using XML Schema

By embedding choice in sequence, 'either or' type can be enforced in XML schema. In the below example, somethingType would allow either foo or bar. Since 'choice' is inside the sequence which can max occur twice, either or is enforced. So foo/bar can appear once or twice or they can both co-exist.

<xsd:complexType name="somethingType">
  <xsd:sequence minOccurs="1" maxOccurs="2">
    <xsd:choice>
      <xsd:element name="foo" type="xsd:string"/>
      <xsd:element name="bar" type="xsd:string"/>
    </xsd:choice>
  </xsd:sequence>
</xsd:complexType>

<?xml version="1.0" encoding="UTF-8"?>
<tns:EitherOr xmlns:tns="http://www.example.org/EitherOr" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.example.org/EitherOr eitheror.xsd ">
  <foo>foo</foo>
  <bar>bar</bar>
</tns:EitherOr>

Who needs BPM?

BPM should be an organization wide initiative not a department specific or systems specific. This should be the real motivation for any company planning to invest in BPMS. All the business processes of the organization have to be discovered/implemented/migrated/automated to BPMS platform. This has to be the end state or at least should be an ideal state for the IT division of a company.

Workflow Systems:

Although BPM systems have its roots with Workflow systems, BPMS is definitely not an extension of a workflow system.
Workflow is no substitute for BPMS and BPM is rather looked at as systems-to-systems technology.
Also workflow is specific to a system/ collection of systems, but does not collectively represent a domain.

EAI/ESB:

With the advent of SOA, I feel the debate of whether we need to use ESB or existing EAI system becomes nullified.
SOA can be implemented either with EAI/ESB or even without these.
In my opinion BPM can be better sold with SOA rather than with ESB. ESB is perceived both as a product and as architecture. Let the customer decide whether he needs an upgrade from EAI to ESB with necessary cost justifications.

BPM complements SOA and vice versa.

XML Parsers

Five types of XML Parsers.

Event based push: SAX, XNI
Event based pull: StAX, XMLPull
Tree: DOM, JDOM , dom4j
Data Binding: JAXB, Castor
Query API: TrAX

Source: http://www.artima.com/intv/xmlapis2.html

Push APIs have a number of advantages. They are very fast. You don't need to read to the end of the document before you start working with the beginning of the document. They use very little memory, because the entire document isn't in memory at once. Instead, you just see sort of a peephole into the document, just the current thing you're looking at. Typically in a push API the work goes into building up some data structure and gradually filling it from the input document until there is enough information there to act on. If you're document is, for example, a collection of articles, a list of records, something for which there are clear chunks in the data and you can process each chunk individually, a push API works very well.

On the other hand, the whole callback interface observer design pattern can be less than ideal for some developers. This brings us to the second major style of XML API, and the newest style: a pull API. A pull API is still streaming, still very fast, still very memory efficient. But instead of the parser being in control, telling the client application when it has some new information, the client application is in control, and it asks the parser to give it the next piece of information when it wants it. But the basic advantages of a pull API are the same as with a push API, except maybe the pull API is little simpler. The implementations of the various pull APIs are not very mature yet. When you actually look at the ones out there—NekoPull, XMLPULL—they have a lot of idiosyncracies both with respect to Java and XML. That's mostly just a function of maturity. There's nothing fundamentally wrong with the idea of a pull API. They're not just fully baked yet. With a little time, in a year or two, I expect pull APIs will be a very popular style of XML parsing.

The third style of XML parsing, and perhaps the most obvious style to most programmers, is a tree-based API. In a tree-based API, an XML document is read by a parser, and the parser constructs an object model, typically around a tree with nodes for elements , attributes, comments, processing instructions, text, and so forth. The entire document is stored in memory. You use the methods of the object to query the document, to navigate the document, to change and modify the document, and so forth. There are more tree-based APIs than any other kind of API: DOM, JDOM, DOM4J, Sparta, ElectricXML, and my own XOM are all tree-based APIs.

The fourth style of API, which is also a fairly recent style, is a data-binding API. It is similar to tree APIs in that the entire document is parsed and an object model is built, but in a data binding API rather than having classes which represent XML concepts, like element and processing instructions, you have classes that represent the concepts the XML represents. So a book element might become a Book object. An employee element might become an Employee object. Typically, some form of schema is compiled to produce these classes automatically. Either a W3C XML schema language schema, a DTD, or a special purpose binding schema written just for that purpose in some special purpose schema language.

And then finally the fifth kind of API is what I would refer to as a query API. These would typically be things like TrAX for transforming with XSLT, or various APIs like Jaxen for searching with XPath. There are no real standards here, but there is some interesting work being done. Generally there the real focus, the real code, goes into the XPath or XSLT query, which we merely call from Java or some other language. It's like using SQL from inside a Java program using JDBC.

BPEL vs XPDL

BPEL:

BPEL is an execution language for Business Process which it achieves via Web service interactions.

Pros:

1. BPEL is powerful since it is based on orchestration mechanism. Since there are lot of WS* specifications, BPEL is tipped to support WS* specs more effectively than XPDL, due to the fact that BPEL itself is based on Web service interactions.
2. Even though XPDL and BPEL are open standards, BPEL is embraced by more vendors, like IBM Websphere Process Server, Oracle BPA, jBPM.
3. BPEL evangelists claim that a BPEL generated by one tool can be executed in any of the process engines. I'm not sure whether this is possible always.

Cons:

1. BPEL spec is too difficult to understand and complicated.
2. The time taken to develop a BPEL process takes more time than BPMN+XPDL process.
3. Not human friendly - however BPEL4People/WS-HumanTask are intended to help BPEL.

BPMN + XPDL:

XPDL schema transforms BPMN representation to process engine executable language.

Pros:

1. BPMN is human readable. Captures, process semantics and graphical details.
2. XPDL is easily extendable. Provides more scope for BPM product vendors since, XPDL is easily extendable to provide proprietary add-ons.
3. Even though not embraced like BPEL, its immensely popular among the best selling BPM products, like Savvion, Aqua Logic, iProcess, Global 360, EMC, Adobe, Cape Vision.

Cons:

1. Vision for support on WS* specs are very poor.
2. XPDL is becoming very product dependent, since product vendors extend it by putting add-ons.

My personal opinion is both XPDL and BPEL are still immature and we have to wait and watch, which among these two become widely adopted. BPEL process getting executed on any process engine is still not a reality. Its like EJB being deployable on any App server promised by J2EE spec, but the reality is lot deviated from the stated premise.

Why BPEL Matters?

Top 5 reasons to choose Rails

I've worked on Rails to a certain extent and my top 5 reasons why I would choose rails to design my next app are,
1. Convention over configuration. This enables to set up the application, database configurations, and MVC stuff literally in minutes.
2. Active Record - Built in ORM. Domain object model can be configured easily and can be translated to Database. In J2EE or .Net this would require a lot of XML configurations and corresponding database mappings.
3. Support for REST (Representational state transfer). Rails have an implicit support for REST unlike J2EE and .Net.
4. Test Unit - Embraces test driven development.
5. Every dependency is a gem - Project related dependencies/libraries can be easily downloaded as gem install XXX.
However, the main criticism for Rails being scalability and non-availability of standard tool-set for development. My bet on Rails would be for trivial applications web apps.

Install SQLite3 for Ruby in Windows

1.  I downloaded sqlite3 dll zip from
http://www.sqlite.org/sqlitedll-3_6_12.zip and unzipped into C:\ruby\bin
and then ran
2.  gem install sqlite3-ruby -v 1.2.3

Rails Sucks

I've just started to learn Ruby on Rails (RoR). Got stuck when downloading rails behind a firewall. I wonder why Rails has poor documentation regarding the download steps.

Finally I manged to download rails by setting the following ENV_VARIABLE in Windows environment.

HTTP_PROXY=http://user:pwd@host:port

Even more disgusting is the fact, that I needed to change my password couple of times, since my credentials had special characters like @, %, !. Obviously, Rails hated this.

Colored????

When I born, I Black,
When I grow up, I Black,
When I go in Sun, I Black,
When I scared, I Black,
When I sick, I Black,
And when I die, I still black.......

And you White fella,
When you born, you Pink,
When you grow up, you White,
When you go in Sun, you Red,
When you cold, you Blue,
When you scared, you Yellow,

When you sick, you Green,
And when you die, you Gray.................
And you calling me Colored ???????????

- A poem by an African.

Best of Quotes


Tough times never last but tough people do.

A leader takes people where they want to go.A great leader takes people where they don't necessarily want to go ,but ought to be.
An attempt may be a failure, but there should not be any failure in making an attempt!
When in doubt, tell the truth. -Mark Twain.
The measure of a man, is not determined at moments of happiness, but at times of controversy and challenge.
The taste of success is savorless without defeat.
It's not where you sit, but what you do. -Presi

Losing is victory postponed
"Kites rise highest against the wind; not with it."
"Twenty years from now you will be more disappointed by the things that you didn't do than by the ones you did do. So throw off the bowlines. Sail away from the safe harbor. Catch the trade winds in your sails. Explore. Dream. Discover."
"Do not go where the path may lead, go instead where there is no path and leave a trail."- Ralph Waldo Emerson
"What lies behind us and what lies before us are tiny matters compared to what lies within us."
"Good judgment comes from experience, and often experience comes from bad judgment".
"Let me win, but if I cannot win, let me be brave in the attempt."
"Courage is what you dare to do in public;
Conscience is what you dare not to do in private"
"The important thing in life is not the victory but the contest; the essential thing is not to have won but to have fought well." -Baron Pierre De Coubertin.
"The best and the most beautiful things in the world cannot be seen or even touched. they must be felt with the heart." - Helen Keller.
"Patience, persistence and perspiration make an unbeatable combination for success."
- Napolean Hill

"Strength does not come from winning. Your struggles develop your strengths. When you go through hardships and decide not to surrender, that is strength."
- Arnold Schwarzenegger

" If a man hasn't discovered yet ,something that he would die for, He isn't fit to live. "
"Walking on water and developing software from a specification are easy if both are frozen."
Fear can hold you prisoner. Hope can set you free. -The Shawshank Redemption

You don't throw away life just because it's a little banged up- Seabiscuit


My favorite quote

"The three hardest tasks in the world are neither physical feats nor intellectual achievements, but moral acts: to return love for hate, to include the excluded, and to say, "I was wrong."

Sydney J. Harris

How to crack the SCDJWS ?..

The wikipedia says SCDJWS is the toughest and the most respected Sun Certification.
http://en.wikipedia.org/wiki/Sun_Certified_Professional#Sun_Certified_Developer_for_Java_Web_Services_.28SCDJWS.29
Very true indeed.

I scored 79% (55/69). Here's the split up.

XML Web Service Standards 80%
SOAP 1.1 Web Service Standards 83%
Describing and Publishing (WSDL and UDDI) 100%
JAX-RPC 85%
SOAP and XML Processing APIs (JAXP, JAXB and SAAJ) 100%
JAXR 75%
J2EE Web Services 71%
Security 75%
Developing Web Services 66%
General Design and Architecture 50%
Endpoint Design and Architecture 80%

Preparation Plan

1. RMH Book for XML Basics, Namespaces, Schemas, SOAP, WSDL
2. Rest of the chapters - MZ notes. - javaboot
3. xyzws.com mock exams

The questions in the real exam were little tough than xyzws mocks. It wasn't that straight forward, but with little thinking it can be answered.

I did practise a little with all the APIs. I hosted a Web Service using JAX-RPC, wrote some schemas and compiled it. I used the tomcat for java web services developer pack.

CSV Parser in Java

public class CSVParser {

public static final String CSV_REGEX_PATTERN = "\"([^\"]+?)\",?([^,]+),?,";
public static final String TSV_REGEX_PATTERN = "\t{1}";
public static Pattern csvRE;
public static Pattern tsvRE;

static {
csvRE = Pattern.compile(CSV_REGEX_PATTERN);
tsvRE = Pattern.compile(TSV_REGEX_PATTERN);
}

private List parse(String line) {

List list = new ArrayList();
Matcher m = csvRE.matcher(line);

// For each field
while (m.find()) {
String match = m.group();
if (match == null)
break;
//this will remove trailing , - comment this out if we dont want that affect
if (match.endsWith(",")) {
match = match.substring(0, match.length() - 1);
}
if (match.startsWith("\"")) {
match = match.substring(1, match.length () - 1);
}
if (match.length() == 0)
match = null;
list.add(match);
}

return list;
}

}

How to configure JMeter for your Web Application ?..

How to start ?..
From intranet network, we need to pass through the proxy, and here is the command to start JMeter via proxy.
Please navigate to the bin of the JMeter root directory and fire the following command
C:\project\jakarta-jmeter-2.2\jakarta-jmeter-2.2\bin>jmeter -H proxy.network.net -P 8080 -u -a
Create a Test Plan
1. The JMeter's left side pane contains a Test Plan and WorkBench Item.
2. Click on Test Plan Item.
3. Type in an appropriate name in the Test Plan name text box.
Add a Thread Group
1. Right click on the Test Plan Item
2. Naviagate to Add menu item.
3. Click on Thread Group
4. Name the thread group appropriately.
5. Enter the number of threads (users), ramp up count and loop count appropriately.
Add a Http Request Defaults
1. Right click on the Thread Group which has been created.
2. Naviagate to Add menu item.
3. Navigate to Config Element menu item.
4. Click on Http Request Defaults
Configure Http Request Defaults
1. Click on Http Request Defaults which has been newly created.
2. Enter the following details.
Name: give one
Server Name or IP: stage.com
Port Number:
Protocol: https
Path: /

Add Http Cookie Manager
1. Right click on the Thread Group which has been created.
2. Naviagate to Add menu item.
3. Navigate to Config Element menu item.
4. Click on Http Cookie Manager
Why do we need this ? - to be updated later
Add a Http Request
1. Right click on the Thread Group which has been created.
2. Naviagate to Add menu item.
3. Navigate to Sampler menu item.
4. Click on Http Request
Configure Http Request
1. Click on the Http Request item which has been created.
2. Enter the following details.
Name: Login
Method: Choose POST
Path: /security.AuthenticationServlet.serv
Follow Redirects: Check it.
3. Click on the Add button, to add request parameters.
Name Value Encode Include Equals
j_username hello_bosss no yes
j_password password yes yes
Add Results
1. Right click on the Thread Group which has been created.
2. Naviagate to Add menu item.
3. Navigate to Listener menu item.
4. Click on View Results Tree
Configure SSL Manager
1. Download the digital certificate.
2. Goto STAGE URL from the browser window.
3 Click on View button, when the security window pops up.
4. Goto Details tab
5. Click on Copy to File .. button.
6. Save the file to disk.
7. Navigate Options Menu in JMeter dialog screen.
8. Click on SSL Manager.
9. Enter the digital certificate file name with the path in the File Name: text box.
10. Click Open button.
11. Click Ok/Cancel if ask for a KeyStore password. The default password is 'changeit'
Run Test
1. Navigate to Run menu.
2. Click on the Start menu item.
3. Click on the View Results Tree which you created to see the results.