This commit is contained in:
jungwon
2022-03-03 12:08:19 +09:00
commit 9cd1052ecc
61 changed files with 2572 additions and 0 deletions

View File

@@ -0,0 +1,39 @@
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<ul>
<c:set var="contextPath" value="<%= request.getContextPath()%>"></c:set>
<h1 style=" padding:10px;" width=100%> APM BMT !!</h1>
<p>
샘플 1<br>
<img src="${contextPath}/images/dummy-100x100-1.jpg">
</p>
<p>
샘플 2<br>
<img src="${contextPath}/images/dummy-100x100-2.jpg" width="245">
</p>
<p>
샘플 3<br>
<img src="${contextPath}/images/dummy-100x100-3.jpg" width="245">
</p>
</br>
</body>
</html>

View File

@@ -0,0 +1,46 @@
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ page import = "java.util.*" %>
<%@ page import = "kr.co.mantech.common.*" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<ul>
<c:set var="contextPath" value="<%= request.getContextPath()%>"></c:set>
<h1 style=" padding:10px;" width=100%> OOM BMT !!</h1>
<%!
HeapLeakManager hlm = new HeapLeakManager(false,50000, HeapLeakManager.CheckType.Heap);
%>
<%
HashMap hm= hlm.doLeak();
%>
<BR>
HeapSize =<%= hm.get("heapSize") %> MB
<BR>
freeHeapSize =<%= hm.get("freeHeapSize") %> MB
<BR>
ArraySize =<%= hm.get("ArraySize") %> 개
<BR>
Number of Loaded Class =<%= hm.get("classesSize") %> 개
<BR>
</h2></p>
</br>
</body>
</html>

View File

@@ -0,0 +1,48 @@
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ page import = "java.util.*" %>
<%@ page import = "kr.co.mantech.common.*" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<ul>
<c:set var="contextPath" value="<%= request.getContextPath()%>"></c:set>
<h1 style=" padding:10px;" width=100%> Perm OOM BMT !!</h1>
<%!
HeapLeakManager hlm = new HeapLeakManager(true,10000, HeapLeakManager.CheckType.Perm);
%>
<%
HashMap hm= hlm.doLeak();
%>
<BR>
HeapSize =<%= hm.get("heapSize") %> MB
<BR>
freeHeapSize =<%= hm.get("freeHeapSize") %> MB
<BR>
ArraySize =<%= hm.get("ArraySize") %> 개
<BR>
Number of Loaded Class =<%= hm.get("classesSize") %> 개
<BR>
</h2></p>
</br>
</body>
</html>

View File

@@ -0,0 +1,40 @@
<%@page import="java.util.Calendar"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ page import="java.util.Date" %>
<%@ page import="kr.co.mantech.jungwon.F12.*" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<%
APMBMTClass apm = new APMBMTClass();
out.println("APMBMTClass + printInfo + 1 second");
out.println("</BR>");
apm.printInfo(1);
out.println("APMBMTClass + printInfo + 5 second");
apm.printInfo(5);
out.println("</BR>");
out.println("APMBMTClass + printInfo + 10 second");
apm.printInfo(10);
out.println("</BR>");
out.println("APMBMTClass + printInfo-nested");
apm.printInfo1(1);
out.println("</BR>");
out.println("APMBMTClass + printInfo + Check Method Cap Time ");
apm.printInfo3(1);
out.println("</BR>");
%>
</html>

View File

@@ -0,0 +1,5 @@
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<hr/>
<class="copyright">Copyright 2020 (주)맨텍 All Rights Reserved</p>

View File

@@ -0,0 +1,18 @@
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<c:set var="contextPath" value="<%= request.getContextPath()%>"></c:set>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td colspan=2 style="background-color:#white;"><img src="${contextPath}/resources/images/mantech.png" alt="Mantech logo" /> </td>
</tr>
<tr>
<td ><img src="${contextPath}/resources/images/accordion_img.png" alt="accordion logo" /></td>
<td style=" padding:10px;" width=100%><h1 >샘플 테스트 WEBAPP Version 1</h1>
</tr>
</table>
<hr/>

