Hi,
Here is a very interesting thing we are going to see…Monitoring the Payload of HttpSession created by the Application On the Server…This is very helpful to check whether the HttpSession Attributes are Serializable or not…Because In AdminConsole you can see the Payload (Size of HttpSession) If it is NEGATIVE value means your HttpSession contains some Non Serializable contents…Hence your Application is not good enough to be deployed on a Clustered Environment..
Step1). First Of all Login to Admin Console and then Create a Diagnostic Module…
AdminConsole—Diagnostics—>Diagnostics Modules
Create a Diagnostic Module
Example:
Name: “Module-0” Save (LocK & Edit)
AdminConsole—Diagnostics—>Diagnostics Modules—>Module-0
Enabled: True (Check the CheckBox)
Targets: AdminServer (U can choose your own Target Server)
you can see the following entry in your “config.xml”
C:bea103user_projectsdomains7001_Domainconfigconfig.xml sinppet
<wldf-system-resource> <name>Module-0</name> <target>AdminServer</target> <descriptor-file-name>diagnostics/Module-0-3905.xml</descriptor-file-name> <description></description> </wldf-system-resource>
C:bea103user_projectsdomains7001_DomainconfigdiagnosticsModule-0-3905.xml
<?xml version='1.0' encoding='UTF-8'?> <wldf-resource xmlns="http://www.bea.com/ns/weblogic/weblogic-diagnostics" xmlns:sec="http://www.bea.com/ns/weblogic/90/security" xmlns:wls="http://www.bea.com/ns/weblogic/90/security/wls" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.bea.com/ns/weblogic/weblogic-diagnostics http://www.bea.com/ns/weblogic/weblogic-diagnostics/1.1/weblogic-diagnostics.xsd"> <name>Module-0</name> <instrumentation> <enabled>true</enabled> </instrumentation> </wldf-resource>
Step2). Now develop an EAR application and place the “weblogic-diagnostics.xml” file in the META-INF directory of EAR And “MyDiagnosticTestEAR/META-INF/weblogic-diagnostics.xml”
<?xml version="1.0" encoding="UTF-8"?> <wldf-resource xmlns="http://www.bea.com/ns/weblogic/90/diagnostics"> <instrumentation> <enabled>true</enabled> <wldf-instrumentation-monitor> <name>HttpSessionDebug</name> <enabled>true</enabled> </wldf-instrumentation-monitor> </instrumentation> </wldf-resource>
NOTE: After Creating the Diagnostic Module in AdminConsole Please restart The Server where it is targeted…
Step3). Inside the EAR Place any WEB Application where you set some data inside the HttpSession …Like:
<%@ page language="java" contentType="text/html;charset=UTF-8"%> <html> <body> <% session.setAttribute("AAAAAAAAA","BBBBBBBBBBBBBB"); session.setAttribute("CCCCCCCCC","DDDDDDDDDDDDDDDDDDDDDDDD"); %> <BR>Data is set inside the Session:<BR> <h4>session.setAttribute("AAAAAAAAA","BBBBBBBBBBBBBB"); <h4>session.setAttribute("CCCCCCCCC","DDDDDDDDDDDDDDDDDDDDDDDD"); </body> </html>
January 26th, 2010 on 5:56 pm
Hi ,
Your postings are verymuch helpfull to me.
Congrats for all of your hardwork …
thanx.
Seshadri
December 22nd, 2010 on 12:16 am
Jay,
For my web application. I have created the file weblogic-diagnostics.xml in META-INF of webapplication. This work fine and i am able to see the table EventsDataArchive.
I have some questions and need your help to understand them
1) What we are trying to achieve by doing this. How this will help in our debugging
2) What payload indicate.
3) What is mean by size of http session.
Thanks
Sumit
December 22nd, 2010 on 10:16 pm
Hi Sumit,
EventDataArchieve in above case will help us in investigating and especially debugging different HttpSession related Issues. It tells us What Kind of Payload the Session is carrying. What is the Size of each and Every Session Object…which helps us to understand the Load on Session Replication. Many times it happens that an Application puts a very large amount of data dynamically inside the HttpSession which causes many issues sometimes SessionReplication related issue as well..so enabling EventDataArchieve helps us to debug those kind of issues.
.
.
Keep Posting 🙂
Thanks
Jay SenSharma
July 14th, 2013 on 12:21 pm
Hi,
I tried the above process but didn’t worked for me.
Just want to know that weblogic-diagnostics.xml is to be added in fusion project or portal project?
is there any alternative process?