Speeding up jsp
Speeding up jsp
Posted: Aug 4, 2004 1:07 PM Reply
Hello, I'd like to know about ways to speed up a java application.
We're using jsp java beans on a webserver running Apache/Tomcat 4.1.18.
It's accessing database information through ODBC from a Microsoft SQL Server
version 8.0 database across a network. We're encountering some problems
with one jsp page because I think it's retrieving many result sets from
the database. The queries in question select from several lookup tables and out.prinln the results
to several select html tags. We're using JDBC, and limiting our select to the minimum numer of database
columns.
Any recommendations about speeding up the specific problem with this jsp
page, or any general suggestions on performance improvements would be
welcome.
Mike
As said, the database should do as much as possible, including caching of the query results.
If the database and the web server are separated by a network, and there is latency in this connection, then you should also avoid roundtrips.
You could consider for each page having just one roundtrip by having the database server provide the data, not as separate query results, but as single documents or data structures.
That is, you could implement a web-service interface or an enterprise java beans interface as the point of access to your data. The web layer would then call remote functions and get the necessary data structures for each view.
But this would be a misuse of web-services and EJB because you would be mixing the presentaion logic with the business logic. You would have half of the presentation layer "remoted" (bad, and difficult to maintain).
So, even if there are slowness problems, I think you should try to isolate the presentation layer as much as possible, even if it involves many roundtrips. So, investigate the follwing possibilities:
1. Optimizing the SQL code.
2. Network issues: where is it taking the time?
Similar Messages
-
Novice Programmer Needs To Learn JSP
Hi All,
I am an experienced HTML programmer and my current employer would like me to learn JSP, JavaScript, and Java. They would prefer I learn JSP first.
I have no programming experience beyond HTML. What is the best way for me to learn JSP? Can I learn through books or will I need to take a class?
I appreciate any and all advice.
- RobMaybe someone else will disagree with me, but from my experience your management does not have a clue.
JSPs may look like more fancy HTML pages, but in fact the use of them by an application server (such as Tomcat) causes them to be translated into Java code and they become servlets. So, you cannot do serious JSP work without being aware of what is going on in wrinting Java Servlets.
JavaScript, although the name starts with "Java" is a distinct language, used pretty much only in browsers as a way to have smarter action implemented in the browser. JavaScript shares a tantalizing amount of Java's syntax, but they are different.
For example, if we consider a form to be used by someone to prepare information to send to a web site, with JavaScript, you can do validation before the data is sent to the server and put up a message to the user with no network traffic required. With logic only in Java code on the server, you will need to send the data to the server to do validation, and then send back a rejection notice asking for the user to recreate the information.
The ugly truth (in my opinion) is that to be a good writer of Java-ish things to be shown in a browser, you need to know HTML, JavaScript, Java, and Java Servlets. (Pretty soon you will need to deal with database stuff.)
JSPs can make some tasks easier, but you need to know what is really going on or you can make errors at a high rate of speed.
JSPs are not required. You could write code on the server to create a stream of html output that is a combination of standard blocks of html code and content from other sources (usually databases). With JSPs however, you can write blocks of html and java code and the process of compiling a JSP turns it into Java code that generates the stream of html output wiith intermixed data. It is easier to do maintenance on a JSP than on a plain servlet.
For example, if you are doing a page that is a "shopping cart" for an e-commerce site, you can have the standard html lines to create the <table> and header rows. Then, you switch into Java, get the data, and loop through the entries. For each item in the list of contents you output a row of the html table. When you are through looping through the data, you exit the java code and have a plain old html ending of the table.
Does this help?
Dave Patterson -
Hello,
We are in the process of upgrading iPlanet 4.1 to 6.1Sp2. We have made enhancements to our code to support this effort, ie making our session bean serializable, adding the context dir in jsp to jsp calls.
Right now we are noticing slow rendering speed for jsp pages compared to iPlanet 4.1. It seems the page loads to a certain point, there is about 2-4 second delay before the page completes loading.
I've activated the monitor for performance statistics.
Here is the perf dump.
webservd pid: 8109
Sun ONE Web Server 6.1SP2 B04/07/2004 16:09 (SunOS DOMESTIC)
Server started Tue Jul 13 10:33:08 2004
Process 8109 started Tue Jul 13 10:33:08 2004
ConnectionQueue:
Current/Peak/Limit Queue Length 0/1/4096
Total Connections Queued 11
Average Queue Length (1, 5, 15 minutes) 0.00, 0.00, 0.00
Average Queueing Delay 0.15 milliseconds
ListenSocket group1:
Address http://10.201.1.53:80
Acceptor Threads 1
Default Virtual Server https-infa.net
KeepAliveInfo:
KeepAliveCount 2/256
KeepAliveHits 44
KeepAliveFlushes 0
KeepAliveRefusals 0
KeepAliveTimeouts 8
KeepAliveTimeout 30 seconds
SessionCreationInfo:
Active Sessions 2
Keep-Alive Sessions 0
Total Sessions Created 48/256
CacheInfo:
enabled yes
CacheEntries 27/1024
Hit Ratio 82/140 ( 58.57%)
Maximum Age 30
Native pools:
NativePool:
Idle/Peak/Limit 1/1/128
Work Queue Length/Peak/Limit 0/0/0
Server DNS cache disabled
Async DNS disabled
Performance Counters:
Average Total Percent
Total number of requests: 57
Request processing time: 1.2522 71.3780
default-bucket (Default bucket)
Number of Requests: 57 (100.00%)
Number of Invocations: 866 (100.00%)
Latency: 0.0003 0.0174 ( 0.02%)
Function Processing Time: 1.2519 71.3606 ( 99.98%)
Total Response Time: 1.2522 71.3780 (100.00%)
Sessions:
Process Status Function
8109 response service-dump
response service-j2eeHere is a sample of jsp that renders partially. Each page renders to the same spot for that page, then there is a 5-10 second delay before the page finishes.
<-- Partial Page rendered -->
<HTML>
<HEAD>
<TITLE> FAST : Health Check</TITLE>
<link rel="stylesheet" type="text/css" href="/styles/table.css">
<script>
<!--
if (top.location != location) top.location.href = location.href;
//-->
</script>
</HEAD>
<BODY BACKGROUND="/graphics/BACK25.jpg" BGPROPERTIES="FIXED">
<SCRIPT>
var menuBarOption = "";
</SCRIPT>
<SCRIPT>
<!-- Begin
var activeColor = "#COCOCO";
var inActiveColor = "#000066";
var whatColor = "#000066";
var fontColor = "#COCOCO";
document.write('<TABLE BORDER="0" CELLSPACING="0" CELLPADDING="0" WIDTH="780" height="80">');
document.write('<TR>');
document.write('<TD ALIGN="right" width="300" rowspan="2" bgcolor="#FFFFFF" valign="bottom"><a href="/"><img border="0" src="/graphics/infaheadbig2.jpg" align="absbottom" width="300" height="80"></a>');
document.write('</TD>');
document.write('<TD ALIGN="right" valign="bottom" bgcolor="#FFFFFF">');
document.write('<table border="0" cellspacing="0" cellpadding="2" valign="bottom">');
document.write(' <tr>');
document.write('<td align="center">');
document.write('<font face="Arial" size="1" color="#FFFFFF"><a target="_blank" href="http://www.forwardair.com" style="color: red">www.ForwardAir.com</a> </font><b><font size="3" color="#D3D0D5" face="Verdana"> | </font></b>');
document.write('<font face="Arial" size="1" color="#FFFFFF"><a href="/" style="color: #000066">Home</a> </font><b><font size="3" color="#D3D0D5" face="Verdana"> | </font></b>');
document.write('<font face="Arial" size="1" color="#FFFFFF"><a href="/servlet/salesCRM/logon.jsp" style="color: #000066">Sales & Marketing</a> </font><b><font size="3" color="#D3D0D5" face="Verdana"> | </font></b>');
document.write('<font face="Arial" size="1" color="#FFFFFF"><a href="/servlet/operations/logon.jsp" style="color: #000066">Operations</a> </font><b><font size="3" color="#D3D0D5" face="Verdana"> | </font></b>');
document.write('<font face="Arial" size="1" color="#FFFFFF"><a href="/servlet/corporate/login.jsp" style="color: #000066">Corporate</a> </font><b><font size="3" color="#D3D0D5" face="Verdana"> | </font></b>');
document.write('<font face="Arial" size="1" color="#FFFFFF"><a href="/fast/fast.htm" style="color: #000066">FAST</a></font>');
document.write('</td>');
document.write(' </tr>');
document.write('</table>');
document.write('</TD>');
document.write('</TR>');
document.write('<TR>');
document.write('<TD ALIGN="left" bgColor="#FFFFFF" valign="bottom">');
document.write('<table border="0" cellspacing="1" width="100%">');
document.write('<tr>');
whatColor = inActiveColor;
fontColor = activeColor;
if (menuBarOption == "AIRBILLS") {
whatColor = activeColor;
fontColor = inActiveColor;
document.write('<td align="center" bgcolor="' + whatColor + '" valign="top" width="70"><font face="Arial" size="1" color="' + fontColor + '">Airbills<br>');
document.write('<a href="/servlet/airbills/fatnt.jsp">');
document.write('<img border="0" src="/graphics/boxicon.gif" width="32" height="32"></a></font></td>');
whatColor = inActiveColor;
fontColor = activeColor;
if (menuBarOption == "EMPLOYEES") {
whatColor = activeColor;
fontColor = inActiveColor;
document.write('<td align="center" bgcolor="' + whatColor + '" valign="top" width="70"><font face="Arial" size="1" color="' + fontColor + '">Directory<br>');
document.write('<a href="/directory.htm">');
document.write('<img border="0" src="/graphics/peopleicon.gif" width="32" height="32"></a></font></td>');
whatColor = inActiveColor;
fontColor = activeColor;
if (menuBarOption == "BENEFITS") {
whatColor = activeColor;
fontColor = inActiveColor;
document.write('<td align="center" bgcolor="' + whatColor + '" valign="top" width="70"><font face="Arial" size="1" color="' + fontColor + '">Benefits<br>');
document.write('<a href="/employees/benefits.htm">');
document.write('<img border="0" src="/graphics/moneyicon.gif" width="32" height="32"></a></font></td>');
whatColor = inActiveColor;
fontColor = activeColor;
if (menuBarOption == "FORMS") {
whatColor = activeColor;
fontColor = inActiveColor;
document.write('<td align="center" bgcolor="' + whatColor + '" valign="top" width="70"><font face="Arial" size="1" color="' + fontColor + '">Forms<br>');
document.write('<a href="/forms.htm">');
document.write('<img border="0" src="/graphics/formicon2.gif" width="32" height="32"></a></font></td>');
whatColor = inActiveColor;
fontColor = activeColor;
if (menuBarOption == "NEWS") {
whatColor = activeColor;
fontColor = inActiveColor;
document.write('<td align="center" bgcolor="' + whatColor + '" valign="top" width="70"><font face="Arial" size="1" color="' + fontColor + '">News<br>');
document.write('<a href="/news.htm">');
document.write('<img border="0" src="/graphics/newsicon.gif" width="32" height="32"></a></font></td>');
whatColor = inActiveColor;
fontColor = activeColor;
if (menuBarOption == "TOOLS") {
whatColor = activeColor;
fontColor = inActiveColor;
document.write('<td align="center" bgcolor="' + whatColor + '" valign="top" width="70"><font face="Arial" size="1" color="' + fontColor + '">Tools<br>');
document.write('<a href="/tools.htm">');
document.write('<img border="0" src="/graphics/toolsicon.gif" width="32" height="32"></a></font></td>');
whatColor = inActiveColor;
fontColor = activeColor;
if (menuBarOption == "SEARCH") {
whatColor = activeColor;
fontColor = inActiveColor;
document.write('<td align="center" bgcolor="' + whatColor + '" valign="top" width="70"><font face="Arial" size="1" color="' + fontColor + '">Search<br>');
document.write('<a href="/search.htm">');
document.write('<img border="0" src="/graphics/magglassicon.gif" width="32" height="32"></a></font></td>');
document.write('</TR>');
document.write('</TABLE>');
document.write('</TD>');
document.write('</TABLE>');
// End -->
</SCRIPT>
<TABLE BORDER=0 CELLPADDING=0 CELLSPACING=0>
<TR>
<TD width="85" height="600" bgcolor="#000066" VALIGN="TOP">
<BR>
<SCRIPT>
var publicSCRMOption = "PROCESSES";
</SCRIPT>
<TABLE BORDER="0" CELLSPACING="0" CELLPADDING="0" ALIGN="LEFT">
<TR><TD height="15" NOWRAP>
<FONT SIZE="-2" FACE="verdana, arial, helvetica" COLOR="#FFFFFF">
<STRONG> FAST Menu </STRONG></FONT>
</TD></TR>
<TR><TD height="15" NOWRAP>
<SCRIPT>
if (publicSCRMOption == "WEBTRENDS")
document.write(' <img border="0" src="/salesCRM/graphics/rarrow.gif" width="8" height="12">');
else
document.write(' ');
</SCRIPT>
<A HREF="/fast/fast.htm"><FONT SIZE="-2" FACE="verdana, arial, helvetica" COLOR="#FFCC66">
<SPAN STYLE="{text-decoration:none}"><STRONG> WebTrends</STRONG></SPAN></FONT></A>
</TD></TR>
<TR><TD height="15" NOWRAP>
<SCRIPT>
if (publicSCRMOption == "PREMIER")
document.write(' <img border="0" src="/salesCRM/graphics/rarrow.gif" width="8" height="12">');
else
document.write(' ');
</SCRIPT>
<A HREF="/servlet/fast/premierLogin.jsp"><FONT SIZE="-2" FACE="verdana, arial, helvetica" COLOR="#FFCC66">
<SPAN STYLE="{text-decoration:none}"><STRONG> Premier</STRONG></SPAN></FONT></A>
</TD></TR>
<TR><TD height="15" NOWRAP>
<SCRIPT>
if (publicSCRMOption == "PROCESSES")
document.write(' <img border="0" src="/salesCRM/graphics/rarrow.gif" width="8" height="12">');
else
document.write(' ');
</SCRIPT>
<A HREF="/servlet/faf.unix.servlet.GetHealthCheckServlet"><FONT SIZE="-2" FACE="verdana, arial, helvetica" COLOR="#FFCC66">
<SPAN STYLE="{text-decoration:none}"><STRONG> Processes</STRONG></SPAN></FONT></A>
</TD></TR>
<TR><TD height="15" NOWRAP>
<SCRIPT>
if (publicSCRMOption == "EDISTATUS")
document.write(' <img border="0" src="/salesCRM/graphics/rarrow.gif" width="8" height="12">');
else
document.write(' ');
</SCRIPT>
<A HREF="/servlet/faf.unix.servlet.GetEDIStatusServlet"><FONT SIZE="-2" FACE="verdana, arial, helvetica" COLOR="#FFCC66">
<SPAN STYLE="{text-decoration:none}"><STRONG> EDI</STRONG></SPAN></FONT></A>
</TD></TR>
<TR><TD height="15" NOWRAP>
<SCRIPT>
if (publicSCRMOption == "SANIT<--- End of Partial Page --->
This is the complete page which take about 5-10 seconds
<--- Beginning of Completed Page --->
<HTML>
<HEAD>
<TITLE> FAST : Health Check</TITLE>
<link rel="stylesheet" type="text/css" href="/styles/table.css">
<script>
<!--
if (top.location != location) top.location.href = location.href;
//-->
</script>
</HEAD>
<BODY BACKGROUND="/graphics/BACK25.jpg" BGPROPERTIES="FIXED">
<SCRIPT>
var menuBarOption = "";
</SCRIPT>
<SCRIPT>
<!-- Begin
var activeColor = "#COCOCO";
var inActiveColor = "#000066";
var whatColor = "#000066";
var fontColor = "#COCOCO";
document.write('<TABLE BORDER="0" CELLSPACING="0" CELLPADDING="0" WIDTH="780" height="80">');
document.write('<TR>');
document.write('<TD ALIGN="right" width="300" rowspan="2" bgcolor="#FFFFFF" valign="bottom"><a href="/"><img border="0" src="/graphics/infaheadbig2.jpg" align="absbottom" width="300" height="80"></a>');
document.write('</TD>');
document.write('<TD ALIGN="right" valign="bottom" bgcolor="#FFFFFF">');
document.write('<table border="0" cellspacing="0" cellpadding="2" valign="bottom">');
document.write(' <tr>');
document.write('<td align="center">');
document.write('<font face="Arial" size="1" color="#FFFFFF"><a target="_blank" href="http://www.forwardair.com" style="color: red">www.ForwardAir.com</a> </font><b><font size="3" color="#D3D0D5" face="Verdana"> | </font></b>');
document.write('<font face="Arial" size="1" color="#FFFFFF"><a href="/" style="color: #000066">Home</a> </font><b><font size="3" color="#D3D0D5" face="Verdana"> | </font></b>');
document.write('<font face="Arial" size="1" color="#FFFFFF"><a href="/servlet/salesCRM/logon.jsp" style="color: #000066">Sales & Marketing</a> </font><b><font size="3" color="#D3D0D5" face="Verdana"> | </font></b>');
document.write('<font face="Arial" size="1" color="#FFFFFF"><a href="/servlet/operations/logon.jsp" style="color: #000066">Operations</a> </font><b><font size="3" color="#D3D0D5" face="Verdana"> | </font></b>');
document.write('<font face="Arial" size="1" color="#FFFFFF"><a href="/servlet/corporate/login.jsp" style="color: #000066">Corporate</a> </font><b><font size="3" color="#D3D0D5" face="Verdana"> | </font></b>');
document.write('<font face="Arial" size="1" color="#FFFFFF"><a href="/fast/fast.htm" style="color: #000066">FAST</a></font>');
document.write('</td>');
document.write(' </tr>');
document.write('</table>');
document.write('</TD>');
document.write('</TR>');
document.write('<TR>');
document.write('<TD ALIGN="left" bgColor="#FFFFFF" valign="bottom">');
document.write('<table border="0" cellspacing="1" width="100%">');
document.write('<tr>');
whatColor = inActiveColor;
fontColor = activeColor;
if (menuBarOption == "AIRBILLS") {
whatColor = activeColor;
fontColor = inActiveColor;
document.write('<td align="center" bgcolor="' + whatColor + '" valign="top" width="70"><font face="Arial" size="1" color="' + fontColor + '">Airbills<br>');
document.write('<a href="/servlet/airbills/fatnt.jsp">');
document.write('<img border="0" src="/graphics/boxicon.gif" width="32" height="32"></a></font></td>');
whatColor = inActiveColor;
fontColor = activeColor;
if (menuBarOption == "EMPLOYEES") {
whatColor = activeColor;
fontColor = inActiveColor;
document.write('<td align="center" bgcolor="' + whatColor + '" valign="top" width="70"><font face="Arial" size="1" color="' + fontColor + '">Directory<br>');
document.write('<a href="/directory.htm">');
document.write('<img border="0" src="/graphics/peopleicon.gif" width="32" height="32"></a></font></td>');
whatColor = inActiveColor;
fontColor = activeColor;
if (menuBarOption == "BENEFITS") {
whatColor = activeColor;
fontColor = inActiveColor;
document.write('<td align="center" bgcolor="' + whatColor + '" valign="top" width="70"><font face="Arial" size="1" color="' + fontColor + '">Benefits<br>');
document.write('<a href="/employees/benefits.htm">');
document.write('<img border="0" src="/graphics/moneyicon.gif" width="32" height="32"></a></font></td>');
whatColor = inActiveColor;
fontColor = activeColor;
if (menuBarOption == "FORMS") {
whatColor = activeColor;
fontColor = inActiveColor;
document.write('<td align="center" bgcolor="' + whatColor + '" valign="top" width="70"><font face="Arial" size="1" color="' + fontColor + '">Forms<br>');
document.write('<a href="/forms.htm">');
document.write('<img border="0" src="/graphics/formicon2.gif" width="32" height="32"></a></font></td>');
whatColor = inActiveColor;
fontColor = activeColor;
if (menuBarOption == "NEWS") {
whatColor = activeColor;
fontColor = inActiveColor;
document.write('<td align="center" bgcolor="' + whatColor + '" valign="top" width="70"><font face="Arial" size="1" color="' + fontColor + '">News<br>');
document.write('<a href="/news.htm">');
document.write('<img border="0" src="/graphics/newsicon.gif" width="32" height="32"></a></font></td>');
whatColor = inActiveColor;
fontColor = activeColor;
if (menuBarOption == "TOOLS") {
whatColor = activeColor;
fontColor = inActiveColor;
document.write('<td align="center" bgcolor="' + whatColor + '" valign="top" width="70"><font face="Arial" size="1" color="' + fontColor + '">Tools<br>');
document.write('<a href="/tools.htm">');
document.write('<img border="0" src="/graphics/toolsicon.gif" width="32" height="32"></a></font></td>');
whatColor = inActiveColor;
fontColor = activeColor;
if (menuBarOption == "SEARCH") {
whatColor = activeColor;
fontColor = inActiveColor;
document.write('<td align="center" bgcolor="' + whatColor + '" valign="top" width="70"><font face="Arial" size="1" color="' + fontColor + '">Search<br>');
document.write('<a href="/search.htm">');
document.write('<img border="0" src="/graphics/magglassicon.gif" width="32" height="32"></a></font></td>');
document.write('</TR>');
document.write('</TABLE>');
document.write('</TD>');
document.write('</TABLE>');
// End -->
</SCRIPT>
<TABLE BORDER=0 CELLPADDING=0 CELLSPACING=0>
<TR>
<TD width="85" height="600" bgcolor="#000066" VALIGN="TOP">
<BR>
<SCRIPT>
var publicSCRMOption = "PROCESSES";
</SCRIPT>
<TABLE BORDER="0" CELLSPACING="0" CELLPADDING="0" ALIGN="LEFT">
<TR><TD height="15" NOWRAP>
<FONT SIZE="-2" FACE="verdana, arial, helvetica" COLOR="#FFFFFF">
<STRONG> FAST Menu </STRONG></FONT>
</TD></TR>
<TR><TD height="15" NOWRAP>
<SCRIPT>
if (publicSCRMOption == "WEBTRENDS")
document.write(' <img border="0" src="/salesCRM/graphics/rarrow.gif" width="8" height="12">');
else
document.write(' ');
</SCRIPT>
<A HREF="/fast/fast.htm"><FONT SIZE="-2" FACE="verdana, arial, helvetica" COLOR="#FFCC66">
<SPAN STYLE="{text-decoration:none}"><STRONG> WebTrends</STRONG></SPAN></FONT></A>
</TD></TR>
<TR><TD height="15" NOWRAP>
<SCRIPT>
if (publicSCRMOption == "PREMIER")
document.write(' <img border="0" src="/salesCRM/graphics/rarrow.gif" width="8" height="12">');
else
document.write(' ');
</SCRIPT>
<A HREF="/servlet/fast/premierLogin.jsp"><FONT SIZE="-2" FACE="verdana, arial, helvetica" COLOR="#FFCC66">
<SPAN STYLE="{text-decoration:none}"><STRONG> Premier</STRONG></SPAN></FONT></A>
</TD></TR>
<TR><TD height="15" NOWRAP>
<SCRIPT>
if (publicSCRMOption == "PROCESSES")
document.write(' <img border="0" src="/salesCRM/graphics/rarrow.gif" width="8" height="12">');
else
document.write(' ');
</SCRIPT>
<A HREF="/servlet/faf.unix.servlet.GetHealthCheckServlet"><FONT SIZE="-2" FACE="verdana, arial, helvetica" COLOR="#FFCC66">
<SPAN STYLE="{text-decoration:none}"><STRONG> Processes</STRONG></SPAN></FONT></A>
</TD></TR>
<TR><TD height="15" NOWRAP>
<SCRIPT>
if (publicSCRMOption == "EDISTATUS")
document.write(' <img border="0" src="/salesCRM/graphics/rarrow.gif" width="8" height="12">');
else
document.write(' ');
</SCRIPT>
<A HREF="/servlet/faf.unix.servlet.GetEDIStatusServlet"><FONT SIZE="-2" FACE="verdana, arial, helvetica" COLOR="#FFCC66">
<SPAN STYLE="{text-decoration:none}"><STRONG> EDI</STRONG></SPAN></FONT></A>
</TD></TR>
<TR><TD height="15" NOWRAP>
<SCRIPT>
if (publicSCRMOption == "SANITYCHECK")
document.write(' <img border="0" src="/salesCRM/graphics/rarrow.gif" width="8" height="12">');
else
document.write(' ');
</SCRIPT>
<A HREF="/servlet/faf.unix.servlet.GetSanityCheckDiagnosticServlet"><FONT SIZE="-2" FACE="verdana, arial, helvetica" COLOR="#FFCC66">
<SPAN STYLE="{text-decoration:none}"><STRONG>Sanity Check</STRONG></SPAN></FONT></A>
</TD></TR>
<TR><TD height="15" NOWRAP>
<SCRIPT>
if (publicSCRMOption == "FASTBOOK")
document.write(' <img border="0" src="/salesCRM/graphics/rarrow.gif" width="8" height="12">');
else
document.write(' ');
</SCRIPT>
<A HREF="/fast/fastBook.htm"><FONT SIZE="-2" FACE="verdana, arial, helvetica" COLOR="#FFCC66">
<SPAN STYLE="{text-decoration:none}"><STRONG> FAST Book</STRONG></SPAN></FONT></A>
</TD></TR>
<TR><TD height="15" NOWRAP>
<SCRIPT>
if (publicSCRMOption == "AWBREPORT")
document.write(' <img border="0" src="/salesCRM/graphics/rarrow.gif" width="8" height="12">');
else
document.write(' ');
</SCRIPT>
<A HREF="/servlet/faf.unix.servlet.AWBCountReportServlet"><FONT SIZE="-2" FACE="verdana, arial, helvetica" COLOR="#FFCC66">
<SPAN STYLE="{text-decoration:none}"><STRONG>AWB Report</STRONG></SPAN></FONT></A>
</TD></TR>
</TABLE>
</TD>
<TD width="715" VALIGN="TOP">
<DIV ALIGN="right">
<font size="1" color='black'><script LANGUAGE="JavaScript" SRC="/date.js"></script></font>
</DIV>
<H4> Process - Health Check</H4>
<form name="processes" method="POST">
<BLOCKQUOTE>
AS400 DATA PULL - HEALTH CHECK (For IT Personnel Use)
<BR><BR>
<table border="1" bordercolordark="#003366" bordercolorlight="#003366" cellpadding="4" cellspacing="0" width="90%">
<tr bgcolor="#003366">
<TD align="center"><b><font color="#ffffff" size="2">NAME</b></font></TD>
<TD align="center"><b><font color="#ffffff" size="2">RUN</b></font></TD>
<TD align="center"><b><font color="#ffffff" size="2">STARTED</b></font></TD>
<TD align="center"><b><font color="#ffffff" size="2">FINISHED</b></font></TD>
<TD align="center"><b><font color="#ffffff" size="2">FLAG</b></font></TD>
<TD align="center"><b><font color="#ffffff" size="2">RECOVERY</b></font></TD>
</tr>
<tr bgcolor="#FFFFFF">
<TD align='center'> CLIENTAR </TD><TD align='center'> Daily </TD><TD align='left'> 6/30/04 9:56 AM </TD><TD align='left'> 6/30/04 10:00 AM </TD><TD align='center'> SUCCESS </TD><TD align='left'> RESTART THE PROCESS </TD>
</tr>
<tr bgcolor="#FFFFFF">
<TD align='center'> CONTAINERALERT </TD><TD align='center'> DAILY </TD><TD align='left'> 6/23/04 6:00 AM </TD><TD align='left'> 6/23/04 6:00 AM </TD><TD align='center'> SUCCESS </TD><TD align='left'> RESTART THE PROCESS </TD>
</tr>
<tr bgcolor="#FFFFFF">
<TD align='center'> DAYMONTHREVENUE </TD><TD align='center'> Daily </TD><TD align='left'> 6/23/04 5:20 AM </TD><TD align='left'> 6/23/04 5:39 AM </TD><TD align='center'> SUCCESS </TD><TD align='left'> </TD>
</tr>
<tr bgcolor="#FFFFFF">
<TD align='center'> FADAILYREVENUE </TD><TD align='center'> Daily </TD><TD align='left'> 6/30/04 10:13 AM </TD><TD align='left'> 6/30/04 10:19 AM </TD><TD align='center'> SUCCESS </TD><TD align='left'> RESTART THE PROCESS </TD>
</tr>
<tr bgcolor="#FFFFFF">
<TD align='center'> FAONTIMECOMPLIANCE </TD><TD align='center'> Daily </TD><TD align='left'> 7/15/04 2:44 PM </TD><TD align='left'> 7/15/04 2:47 PM </TD><TD align='center'> SUCCESS </TD><TD align='left'> </TD>
</tr>
<tr bgcolor="#FFFFFF">
<TD align='center'> FAPAYROLLLOCS </TD><TD align='center'> WEEKLY </TD><TD align='left'> 6/18/04 4:30 PM </TD><TD align='left'> 6/18/04 4:30 PM </TD><TD align='center'> SUCCESS </TD><TD align='left'> RESTART THE PROCESS </TD>
</tr>
<tr bgcolor="#FFFFFF">
<TD align='center'> FAPROCESS </TD><TD align='center'> Daily </TD><TD align='left'> 6/23/04 4:00 AM </TD><TD align='left'> 6/23/04 4:02 AM </TD><TD align='center'> SUCCESS </TD><TD align='left'> RESTART THE PROCESS </TD>
</tr>
<tr bgcolor="#FFFFFF">
<TD align='center'> FATIMESHEET </TD><TD align='center'> WEEKLY </TD><TD align='left'> 6/18/04 4:30 PM </TD><TD align='left'> 6/18/04 4:39 PM </TD><TD align='center'> SUCCESS </TD><TD align='left'> CLEAR DB AND RESTART PROCESS </TD>
</tr>
<tr bgcolor="#FFFFFF">
<TD align='center'> FAVOLUME </TD><TD align='center'> Daily </TD><TD align='left'> 6/30/04 10:30 AM </TD><TD align='left'> 6/30/04 4:15 PM </TD><TD align='center'> SUCCESS </TD><TD align='left'> RESTART THE PROCESS </TD>
</tr>
<tr bgcolor="#FFFFFF">
<TD align='center'> HP_EMPEXTRACT </TD><TD align='center'> Daily </TD><TD align='left'> 7/26/04 7:10 AM </TD><TD align='left'> 7/26/04 7:10 AM </TD><TD align='center'> SUCCESS </TD><TD align='left'> RESTART THE PROCESS </TD>
</tr>
<tr bgcolor="#FFFFFF">
<TD align='center'> HP_HOURSLOAD </TD><TD align='center'> Daily </TD><TD align='left'> 7/26/04 7:10 AM </TD><TD align='left'> 7/26/04 7:10 AM </TD><TD align='center'> SUCCESS </TD><TD align='left'> RESTART THE PROCESS </TD>
</tr>
<tr bgcolor="#FFFFFF">
<TD align='center'> HP_PUNCHPROCESS </TD><TD align='center'> Daily </TD><TD align='left'> 7/26/04 7:10 AM </TD><TD align='left'> 7/26/04 7:10 AM </TD><TD align='center'> SUCCESS </TD><TD align='left'> RESTART THE PROCESS </TD>
</tr>
<tr bgcolor="#FFFFFF">
<TD align='center'> MONTHLYVOLUME </TD><TD align='center'> Monthly </TD><TD align='left'> 6/1/04 12:00 AM </TD><TD align='left'> 6/1/04 12:11 AM </TD><TD align='center'> SUCCESS </TD><TD align='left'> RESTART THE PROCESS </TD>
</tr>
<tr bgcolor="#FFFFFF">
<TD align='center'> PREPAIDRATEMAP </TD><TD align='center'> DAILY </TD><TD align='left'> 6/29/04 10:26 AM </TD><TD align='left'> 6/29/04 10:38 AM </TD><TD align='center'> SUCCESS </TD><TD align='left'> RESTART THE PROCESS </TD>
</tr>
<TR bgcolor="#FFFFFF">
<TD colspan="6" align="center">
<B>Total records returned : 14</B>
</TD>
</TR>
</TABLE>
</form>
</BLOCKQUOTE>
<script LANGUAGE="JavaScript" SRC="/publicFooter.js"></script>
</TD>
</TR>
</TABLE>
</BODY>
</HTML><--- End of Complete page ---> -
Can I deploy pages with DB params stored elsewhere?
Hello,
Trying to get up to speed with JSP's. So far, all is well. Can go into, out, etc. of a DB, which is fine.
Question is this. The pages that have all of the JDBC connection params in them, is it possible to put all of the DB params into a module page, and just import it, so I don't have a ton of duplicate code floating around the web site? If so, what's the best? Almost like a .h file in C++, but in Java, what are they called?
Thanks,
10khttp://java.sun.com/products/jsp/syntax/1.2/syntaxref12.html
You can use the <%@ include %> which is the equivalent of a .h file in c++
It is a static include at page translation time, which effectively just "pastes" the code into your jsp.
This way you can have a common header on all of your JSPs.
However it is preferable NOT to do SQL queries/scriptlet code in JSP.
Write a java bean that handles database connection, and call db.getConnection() on it.
Or use JSTL sql tags
Even better, don't have any SQL statements on your JSP pages - put it all into java beans as a data access layer.
Cheers,
evnafets -
I would like to know which APIs are necessary to develop a network speed tester in jsp or which method to do this, knowing about which APIs it's necessary, I will study them. Here is a example of a network speed tester that I'm trying to do
Examples:
http://www.coiinc.com/speedtest/initialmeter.php
http://www.pcativo.com.br/testes.asp?teste_tipo=velocidade
http://www.navegante.com.br/medidor/initialmeter.php
http://medidor.interair.com.br/
http://www.rjnet.com.br/velocimetro/index2.htmSir,
For at least a couple of these options it appears that the test is actually based on JavaScript.
What seems to happen is that at the beginning of the page there is a JavaScript variable that is set with the time.
Then there is a big amount of some sort of data. Which I would guess has been measured to be X big. Let's say 1 MB.
Finally there is another bit of Javascript which again takes the time and then finds out the difference and from that one can sort of conclude the time difference.
But I am not convinced this will always work perfectly but who knows... anyway your use of JSP wouldn't preclude you from just basically copying what these others are doing.
Sincerely,
Slappy -
Speeding up displaying 1000s of rows of db query results in JSP
I am working on a report that formats and displays thousands of rows from the result set. Although the query itself takes only 1 sec, a lot of time (15 secs) is spent formatting for JSP and serving it back to the browser.
Is there an efficient way of speeding this up? Increasing page buffer size didn't seem to help. <%@ page buffer="64kb" %>
Thanks
Mark SabatiniIs there an efficient way of speeding this up?
Increasing page buffer size didn't seem to help. <%@
page buffer="64kb" %>The container starts writing out the html when the buffer is full.
So, increasing the buffer size will further delay the appearance of the page in the browser.
If by formatting the page, you mean sorting/re-arranging data, you could push that into the database by using a stored procedure.
@mshanu: What exactly do you expect to achieve by adding an extra step of converting to xml? -
How Can I speed up the results on my JSP page with the help of Caching.
I am generating a dropdown listbox by merging an xml file with a style sheet(xsl).
This list box comes up fine without any problems. Now, I am adding some advanced
logic to the
style sheet (xsl) to use the same xml file in a more efficient way. This time
the generation
of the list box is taking much longer (upto 25 seconds) although I get the results
I want.
Is there any way I could speedup this process by using weblogics caching. I know
the process is slowing down
due to the code in the stylesheet. Will caching resolve this issue?. I tried
using
<wl:cache> </wl:cache> on the jsp page generating this listbox but found no improvement.
Any help will be very much appreciated.turn off your phone, unplug your router, leace it off for 30 seconds, and then power it back on and turn the iphone back on
-
Question about speed issues using JSP/JavaBeans/JRun & SQL Server
Hi. I am a developer for a small software company. About 2 years ago we started development on an E-Commerce platform written in Java. It has administrative tools that are actual applications and also web admins that are jsp pages.
Every JSP page we have calls java beans, and these java beans then pull information from or put information into our database.
Our database is SQL server 7.0 and is a relational DB. So, for instance, we have about 100 items, with 15 features each, 3 images, and so its a pretty small database, but it has quite a few rows.
Now, to pull information straight from our database and spit it out on a jsp page, it takes about 2 seconds, to put information into the database (saving a survey), it takes about 5-10 seconds. To me, this seems like a VERY long time just for a page to load. We have about 7 websites all running on the same server with different instances of JRun 3.0, and that same server is running SQL Server and IIS 5.0.
Now, without posting our thousands of lines of code, can anyone help me try to figure out where our bottleneck might possibly be? Any help or suggestions would be greatly appreciated
Anyone that has done something similar, what was your database access time and what did you use to display your pages? (Jrun with IIS or what)
I'm the last person here (everyone else jumped ship and I wasn't here for the design aspect of this project) and before we bring in a consultant to try to work on this, I was hoping that some of you here could share your insight on any similar projects you may have worked on.
Thank you very much.Make sure that your JDBC code is using connection pooling. You would know this since you would have to set up a DataSource in the JMC.
Then instead of going through the DriverManager, you would get your Connection from the DataSource object via the InitialContext object.
If you're already using Connection pooling, verify that the SQL statements are as efficient as possible. That is, make sure they are using indexes in the DBMS. The SQL tracer tool can show any bad performing SQL.
Lastly, re-index any tables if they are not reindexed on a regular basis. How often you re-index will depend on how often the data changes.
Good luck ... -
Memory speed - Equium A200 PSAF5E
Hi all,
I own a Toshiba Equium A200 - 1V0
Model no. PSAF5E - 001003sp
Bios version updated to v. 2.50
Everest Ultimate 4.5.1330 says that I have 2GB of RAM, in two sticks of Samsumg DDR2-667. Also it says too that my FSB is 133Mhz with correct CPU speed and multipier.
The problem comes with memory speed. It shows DDR2-667 capable sticks and chipset, but DRAM:FSB ratio is set to 8:4 resulting in DDR2-533, in any energy profile. The system operates in dual-channel 128bit configuration, so I'm losing 2144 MB/sec of transfer speed.
The chipset is identified as an Intel Crestline GML GL960, Everest and Toshiba website show it as DDR2-667 capable, Intel website claims about DDR2-533.
Link:[http://uk.computers.toshiba-europe.com/innovation/jsp/SUPPORTSECTION/discontinuedProductPage.do?service=UK&com.broadvis ion.session.new=Yes&PRODUCT_ID=138201]
Link:[http://www.intel.com/products/notebook/chipsets/gl960/gl960-overview.htm]
I haven't found any motherboard info or manual, so here are my questions:
- Is this speed normal or may I expect the DDR2-667 mode with this system?
- Is the dual-channel mode decreasing memory speed?
- If I re-install memory modules one by one and changing the position, Could it reset the speed values of the system?
- Can I access to any hidden BIOS settings to tweak the memory? (I have a Medion system that has a hidden and password protected BIOS mode accessible through F11 instead of F2 where I can find lots of options not shown in normal F2 BIOS)
- Any more ideas?
Many thanks in advance. Any help would be much apreciated.Hi HiperGrover,
As PauPau wrote, the limited FSB is 533 MHz and that means the memory modules will run at this speed. Furthermore DDR2-667 modules can be used properly but they run only with lower speed.
So don be worry about this, everything is ok with your notebook.
Last but not least in BIOS there are no options about tweaking the modules and such options will not bring a strong performance boost but they could make your computer unstable. -
We are in the stage of deciding which language to develop portlets. I lean towards JSP or servlets for the wide array of Java libraries we can use. I think the only advantage of PL/SQL is speed. Thanks.
It depends. If your developers are mainly Java developers, you'll probably prefer building web portlets. But if you have a strong PL/SQL skill set you could choose the latter. Additionally, if you're developing content that is database intensive you may want to build PL/SQL portlets since they transact with the database faster. If you're going to aggregate content from various web sites, using web providers is preferable. It's a matter of choice based on your requirements and preferences.
-
How to call a repeater within a jsp file in web portal
Hello, I wrote a Timer javascript to create a Timer thread that keep running and repeating for every 5 seconds. Basically, this javascript includes a StartTimer(), StopTimer() and UpdateTimer(), I also have a repeater to retrieve data from Oracle Dataabse and diplay them on the screen. Here are the codes
=======================================================
<table border="1">
<netui-data:repeater dataSource="{pageFlow.trackData}" >
<netui-data:repeaterHeader>
<tr>
<!-- create row header for each column -->
<td style="font-family:times new roman;font-size:14pt;color:#0000ff;">TrackNumber</td>
<td style="font-family:times new roman;font-size:14pt;color:#0000ff;">Latitude</td>
<td style="font-family:times new roman;font-size:14pt;color:#0000ff;">Longitude</td>
<td style="font-family:times new roman;font-size:14pt;color:#0000ff;">Altitude</td>
<td style="font-family:times new roman;font-size:14pt;color:#0000ff;">Course</td>
<td style="font-family:times new roman;font-size:14pt;color:#0000ff;">Speed</td>
<td style="font-family:times new roman;font-size:14pt;color:#0000ff;">Time</td>
</tr>
</netui-data:repeaterHeader>
<tr>
<netui-data:repeaterItem>
<!-- these will make the repeater insert data in table rows -->
<td><netui:label value="{container.item}" defaultValue=" "></netui:label></td>
<% j = j + 1; %>
<% if (j > 6) { %>
</tr>
<% j = 0; %>
<tr>
<% } %>
</netui-data:repeaterItem>
</tr>
</netui-data:repeater>
</table>
====================================================
I also wrote another Timer running in the server side. here are the codes
======================================================
<%!
public void startTimer(HttpServletRequest request)
Timer timer = new Timer();
TimerTask monitorTimerTask = new Monitor();
timer.schedule(monitorTimerTask, 5000, 5000);
request.getSession().setAttribute("My Timer", monitorTimerTask);
System.out.println("Timer starts");
%>
<%!
public class Monitor extends TimerTask
public void run()
%>
<%!
public void stopTimer(HttpServletRequest request)
TimerTask monitor = (TimerTask) request.getSession().getAttribute("My Timer");
if (monitor != null)
System.out.println("Timer stops");
monitor.cancel();
%>
<% if (request.getParameter("start") != null)
startTimer(request);
%>
<% if (request.getParameter("stop") != null)
stopTimer(request);
%>
<input type="button" value="Start the Timer" onclick="document.location='index.jsp?start=true'">
<input type="button" value="Stop the Time" onclick="document.location='index.jsp?stop=true'">
======================================================
My question is how do (can I) call those codes repeater above within the StartTimer() in Javascript or the funtion run() in the class Monitor, which will will be called continuously every 5 seconds, whenever I click on the button Start. Right now, it seems to me that whenever the portal starts, then those repeater codes are executed just once and are not executed when I click on the start button to call the start() in javascripts/run() in the class Monitor.
PS. I include the codes for two different Timers but in my portal there is only one Timer and I can pick one of those, whichever works better. Please help
Thank you
TLIt might compile perfectly well, but the message suggests that you didn't deploy it properly. The class loader can't find it.
That .class file should appear with its package directory structure under the WEB-INF/classes directory or in a JAR in your WEB-INF/lib directory in some WAR file. Does it? -
OK - I looked at the manual & see they made it major project. Instead of simply assigning tel numbers to each of the dialing digits, you have to build a directory record first, then you can assign the directory record to a dialing digit.
Looks like the simple part is using it - just press and hold the digit to dial the whole number.
So, it will take 40 minutes or so to break down the steps in understandable prose. It is too late to start now & i have a vet appointment in the am. All day is kind of full. But, I will try to do it tomorrow (thurs the 18th)Seemed like there should be a speed dial, so I did a search & found the cure is worse than the disease -
Dial from your phone
Make calls directly from your existing touch-tone home phone:
Local calls: Dial the 7- or 10-digit phone number.
Long distance calls: Dial 1 + area code + 7-digit phone number.
International calls: Dial 011 + country code + 7-digit phone number.
Dial online from your myAT&T account
Call from your online Address Book or Call History, which shows a list of up to 100 of your most recent call records sorted by date and time:
Log in to myAT&T. Don't have a myAT&T login? Register today!
From the I want to menu, select Manage my plans and services and then Manage my phone features.
Your U-verse portal will open and a Make a Call box will appear on the left side of the page.
Enter a number to dial or select a number from your Call History or Address Book.
Specify whether you'd like to activate/deactivate Caller ID Blocking and Call Waiting for the call.
Select Place Call.
When your home phone rings, pick it up to place your call.
Important Note
To find numbers in the Call History, you can also sort numbers by missed, answered, outgoing, name, length of call, or type, or search for a specific call.
Dial from your U-verse TV
With U-verse TV, you can view a list of up to 100 of your most recent incoming call records by date and time on your TV screen. Use your U-verse TV remote to tune to your Call History and return calls with the press of a button.
Tune to Channel 9900 using your U-verse TV remote.
Select a U-verse Voice phone number on screen.
Press OK to view a log of answered and missed calls. You can sort by name, date, and phone number.
Scroll using the arrows.
Select a number and press OK to return a call.
Select Call and press OK.
When your home phone rings, pick it up to place your call.
You can have a call list accesed from a browser.
You can call back a historical call from the browser or TV.
https://www.att.com/esupport/article.jsp?sid=KB401002 -
Intermittant server error when trying to compile jsp.
Hi,
I'm testing my jsp on different browser versions, and on different connection
speeds, and I'm finding a consistent problem with using weblogic v6.1sp1 and slower
connections. (about 56k)
In IE 5/5.5/6, a 'This page cannot be displayed' error shows up. There is no error
in the webserver log and if you enter the url again, it will usually work, or
it might need to be entered twice.
This appears to be a jsp compilation issue, and I'm not sure if it can be resolved.
Any help would be greatly appreciated.
Thanks,
Maeve
Are you using an error page? I've seen IE do some strange things with error
pages with content less than 255 chars long!
"Maeve Loughnane" <[email protected]> wrote in message
news:3c626843$[email protected]..
>
> Hi,
>
> I'm testing my jsp on different browser versions, and on different
connection
> speeds, and I'm finding a consistent problem with using weblogic v6.1sp1
and slower
> connections. (about 56k)
>
> In IE 5/5.5/6, a 'This page cannot be displayed' error shows up. There is
no error
> in the webserver log and if you enter the url again, it will usually work,
or
> it might need to be entered twice.
>
> This appears to be a jsp compilation issue, and I'm not sure if it can be
resolved.
>
> Any help would be greatly appreciated.
> Thanks,
> Maeve
-
[MapViewer] MapClient.jsp to Servlet?
Hi,
Has anybody ever tried to convert the demo that comes with MapViewer into a servlet?
Right now the MapClient.jsp demo is very slow here, and I hope to get some speed improvements with a servlet. I also think it's a little easier to add some extra functionallity with a servlet...
So, has anybody done it?You may want to first find out what's slowing down the jsp client. Most likely its the database query time dominating the performance, in which case converting the jsp into servlet wont help much.
you can change the logging level of MapViewer to "finest" and check the logs while doing a few zoom/pans from the client. see how much time is spent in loading the data from db and what's the percentage of that in the overall process.
lj -
Compiling jsp pages in wl 10.0 2 times slower than wl 9.1
Hi:
I have enterprise application. In weblogic 9 it took 4-5min to compile all the jsp pages, in weblogic 10 it takes 10-11min!!
Is there anything I can do to speed it up?Hi, thanks for your answers.
Yes, I actually build the ear file and then I call weblogic.appc on it. And again, on wl 9 it used to take 4-5min, now it is taking 10-11min. Most of the time of the build process is taken by the page compilation.
The other thing I noticed is that if I change a page the time it takes WL to recompile the page is way longer than before. I have to wait for a good 14-15seconds until the weblogic returns the new page. The weblogic java process goes up to almost 100%. Before, in WL 9 I had to wait just a few seconds. And ok, my computer is a dual core at 2.33GHz. Don't tell me I need to upgrade :-).
I realize that the jsp compilation must have gotten more complicated because now jsf & jsp are unified but still....
My app is a jsf application and I also use tag files.
About precompiling the pages... I build the application on windows then I deploy it on linux. In WL 9, whenever I deployed the app, I had to precompile the pages otherwise the users experienced slower responses the first time. For whatever reason WL 9 didn't think the pages were already precompiled (they were part of the ear file). In WL 10 that seemed to have been fixed.
Maybe you are looking for
-
Importing just music FILES from PC to Mac
Hi, Just bought my wife a mac and want to transfer her music files from the PC to the Mac. The PC does NOT have itunes running anymore. Let's just say the itunes, at least on the PC, does some rather dumb things. Anyhow, itunes on the PC is dead. Pla
-
Scared of buying a new Macbook - help!
Scared of buying a new Macbook! I really need to buy a laptop due to a book I'm about to start writing, but after reading all the negative things on here about the new Macbook and Macbook Pro with overheating and this funny heat gel that Apple are du
-
I wolud like to make a Drag&Drop JTree
Hi everyone: I'm trying to implement a JTree with Drag&Drop support. I've been lookig for some code examples but It was imposible to find them. I didn't found either information about drag&drop. Thank you very much. Chefo
-
So what's actually different about iOS4 on 3G!?
Ok, so I waited around three hours for iOS4 to install on my iPhone 3G - When it finally 'came back to life' all I can see that's different is the dock and the photo albums are slightly different - Are these the only changes!? Please don't tell me I'
-
I have completed a song on the GarageBand app which plays fine. I export it via email and it opens up in iTunes on my PC fine but when you play it there is no sound from the file. Anyone know I am doing wrong please?