View File

@@ -0,0 +1,56 @@
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<ul>
<c:set var="contextPath" value="<%= request.getContextPath()%>"></c:set>
<li><a href="${contextPath}/pages/1.jsp">기본페이지 호출</a></li >
<li> F01 : 클라이언트 분리 호출(이미지/JSP) </li>
<ul>
<li><a href="${contextPath}/pages/F01-image.jsp">F01 이미지 분리 화면 호출</a></li>
</ul>
<li>샘플 세션 정보</li>
<ul>
<li><a href="${contextPath}/pages/session-info.jsp">Session : 샘플 세션 정보 </a></li>
</ul>
<li>OOM 테스트</li>
<ul>
<li><a href="${contextPath}/pages/OOMTest.jsp">OOM 테스트 : heapdump, 메모리 추이등 확인 </a></li>
<li><a href="${contextPath}/pages/PermOOM.jsp">Perm영역 OOM 테스트 : OutOfMemory 확인</a></li>
</ul>
<li>cpu 사용률 증가</li>
<ul>
<li><a href="${contextPath}/pages/cpu.jsp">CPU사용률 테스트 : CPU 사용률 증가 확인 </a></li>
</ul>
<li>임의 클래스 매소드 추적</li>
<ul>
<li><a href="${contextPath}/pages/classMethod.jsp">임의 클래스/ 메소드 호출</a></li>
</ul>
<li>DB 커넥션 정보</li>
<ul>
<li><a href="${contextPath}/pages/db-connection-info.jsp">DB : ConnectionPool </a></li>
</ul>
<li>DB 커넥션 leak</li>
<ul>
<li><a href="${contextPath}/pages/db-connection-leak.jsp"> DB : Connection Leak </a></li>
</ul>
<li>Thread Sleep</li>
<ul>
<li><a href="${contextPath}/pages/thread-sleep.jsp"> Thread : Thread 무한 대기 </a></li>
<li><a href="${contextPath}/pages/thread-sleep-3.jsp"> Thread : Thread 3초 대기 </a></li>
<li><a href="${contextPath}/pages/thread-sleep-1.jsp"> Thread : Thread 1초 대기 </a></li>
</ul>
</ul>

View File

@@ -0,0 +1,52 @@
<%@page import="java.util.Calendar"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ page import="java.util.Date" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<%
String second = request.getParameter("second");
if (second == null )
{
second="1";
}
%>
<body>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td colspan=2 style="background-color:#7a7a84;"><img src="../images/tta_logo.png" alt="TTA logo" /> </td>
</tr>
<tr>
<td ><img src="../images/bmt_logo.gif" alt="BMT logo" /></td>
<td style=" padding:10px;" width=100%> <h1>Sleep for ${second} second </h1>
</tr>
</table>
<hr/>
<%
long start = System.currentTimeMillis();
Thread.sleep(Integer.parseInt(second)*1000);
long end = System.currentTimeMillis();
long gap = (end-start);
%>
<h1 style=" padding:10px;" >Call Success !!!!! </h1> <br>
<h2>elapsed time = <%= gap %> ms </h2> <br>
<hr/>
<class="copyright">Copyright 2017 TTA All Rights Reserved (TTA 한국정보통신기술협회)</p>
</body>
</html>

View File

@@ -0,0 +1,38 @@
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE HTML>
<c:set var="title" value="TTA_F01" />
<c:set var="content" value="content" />
<html>
<head>
<title>${param.title}</title>
<link rel="stylesheet" type="text/css"
href="${pageContext.request.contextPath}/css/template.css" />
</head>
<body>
<div id="header">
<jsp:include page="/jsp/common/header.jsp" />
</div>
<div id="middle">
<div id="left"> <h4>TEST CASE</h4>
<jsp:include page="/jsp/common/menu.jsp" />
</div>
<div id="contents" >
<jsp:include page="/${param.content}" />
</div>
</div>
<div id="footer">
<jsp:include page="/jsp/common/footer.jsp" />
</div>
</body>
</html>

