private void initialize() {
        frame = new JFrame(String.format("Wisper -- %s", localName));
        frame.getContentPane().setBackground(Color.LIGHT_GRAY);
        frame.getContentPane().setLayout(new BorderLayout(0, 0));

        sendPanel = new JPanel();
        frame.getContentPane().add(sendPanel, BorderLayout.SOUTH);
        sendPanel.setLayout(new BoxLayout(sendPanel, BoxLayout.X_AXIS));
        // sendPanel.setLayout(new GridBagLayout());

        
        sendButton = new JButton("Request");
        sendButton.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                synchronized (lock) {
                	
                    String sendMsg = "this is request msg";
                    //String kind = kindField.getText();
                    String displayMsg = String.format("me: %s\n", sendMsg);
                    textArea.append(displayMsg);
                     // Store it in dialog and send
                    dialogMap.get(currentPartner).append(displayMsg);
                   // mp.multiSend(new TimeStampedMessage(currentPartner, kind, sendMsg, null),currentPartner);
                    mp.requestLock();
                }
            }
        });
        sendPanel.add(sendButton);
        sendPanel.setAutoscrolls(true);
        
        
        releaseButton = new JButton("Release");
        releaseButton.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                synchronized (lock) {
                	if(mp.state != LockState.HELD){
                		String displayMsg = String.format("you are not holding lock, not able to send request\n");
                        textArea.append(displayMsg);
                         // Store it in dialog and send
                        dialogMap.get(currentPartner).append(displayMsg);
                        statusArea.append(displayMsg);
                        // Store it in dialog and send
                      // dialogMap.get(currentPartner).append(displayMsg);
                        return;
                	}
                    String sendMsg = "this is release msg";
                    String displayMsg = String.format("me: %s\n", sendMsg);
                    textArea.append(displayMsg);
                    // Store it in dialog and send
                    dialogMap.get(currentPartner).append(displayMsg);
                   // mp.multiSend(new TimeStampedMessage(currentPartner, kind, sendMsg, null),currentPartner);
                    mp.releaseLock();
                }
            }
        });
        sendPanel.add(releaseButton);
        
        

        hostList = new JList();
        hostList.setValueIsAdjusting(true);
        hostList.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
        hostList.setFont(new Font("Lucida Grande", Font.PLAIN, 14));
        listModel = new DefaultListModel(); 
        for (String value : displayedHostnameList) {
            listModel.addElement(value);
        }

        hostList.setModel(listModel);
        hostList.addListSelectionListener(new ListSelectionListener() {
            @Override
            public void valueChanged(ListSelectionEvent arg0) {
                if (!arg0.getValueIsAdjusting()) {
                    currentPartner = hostnameList1[hostList.getSelectedIndex()];
                    textArea.setText(dialogMap.get(currentPartner).toString());
                    // remove new message notification
                    int pos = hostnameMap.get(currentPartner).intValue();
                    listModel.setElementAt(displayedHostnameList[pos], pos);
                }
            }
        });
        hostList.setSelectedIndex(0);
        currentPartner = hostnameList1[0];

        listPanel = new JScrollPane();
        listPanel.setPreferredSize(new Dimension(150, 200));
        listPanel.setViewportView(hostList);

        textArea = new JTextArea();
        statusArea = new JTextArea();
        statusArea.setText("Status: ");

        textPanel = new JScrollPane();
        statusPanel = new JScrollPane();
        frame.getContentPane().add(textPanel, BorderLayout.CENTER);
        textPanel.setViewportView(textArea);
        //frame.getContentPane().add(statusPanel, BorderLayout.CENTER);
        sendPanel.add(statusArea);
        //textPanel.setViewportView(statusArea);
        lblHosts = new JLabel("Groups");
        lblHosts.setFont(new Font("Lucida Grande", Font.PLAIN, 14));
        lblHosts.setAlignmentX(Component.CENTER_ALIGNMENT);
        lblHosts.setAlignmentY(Component.BOTTOM_ALIGNMENT);

        hostPanel = new JPanel();
        hostPanel.setBackground(SystemColor.text);
        frame.getContentPane().add(hostPanel, BorderLayout.WEST);
        hostPanel.setLayout(new BoxLayout(hostPanel, BoxLayout.Y_AXIS));
        hostPanel.add(lblHosts);

        hostPanel.add(listPanel);
        // textPanel.setViewportView(textArea);

        frame.setBackground(Color.LIGHT_GRAY);
        frame.setBounds(100, 100, 520, 445);
        frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    }