Monday, July 22, 2013

How to get rid of Question Mark icons in Ubuntu Unity Launcher


This is an annoying problem we sometimes face with certain applications in Ubuntu. But the solution is very simple. For the convenience, let's go step by step. (I'm facing this problem for IntelliJ IDEA.) 

Step 1:

We have to create a Desktop Entry File (with .desktop extention) in ~/.local/share/applications. Desktop Entry File is a configuration file describing how a particular program is to be launched, how it appears in menus, etc. 

I'm creating jetbrains-idea.desktop file.

vi ~/.local/share/applications/jetbrains-idea.desktop 

Step 2:

Add following text to the file and save it.

Sunday, July 14, 2013

How to enable http level request/response logs for WSO2AS [With Tomcat 7]

 



To enable http level request/response logs in WSO2AS, we can use Access_Log_Valve [1] which is provided in Tomcat 7.


To enable logging, you have to put following xml element under  /Server/Service/Engine/Host/ element in  {WSO2AS_HOME}/repository/conf/tomcat/catalina-server.xml, and restart the AS server.


This will create a log file named “localhost_access_log_sample.{DATE}.log” inside {WSO2AS_HOME}/repository/logs directory.


Here, ‘pattern’ parameter is the one we can use to specify which parts of the request/response needs to be logged. In above sample, xxx stands for the header name we need to log. Here  %{xxx}i stands for request headers and  %{xxx}o for response headers.