View File

@@ -0,0 +1,38 @@
<%@page import="java.util.Calendar"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ page import="java.util.Date" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<%
while (true)
{
int time=0;
for (int i=1; i<100000;i++)
{
double temp = Math.random()* Math.random() * 100;
String str = "aaa";
str = str+str;
}
Thread.sleep(100);
time++;
if (time==200)
break;
}
%>
</html>

View File

@@ -0,0 +1,89 @@
<%@ page language="java" contentType="text/html;charset=EUC-KR"%>
<%@ page import="kr.co.mantech.common.DBManager" %>
<%@ page import="java.sql.*" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<html>
<head>
<title>XA_DataSource Test</title>
</head>
<body>
<%
String sql = request.getParameter("sql");
if (sql==null)
sql="select * from emp";
String dsName = request.getParameter("dsName");
%>
<Table align=left border="1" width=100%>
<tr><td align="left">JNDI NAME</td> <td align="left"><%=dsName%></td></tr>
<tr><td align="left">selectSQL</td> <td align="left"><%=sql%></td></tr>
<tr><td align="left">DESC</td> <td align="left">Select from <%=dsName%> </td>
<%
ResultSet rs=null;
Connection con=null;
PreparedStatement ps = null;
DBManager db;
db = new DBManager();
%>
<h3>
<Form method = "get" action="${pageContext.request.contextPath}/pages/db-connection-info.jsp">
<Table align=left border="1" width=100%>
<tr>
<td align=right width=30% >DataSource JNDI</td>
<td><input type="text" name="dsName" value="${param.dsName}"/> </td>
<tr>
<tr>
<td align=right width=30% >SQL</td>
<td ><input type="text" name="sql" value="${param.sql}" /> </td>
<tr>
<td colspan="2" align=center width=100%><input type="submit" name="input" value="<22>Է<EFBFBD>"></td>
</tr>
</Table>
</Form>
</h3>
<%
if (dsName !=null )
{
con = db.getConnection(dsName);
ps = con.prepareStatement(sql);
rs = db.selectSQL(ps);
ResultSetMetaData rsmd = rs.getMetaData();
int columnCnt = rsmd.getColumnCount() ;
out.print("<br>");
out.print("<h2> Sql Query = " + sql + "</h2>");
out.print("<table border=1 bordercolor=\"gray\" cellspacing=1 cellpadding=0 width=\"100%\">");
for(int i=1;i<=columnCnt;i++)
{
out.print("<td>");
out.print(rsmd.getColumnName(i));
out.print("</td>");
}
out.print("</tr>");
while(rs.next())
{
out.print("<tr>");
for(int i=1;i<=columnCnt;i++)
{
out.print("<td>");
out.print(rs.getString(i));
out.print("</td>");
}
out.print("</tr>");
}
out.print("</table>");
db.close(con, rs, ps);
}
%>
</body>
</html>

View File

@@ -0,0 +1,89 @@
<%@ page language="java" contentType="text/html;charset=EUC-KR"%>
<%@ page import="kr.co.mantech.common.DBManager" %>
<%@ page import="java.sql.*" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<html>
<head>
<title>Conncecion Leak</title>
</head>
<body>
<%
String sql = request.getParameter("sql");
if (sql==null)
sql="select * from emp";
String dsName = request.getParameter("dsName");
%>
<Table align=left border="1" width=100%>
<tr><td align="left">JNDI NAME</td> <td align="left"><%=dsName%></td></tr>
<tr><td align="left">selectSQL</td> <td align="left"><%=sql%></td></tr>
<tr><td align="left">DESC</td> <td align="left">Select from <%=dsName%> </td>
<%
ResultSet rs=null;
Connection con=null;
PreparedStatement ps = null;
DBManager db;
db = new DBManager();
%>
<h3>
<Form method = "get" action="${pageContext.request.contextPath}/pages/db-connection-leak.jsp">
<Table align=left border="1" width=100%>
<tr>
<td align=right width=30% >DataSource JNDI</td>
<td><input type="text" name="dsName" value="${param.dsName}"/> </td>
<tr>
<tr>
<td align=right width=30% >SQL</td>
<td ><input type="text" name="sql" value="${param.sql}" /> </td>
<tr>
<td colspan="2" align=center width=100%><input type="submit" name="input" value="<22>Է<EFBFBD>"></td>
</tr>
</Table>
</Form>
</h3>
<%
if (dsName !=null )
{
con = db.getConnection(dsName);
ps = con.prepareStatement(sql);
rs = db.selectSQL(ps);
ResultSetMetaData rsmd = rs.getMetaData();
int columnCnt = rsmd.getColumnCount() ;
out.print("<br>");
out.print("<h2> Sql Query = " + sql + "</h2>");
out.print("<table border=1 bordercolor=\"gray\" cellspacing=1 cellpadding=0 width=\"100%\">");
for(int i=1;i<=columnCnt;i++)
{
out.print("<td>");
out.print(rsmd.getColumnName(i));
out.print("</td>");
}
out.print("</tr>");
while(rs.next())
{
out.print("<tr>");
for(int i=1;i<=columnCnt;i++)
{
out.print("<td>");
out.print(rs.getString(i));
out.print("</td>");
}
out.print("</tr>");
}
out.print("</table>");
//db.close(con, rs, ps);
}
%>
</body>
</html>

View File

@@ -0,0 +1,16 @@
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
<h1 style=" padding:10px;" width=100%> APM BMT !!</h1>
</body>
</html>

View File

@@ -0,0 +1,28 @@
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<H2>
APM BMT 테스트
</H2>
1) 기본 페이지 <br>
http://IP/NIA-APM-BMT/jsp/common/normal.jsp <br>
2) F01 : 클라이언트 분리 호출(이미지/JSP)<br>
3) F02, F03 등 : HeapDump 생성 : 메모리 관련 모니터링(OutOfMemory) <br>
4) F06 : DB Connection 관련 <br>
5) 응답지연 관련 : sleep.jsp <br>
6) cpu 관련 : cpu.jsp <br>

View File

@@ -0,0 +1,28 @@
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td colspan=2 style="background-color:#7a7a84;"><img src="../images/tta_logo.png" alt="TTA logo" /> </td>
</tr>
<tr>
<td ><img src="../images/bmt_logo.gif" alt="BMT logo" /></td>
<td style=" padding:10px;" width=100%/>
</tr>
</table>
</hr>
<h1 style=" padding:10px;" width=100%> Sample WAS BMT !!</h1>
</hr>
<class="copyright">Copyright 2017 TTA All Rights Reserved (TTA 한국정보통신기술협회)</p>
</body>
</html>

View File

@@ -0,0 +1,69 @@
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@page import="java.util.*" %>
<%@page import="java.text.*" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<%
HttpSession sess = request.getSession();
boolean isNew = session.isNew();
String sessionId = session.getId();
long creationTime = session.getCreationTime();
long lastAccessedTime = session.getLastAccessedTime();
int maxInactiveInterval = session.getMaxInactiveInterval();
int rand_M=(int)(Math.random()*10000);
int rand_MS=(int)(Math.random()*10000);
if (sess.getAttribute("SessionAttr") ==null) {
out.println("<h2> session out </h2>");
sess.setAttribute("SessionAttr", rand_M+"");
sess.setAttribute("SessionAttr2", rand_MS+"");
} else {
out.println("<h2> session exist </h2>");
}
java.util.Enumeration e = sess.getAttributeNames();
%>
<table border=1 bordercolor="gray" cellspacing=1 cellpadding=0 width="100%">
<tr bgcolor="gray"><td colspan=2 align="center"><font color="white"><b>Session Info</b></font></td></tr>
<tr>
<td width="25%">Session ID</td><td width="75%"><%=sessionId%></td>
</tr>
<tr>
<td>isNewe</td><td><%=isNew%></td>
</tr>
<tr>
<td>Creation Time</td><td><%=new Date(creationTime)%></td>
</tr>
<tr>
<td>Last Accessed Time</td><td><%=new Date(lastAccessedTime)%></td>
</tr>
<tr>
<td>Max Inactive Interval</td><td><%=maxInactiveInterval%></td>
</tr>
<tr bgcolor="cyan"><td colspan=2 align="center"><b>Session Vaule List<b></td></tr>
<tr>
<td align="center">NAME</td>
<td align="center">VAULE</td>
</tr>
<%
String name = null;
while ( e.hasMoreElements() ) {
name = (String) e.nextElement();
%>
<tr><BR><td align="left">sessnion name <%=name%></td><BR> <td align="left"><%=sess.getAttribute(name)%></td></tr>
<%
}
%>
</table>

View File

@@ -0,0 +1,75 @@
<%@page import="java.util.Calendar"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ page import="java.util.Date" %>
<%@ page import="java.util.concurrent.*" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<%
String second = request.getParameter("second");
if (second == null )
{
second="1";
}
%>
<body>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td colspan=2 style="background-color:#7a7a84;"><img src="../images/tta_logo.png" alt="TTA logo" /> </td>
</tr>
<tr>
<td ><img src="../images/bmt_logo.gif" alt="BMT logo" /></td>
<td style=" padding:10px;" width=100%> <h1>Sleep for ${second} second </h1>
</tr>
</table>
<hr/>
<%
long start = System.currentTimeMillis();
Thread.sleep(Integer.parseInt(second)*1000);
int cnt=0;
int count=5;
while (true)
{
// double a=Math.random();
// double b=Math.random();
double a=ThreadLocalRandom.current().nextDouble();
double b=ThreadLocalRandom.current().nextDouble();
System.out.println(a);
System.out.println(b);
double c=a*b*a;
if (cnt==count)
break;
cnt++;
}
long end = System.currentTimeMillis();
long gap = (end-start);
%>
<h1 style=" padding:10px;" >Call Success !!!!! </h1> <br>
<h2>elapsed time = <%= gap %> ms </h2> <br>
<hr/>
<class="copyright">Copyright 2017 TTA All Rights Reserved (TTA 한국정보통신기술협회)</p>
</body>
</html>

View File

@@ -0,0 +1,55 @@
<%@page import="java.util.Calendar"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ page import="java.util.Date" %>
<%@ page import="java.util.concurrent.*" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<%
String second = request.getParameter("second");
if (second == null )
{
second="1";
}
%>
<%
long start = System.currentTimeMillis();
Thread.sleep(Integer.parseInt(second)*1000);
int cnt=0;
int count=5;
while (true)
{
// double a=Math.random();
// double b=Math.random();
double a=ThreadLocalRandom.current().nextDouble();
double b=ThreadLocalRandom.current().nextDouble();
System.out.println(a);
System.out.println(b);
double c=a*b*a;
if (cnt==count)
break;
cnt++;
}
long end = System.currentTimeMillis();
long gap = (end-start);
%>
<h1 style=" padding:10px;" >Call Success !!!!! </h1> <br>
<h2>elapsed time = <%= gap %> ms </h2> <br>
</html>

View File

@@ -0,0 +1,16 @@
<%@page import="java.util.Calendar"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ page import="java.util.Date" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
<jsp:forward page="sleep.jsp">
<jsp:param name="second" value="10000"/>
</jsp:forward>
</body>
</html>