Load Tests for (Desgin issue, Servlets with EJBs in real life?)
I have a very light java program that makes an HTTP connection to a servlet
on the WLS,
it uses the GET method for that, and reads the response from the server, it
logs the time that passes from just before opening the HTTP connection and
right after finishing reading the response. Below is the code snippet for
that:
url = new URL(sURL);
start = getCurrentTime();
URLConnection conn = url.openConnection();
conn.connect();
readResponse(conn.getInputStream());
end = getCurrentTime();
There is a second piece that controls the HTTP connections, it is a separate
java program that creates
the HTTP connection process as many times as desired in a loop and waits for
a specific period of time between every fork of the process (values I used
are 0ms, 3 ms, 30ms etc), you can think of this as arrival rate for the
requests to the server. Below is the code snippet that does this :
for(int i=0; i<nNumOfHits; i++) {
Runtime.getRuntime().exec(HTTP_conn_command);
Thread.sleep(nInterval);
I used WLS 5.1, on a pentium III 866 Mhz., Windows 2000 Pro, with 512 Mb
Ram,
tests are done locally, (WLS and the client programs run on the same
machine),
after each test I refresh the server to be accurate.
With the Servlet + Java approach what the servlet does is to instantiate a
Java Object and
call an Init method on the object passing the HttpServletRequest to it, and
call the
corresponding setters, that's it. There are 7 paramaters which are all
strings, so 7 setters are called.
The Servlet + EJB approach does the same thing, but encapsulates the above
implementation in a single business method of a stateless session bean. Home
interface is created in Init() method of the servlet,
so it is used over and over again.
Any comments on this, greatly appreciated,
thanks,
ali.
I have a very light java program that makes an HTTP connection to a servlet
on the WLS,
it uses the GET method for that, and reads the response from the server, it
logs the time that passes from just before opening the HTTP connection and
right after finishing reading the response. Below is the code snippet for
that:
url = new URL(sURL);
start = getCurrentTime();
URLConnection conn = url.openConnection();
conn.connect();
readResponse(conn.getInputStream());
end = getCurrentTime();
There is a second piece that controls the HTTP connections, it is a separate
java program that creates
the HTTP connection process as many times as desired in a loop and waits for
a specific period of time between every fork of the process (values I used
are 0ms, 3 ms, 30ms etc), you can think of this as arrival rate for the
requests to the server. Below is the code snippet that does this :
for(int i=0; i<nNumOfHits; i++) {
Runtime.getRuntime().exec(HTTP_conn_command);
Thread.sleep(nInterval);
I used WLS 5.1, on a pentium III 866 Mhz., Windows 2000 Pro, with 512 Mb
Ram,
tests are done locally, (WLS and the client programs run on the same
machine),
after each test I refresh the server to be accurate.
With the Servlet + Java approach what the servlet does is to instantiate a
Java Object and
call an Init method on the object passing the HttpServletRequest to it, and
call the
corresponding setters, that's it. There are 7 paramaters which are all
strings, so 7 setters are called.
The Servlet + EJB approach does the same thing, but encapsulates the above
implementation in a single business method of a stateless session bean. Home
interface is created in Init() method of the servlet,
so it is used over and over again.
Any comments on this, greatly appreciated,
thanks,
ali.
Similar Messages
-
Desgin issue, Servlets with EJBs in real life?
When designing a web application with WLS and has anyone made extensive use
of EJBs with Servlets/JSP.
Servlets and JSPs are pretty much a must for the web-app, but are EJBs
really so?. Correct me if I am wrong, the reason that we would wanna use
EJBs (especially I am talking about session EJBs), within servlets
is the fact that they are transactional (so you don't implement transaction
logic in your code), or their being clusterable, thus higher availability by
failovers, etc, ,
They are not faster than standard Java, actually.
by using EJBs in our design we're not gonna gain that much of a speed and
our development time is gonna be longer (well, if designed well, EJBs might
be good candidates for reusability),
instead they are gonna give us higher reliability and availability, along
with a cost of rather slower
responses.
I'll post an explanation of the simle load tests that I have done on the WLS
with two different architectures,
namely Servlet + Std. Java & Servlet + Stateless EJB, shortly
Any comments appreciated,
thanks,
ali.EJBs are a tool in your arsenal. Just like Servlets -- you don't hear
developers suggesting that you avoid Servlets/JSPs and just handle port 80
directly in your own code!
Yes, they are transactional objects for Java. Half the time they are a pain
in the a** but they are better than everyone making up their own standard.
They are not faster than standard Java, actually.They are standard Java, so they are not faster. Since the container either
gens code or uses reflection or both to run them, they are typically a bit
slower than doing direct JDBC (for example) in your servlets. Also, it is
easy to get very bad performance if you don't realize how many database
operations a set of ejb invokes can be.
All in all, once you know EJBs you will probably want to use them, because
they get the job done and are pretty efficient when built correctly. Until
then, they will seem like a pain, largely because they are ;-)
Peace,
Cameron Purdy
Tangosol, Inc.
http://www.tangosol.com
+1.617.623.5782
WebLogic Consulting Available
"ali" <[email protected]> wrote in message
news:[email protected]...
When designing a web application with WLS and has anyone made extensiveuse
of EJBs with Servlets/JSP.
Servlets and JSPs are pretty much a must for the web-app, but are EJBs
really so?. Correct me if I am wrong, the reason that we would wanna use
EJBs (especially I am talking about session EJBs), within servlets
is the fact that they are transactional (so you don't implementtransaction
logic in your code), or their being clusterable, thus higher availabilityby
failovers, etc, ,
They are not faster than standard Java, actually.
by using EJBs in our design we're not gonna gain that much of a speed and
our development time is gonna be longer (well, if designed well, EJBsmight
be good candidates for reusability),
instead they are gonna give us higher reliability and availability, along
with a cost of rather slower
responses.
I'll post an explanation of the simle load tests that I have done on theWLS
with two different architectures,
namely Servlet + Std. Java & Servlet + Stateless EJB, shortly
Any comments appreciated,
thanks,
ali. -
Load Testing for IMS 5.2
hi,
is therer any tools available for load testing for ims 5.2? Can mailstone be used? Understand that this is used in NMS 4.x
thxz
cheerz
marxzThere is no offically supported load testing tools that I am aware of. You are correct that mailstone was shipped with NMS. I have used mailstone, once, but could not figure out what the thing was trying to do. I think it is badly written and the documentation is extremely lacking, IMHO.
Being that iMS follows Internet standards you can use any testing tools that also follow those Internet standards. I've not researched to know if load testing tools exist for mail servers or not, certainly someone has done it. -
Do load test for application installed in Weblogic 10.3.4 using OATS 9.31
Hi Friends,
I need to do a load test for my application deployed in Weblogic 10.3.4. I went on to use the Oracle Application testing Suite (OATS 9.31). But it says its compatible only upto Weblogic 10.3.3. So pls advice me to find a way to load test my oracle fusion application deployed in the current server.
Thanks and regards,
VijaiHi,
Maybe worth also trying the WLS forum for what folks over there use: WebLogic Server - General
Frank -
Performance and Load testing for Agentry applications in SMP2.3
Hello Experts,
We have a requirement to carry out the Performance and Load testing for our SAP Work Manager application (SMP2.3).
Please guide me if ATE (Agentry Test environment) / Jmeter / or any other testing tool can be utilized for the same.
Would be great if you could provide me the steps / references for the same.
Thanks,
AbhishekHi Abhishek,
Please refer this document Agentry - Assets for Admins & Architects. It has very good content which explains about performance testing and performance tuning.
Rgrds,
Jitendra -
ATS load testing for E-Business Suite using IE8 issue
Hi,
I am trying to record a load testing script using Oracle Application testing SUite for E-Business Suite R12.1.3 application. When I start recording I get a pop up asking me to change/disable XSS filter in IE8. I have altready done that and restarted the browser. But the same pop up message comes up.
My queries are:
1) Is ATS 9.3 supported for use with Internet Explorer 8? I am using Windows 7
2) How can I overcome this issue so that I can records EBS script in openscript.
I have run the runDiagnosis.bat file under openscript install folder and the output is as follows:
10:40:17,892 INFO [Application] Log files stored in: C:\OracleATS\logs\odt
10:40:17,905 INFO [DiagnosisExecutor] Starting diagnosis...
10:40:17,908 INFO [DiagnosisExecutor] Log files for all diagnosis categories are stored in: "C:\OracleATS\logs\odt"
10:40:18,105 INFO [DiagnosisExecutor] Environment Info - Date Tue Oct 11 10:40:17 BST 2011
Windows Vista 6.1 , x86
OpenScript
Internet Explorer 8.0.7600.16385
FireFox 7.0.1
10:40:18,108 INFO [DiagnosisExecutor] Openscript install directory: C:\OracleATS\openScript
10:40:18,117 DEBUG [DiagnosisExecutor] Diagnosing Oracle EBS/Forms Functional Testing - Forms FT Diagnoser
10:40:18,532 ERROR [Forms FT Diagnoser] JInitiator was not found on the system.
10:40:18,537 INFO [Installer] JRE option cache is available: false
10:40:18,541 ERROR [Installer] Failed to backup JRE options! FormsFT helper installation will continue...
java.io.FileNotFoundException: C:\Users\Rian\AppData\Roaming\Sun\Java\Deployment\deployment.properties (The system cannot find the path specified)
at java.io.FileInputStream.open(Native Method)
at java.io.FileInputStream.<init>(FileInputStream.java:106)
at oracle.oats.scripting.modules.forms.common.utility.FileUtility.copyFile(FileUtility.java:26)
at oracle.oats.scripting.modules.forms.common.helperInstaller.Installer.installJREPatchImpl(Installer.java:119)
at oracle.oats.scripting.modules.forms.common.helperInstaller.Installer.installJREPatch(Installer.java:105)
at oracle.oats.scripting.modules.forms.common.helperInstaller.WindowsInstaller.installJREPatch(WindowsInstaller.java:68)
at oracle.oats.scripting.modules.forms.common.helperInstaller.Installer.doInstall(Installer.java:75)
at oracle.oats.scripting.modules.formsFT.common.api.internal.helperInstaller.InstallerManager.doInstall(InstallerManager.java:130)
at oracle.oats.scripting.modules.formsFT.diagnosis.FormsFTDiagnoser.checkFormFTHelperInstallation(FormsFTDiagnoser.java:141)
at oracle.oats.scripting.modules.formsFT.diagnosis.FormsFTDiagnoser.diagnose(FormsFTDiagnoser.java:50)
at oracle.oats.scripting.diagnosisTool.api.DiagnosisExecutor.diagnose(DiagnosisExecutor.java:146)
at oracle.oats.scripting.diagnosisTool.api.DiagnosisExecutor.diagnose(DiagnosisExecutor.java:90)
at oracle.oats.scripting.diagnosisTool.Application.runSilently(Application.java:191)
at oracle.oats.scripting.diagnosisTool.Application.run(Application.java:90)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.eclipse.equinox.internal.app.EclipseAppContainer.callMethodWithException(EclipseAppContainer.java:574)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:195)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:386)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:549)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:504)
at org.eclipse.equinox.launcher.Main.run(Main.java:1236)
at org.eclipse.equinox.launcher.Main.main(Main.java:1212)
at org.eclipse.core.launcher.Main.main(Main.java:30)
10:40:22,867 WARN [Installer] FormsFT Helper is installed without cache
java.io.FileNotFoundException: C:\Users\Rian\AppData\Roaming\Sun\Java\Deployment\deployment.properties (The system cannot find the path specified)
at java.io.FileInputStream.open(Native Method)
at java.io.FileInputStream.<init>(FileInputStream.java:106)
at oracle.oats.scripting.modules.forms.common.utility.FileUtility.copyFile(FileUtility.java:26)
at oracle.oats.scripting.modules.forms.common.helperInstaller.Installer.installJREPatchImpl(Installer.java:193)
at oracle.oats.scripting.modules.forms.common.helperInstaller.Installer.installJREPatch(Installer.java:105)
at oracle.oats.scripting.modules.forms.common.helperInstaller.WindowsInstaller.installJREPatch(WindowsInstaller.java:68)
at oracle.oats.scripting.modules.forms.common.helperInstaller.Installer.doInstall(Installer.java:75)
at oracle.oats.scripting.modules.formsFT.common.api.internal.helperInstaller.InstallerManager.doInstall(InstallerManager.java:130)
at oracle.oats.scripting.modules.formsFT.diagnosis.FormsFTDiagnoser.checkFormFTHelperInstallation(FormsFTDiagnoser.java:141)
at oracle.oats.scripting.modules.formsFT.diagnosis.FormsFTDiagnoser.diagnose(FormsFTDiagnoser.java:50)
at oracle.oats.scripting.diagnosisTool.api.DiagnosisExecutor.diagnose(DiagnosisExecutor.java:146)
at oracle.oats.scripting.diagnosisTool.api.DiagnosisExecutor.diagnose(DiagnosisExecutor.java:90)
at oracle.oats.scripting.diagnosisTool.Application.runSilently(Application.java:191)
at oracle.oats.scripting.diagnosisTool.Application.run(Application.java:90)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.eclipse.equinox.internal.app.EclipseAppContainer.callMethodWithException(EclipseAppContainer.java:574)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:195)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:386)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:549)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:504)
at org.eclipse.equinox.launcher.Main.run(Main.java:1236)
at org.eclipse.equinox.launcher.Main.main(Main.java:1212)
at org.eclipse.core.launcher.Main.main(Main.java:30)
10:40:22,936 INFO [Installer] JRE option cache is available: false
10:40:24,044 DEBUG [DiagnosisExecutor] Diagnosed Oracle EBS/Forms Functional Testing - Forms FT Diagnoser. Analyzing results.
10:40:24,063 DEBUG [DiagnosisExecutor] Diagnosing Sun JRE Version 1.6.0_24
10:40:24,077 DEBUG [DiagnosisExecutor] Diagnosing Forms FT Helper Installation
10:40:24,080 DEBUG [DiagnosisExecutor] Diagnosing Web Functional Testing - IE Helper
10:40:24,238 INFO [IEBhoUtil] DotNet Framework found. Version is 4.0.30319
10:40:24,404 INFO [RunCommand] [Cmd execute] cmd.exe /C C:\Windows\Microsoft.NET\Framework\v4.0.30319\regasm.exe
10:40:26,187 INFO [IEBhoUtil] DotNet Framework works well.
10:40:26,318 INFO [IEBhoUtil] OpenScript IE Toolbar/BHO is found.
10:40:26,458 INFO [RunCommand] [Cmd execute] cmd.exe /C "C:\OracleATS\openScript\Oracle IE ToolBar\OpenScriptToolBar.exe"
10:40:27,357 ERROR [IEBhoUtil] Run Oracle IE Toolbar error:Attempted to perform an unauthorized operation.
10:40:27,594 INFO [IEBhoUtil] IE Enhanced Security Administrator Setting: null
10:40:27,675 INFO [IEBhoUtil] IE Enhanced Security Users Setting: null
10:40:27,677 INFO [IEBhoUtil] IE Enhanced Security Settings Disabled
10:40:27,681 DEBUG [DiagnosisExecutor] Diagnosed Web Functional Testing - IE Helper. Analyzing results.
10:40:27,683 DEBUG [DiagnosisExecutor] Diagnosing .NET Framework
10:40:27,685 DEBUG [DiagnosisExecutor] Diagnosing IE Helper Installation
10:40:27,686 DEBUG [DiagnosisExecutor] Diagnosing IE Helper Accessibility
10:40:27,687 ERROR [DiagnosisExecutor] Failure found when diagnosing Web Functional Testing IE Helper
10:40:27,689 DEBUG [DiagnosisExecutor] Trying to fix IE Helper Accessibility
10:40:27,691 INFO [IE Helper] Try to fix an issue: IE Helper Accessibility
10:40:27,860 INFO [IEBhoUtil] OpenScript IE BHO/Toolbar has been enabled.
10:40:27,864 INFO [DiagnosisExecutor] Auto-fixed IE Helper Accessibility
10:40:27,866 DEBUG [DiagnosisExecutor] Diagnosing IE Helper Conflict
10:40:27,869 DEBUG [DiagnosisExecutor] Diagnosing IE Zoom Factor
10:40:27,871 DEBUG [DiagnosisExecutor] Diagnosing IE Enhanced Security Setting
10:40:27,982 DEBUG [DiagnosisExecutor] Diagnosing Web Functional Testing - Firefox Helper
10:40:28,076 INFO [FFExtUtil] OpenScript WebDom Firefox extension is already installed.
10:40:28,156 INFO [FFExtUtil] OpenScript WebDom Add-on is compatible with the installed Firefox 7.0.1
10:40:28,174 INFO [FFExtUtil] Firefox profiles are found.
10:40:28,179 INFO [FFExtUtil] Firefox profiles are found.
10:40:28,182 DEBUG [DiagnosisExecutor] Diagnosed Web Functional Testing - Firefox Helper. Analyzing results.
10:40:28,191 DEBUG [DiagnosisExecutor] Diagnosing Firefox Helper Installation
10:40:28,193 DEBUG [DiagnosisExecutor] Diagnosing Firefox Version
10:40:28,199 DEBUG [DiagnosisExecutor] Diagnosing Firefox Helper Accessibility
10:40:28,201 DEBUG [DiagnosisExecutor] Diagnosing Reset Firefox content preferences.
10:40:28,207 DEBUG [DiagnosisExecutor] Diagnosing Operating System - WebDom Platform Diagnosor
10:40:30,798 DEBUG [DiagnosisExecutor] Diagnosed Operating System - WebDom Platform Diagnosor. Analyzing results.
10:40:30,801 DEBUG [DiagnosisExecutor] Diagnosing Environment Variables
10:40:30,803 DEBUG [DiagnosisExecutor] Diagnosing IE Toolbar/BHO Remover
10:40:30,806 DEBUG [DiagnosisExecutor] Diagnosing Oracle EBS/Forms Load Testing - Forms LT Diagnoser
10:40:31,647 DEBUG [Forms LT Diagnoser] Proxy settings for Sun Java 1.5 and higher are set correctly to "Use Browser Settings". Proxy settings for older versions of Sun Java and JInitiator should be manually verified.
10:40:31,650 DEBUG [DiagnosisExecutor] Diagnosed Oracle EBS/Forms Load Testing - Forms LT Diagnoser. Analyzing results.
10:40:31,654 DEBUG [DiagnosisExecutor] Diagnosing IE8 XSS Security Settings
10:40:31,655 ERROR [DiagnosisExecutor] Failure found when diagnosing Oracle EBS/Forms Load Testing Forms LT Diagnoser
10:40:31,659 DEBUG [DiagnosisExecutor] Trying to fix IE8 XSS Security Settings
10:40:31,671 ERROR [DiagnosisExecutor] Did not auto-fix the problem.
10:40:31,674 ERROR [DiagnosisExecutor] Suggestion for fixing: Local intranet: XSS Filter is disabled
Trusted sites: XSS Filter is enabled
Internet: XSS Filter is disabled
Restricted sites: XSS Filter is enabled
To Change setting:
Go to Tools > Internet Options and Choose Security Tab
Select the Zone to modify and Press Custom level
Find Enable XSS filter Setting - Select Disable and click Ok
10:40:31,680 DEBUG [DiagnosisExecutor] Diagnosing Sun Java proxy settings
10:40:31,683 DEBUG [DiagnosisExecutor] Diagnosing Helper Service - Helper Service
10:40:32,282 DEBUG [DiagnosisExecutor] Diagnosed Helper Service - Helper Service. Analyzing results.
10:40:32,284 DEBUG [DiagnosisExecutor] Diagnosing Helper Service Installation
10:40:32,287 DEBUG [DiagnosisExecutor] Diagnosing Helper Service Status
10:40:32,289 DEBUG [DiagnosisExecutor] Diagnosing Helper Service Connection
10:40:32,612 DEBUG [DiagnosisExecutor] No Eclipse configuration .log file available.
10:40:32,774 INFO [DiagnosisExecutor] Diagnosis Complete.
Please advise.
regards
CPHello
1/ ATS 9.3 is supported with IE8, not IE9 at the moment
2/ Did you disable xss settings for the four different security zones?
You can also try to add the EBS url to the trusted sites and disable xss settings for that zone only.
Let us know and good luck
JB -
Re: junit test for entity beans ... ejb 3.0
I'm confused. I'm trying to test my entity bean.
I have:
- an entity bean
- a stateless session bean for accessing the entity bean (facade)
- an interface for accessing the the stateless bean
And I'm trying to write a JUnit test class to test this bean. However, I am uncertain as to how to test this (I'm new to EJB 3.0, JBoss and Eclipse).
What would the JUnit test look like? I'm confused as to whether or not I should be injecting the interface/bean/what???
I've tried several variations. I either get "NameNotFound" - not bound exceptions or Null pointer exceptions.
What would the @EJB syntax look like or how would I do it through the context?
For Example:
@EJB private TestFacade myTest; //interface to stateless bean ?
OR
InitialContext ctx = new InitialContext();
TestResultFacadeBean myTest = (TestResultFacadeBean) ctx.lookup("localTest");
I'm confused at to which method I should be using and what object I should be accessing. If I could get either one to work, I'd be happy. :)
How do I ensure my bean is deployed to the container? What do I need to do?
If anyone has a simple example or explanation as to which method I should use and how to use it, I'd be very grateful.
Thanks very much,
LisaDOK, you need to have several layers of testing.
Layer 0. Test the entity beans are deployable (more on this later). Basically, you need to know that all your annotations work. Things to watch out for are multiple @Id fields in one class or @EmbeddedID or @IdClass in conjuction with @ManyToOne, @ManyToMany, @OneToMany, @OneToOne and fun with @JoinTable, @JoinColumn and @JoinColumns. Once you know how these are supposed to work with the spec, it's not too bad to write it correctly each time. But there are some gotchas that will break things later on.
Layer 1. Do the functions in the classes that don't depend on annotations work as expected. Typically, this is just going to be the getters and setters in your entity classes. Of course JUnit best practice says we don't bother testing functions that look like:
public T getX() {
return this.x;
or
public void setX(T x) {
this.x = x;
as there is nothing that can go wrong with them. So in that case, your level 1 tests will just be initial values specified from constructors and verifying that the non-get/set pairs work, and that the getters you have tagged @Transient work (because you've likely put some logic in them)
Layer 2. Test the session bean methods that don't require injection to work.
Layer 3. Test the session bean methods that require injection (Mock Objects). Simulate the injection for yourself, injecting Mock Objects for the entity manager. Then you can confirm that the correct methods are being called in the correct sequences, etc.
[Note this may require some skill in designing the mock. I'm working on developing my own entitymanager mock, and if it looks usefull I'll release it to the world.
Layer 4. Test the session bean methods that require injection (Real entity manager) (See Layer 0)
For this you will need an out of container persistence implementation. Currently Hibernate and Glassfish provide beta versions. You will need a different persistence.xml file that lists all the entities. You will have to use reflection to inject the entity manager(s) that you create from an entity manager factory unless you provide a constructor that takes an EntityManager as a parameter. You may need to use reflection to call any @PostConstruct method if you made it private.
Layer 5. Navigate the relationships in the objects returned from Layer 4 using a database that has been loaded with test data.
I am currently using Layers 0, 1, 2 & 4 to test my session beans and entity beans. -
Load balancing for JSPs and servlets
Hi:
I am using IIS as the proxy server, with the WLS plug-in, to a WLS
cluster. This provides round robin load balancing just fine. Will it
provide weight based load balancing if I set 'weblogic.system.weight'
differently on each server, or is that not relevant for clustering JSPs
and servlets?
Sincerely,
Ashish
Currently the plugins ( for NES, IIS and Apache) just use the round robin
algorithm. the property
weblogic.system.weight is used only be weblogic's replica aware clusterable
RMI/EJB stubs.
To use this property for your JSP/Servlet load balancing you have to use
weblogic server as proxy fron-ending your weblogic cluster.
--Viresh Garg
Ashish Vimal wrote:
> Hi:
> I am using IIS as the proxy server, with the WLS plug-in, to a WLS
> cluster. This provides round robin load balancing just fine. Will it
> provide weight based load balancing if I set 'weblogic.system.weight'
> differently on each server, or is that not relevant for clustering JSPs
> and servlets?
> Sincerely,
> Ashish
-
Testing for IS NOT NULL with left join tables
Dear Experts,
The query is showing the NULL rows in the query below....
Any ideas, advice please? tx, sandra
This is the sql inspector:
SELECT O100321.FULL_NAME_LFMI, O100321.ID, O100404.ID, O100321.ID_SOURCE
, O100404.NAME, O100321.PERSON_UID, O100404.PERSON_UID, O100404.VISA_TYPE
FROM ODSMGR.PERSON O100321
, ODSMGR.VISA O100404
WHERE ( ( O100321.PERSON_UID = O100404.PERSON_UID(+) ) ) AND ( O100404.VISA_TYPE(+) IS NOT NULL )Hi Everyone,
I am understanding alot of what Michael and Rod wrote.... I am just puzzled over the following:
the query below is left joining the STUDENT table to
HOLD table.
The HOLD table - contains rows for students who have holds on their record.
a student can have more than one hold (health, HIPAA, basic life saving course)
BUT, for this query: I'm only interested that a hold exists, so I'm choosing MAX on hold desc.
Selecting a MAX, helps me, bec. it reduces my join to a 1 to 1 relationship, instead of
1 to many relationship.
Before I posted this thread at all, the LEFT JOIN below testing for IS NOT NULL worked w/o
me having to code IS NOT NULL twice....
Is that because, what's happening "behind the scenes" is that a temporary table containing all max rows is being
created, for which Discoverer has no predefined join instructions, so it's letting me do a LEFT JOIN and have
the IS NOT NULL condition.
I would so appreciate clarification. I have a meeting on Tues, for which I have to explain LEFT JOINS to the user
and how they should create a query. I need to come up with rules.
If I feel "clear", I asked my boss to buy Camtasia videocast software to create a training clip for user to follow.
Also, if any Banner user would like me to email the DIS query to run on their machine, I would be glad to do so.
thx sooo much, Sandra
SELECT O100384.ACADEMIC_PERIOD, O100255.ID, O100384.ID, O100255.NAME, O100384.NAME, O100255.PERSON_UID, O100384.PERSON_UID, MAX(O100255.HOLD_DESC)
FROM ODSMGR.HOLD O100255, ODSMGR.STUDENT O100384
WHERE ( ( O100384.PERSON_UID = O100255.PERSON_UID(+) ) ) AND ( O100384.ACADEMIC_PERIOD = '200820' )
GROUP BY O100384.ACADEMIC_PERIOD, O100255.ID, O100384.ID, O100255.NAME, O100384.NAME, O100255.PERSON_UID, O100384.PERSON_UID
HAVING ( ( MAX(O100255.HOLD_DESC(+)) ) IS NOT NULL )
ORDER BY O100384.NAME ASC -
How can I do the load test for EBS 11i
Dear Suport
I start to try OATS.
I have used a Openscript to record the functional test and it works fine for EBS 11i.
However, I cannot directly use the script from Functional Test. Is there have any ways to convert the Functional Testing script to Load Testing script?
Since the fail of using functional script, I create a new Load Testing script in Openscript and record what I do in functional test. However, I got the below error when I record the script.
!ENTRY oracle.oats.scripting.modules.http.proxyRecorder.ProxyRecorderQueueRunnable 2 0 2010-01-06 11:42:07.354
!MESSAGE Could not determine request character set for http://localhost:8088/olt/ConnectToServer.do, referer=http://localhost:8088/olt/BuildScenario.do
!ENTRY oracle.oats.scripting.modules.browser.api.javaHelper.Installer 4 0 2010-01-06 11:42:58.678
!MESSAGE formsRecorder.jar does not exist in C:\Program Files\Java\jre6\lib\ext
I have tried to copy the file, formsRecorder.jar, from C:\OracleATS\OpenScript\openscript_configuration\org.eclipse.osgi\bundles\56\1\.cp\lib to C:\Program Files\Java\jre6\lib\ext
However, the file, formsRecorder.jar, will be deleted when record the test by openscript. (Antivirus too is disabled during record the script).
Do you have any idea for record the Load Testing script by Openscript?
Regards
Sidney WongTry the trial version of HTML Optimizer - it will optimize 50% of your files and may convince you that optimizing is your best chance to get your site to load in IE unless you want to drastically reduce your page file sizes.
-
Require Help on Load Testing for Oracle Applications
Hi,
I have to do a Load Testing on Oracle Application 11i. I am not able to understand from where do I need to start.
Could any one please help on this ?
Ramu.The tool which I am using for this is "Oracle Application Testing Suite".
Any help welcome !
Ramu -
Hi Experts,
Can you suggest me some good books on java , javascript.The books should include the internals of Servlets,JSP,EJB.
Thanks
vishalhttp://forum.java.sun.com/thread.jspa?forumID=54&threadID=756427&start=7
http://forum.java.sun.com/thread.jspa?forumID=54&threadID=751055
http://forum.java.sun.com/thread.jspa?forumID=54&threadID=743429
http://forum.java.sun.com/thread.jspa?forumID=54&threadID=742997&start=11
http://forum.java.sun.com/thread.jspa?forumID=54&threadID=750775&start=24
Just a simple search for this forum....
It took me 10 seconds tofind these..
JJ -
JNDI tree access for code outside servlets and EJBs and JSPs
Can code outside EJBs, Servlets and JSPs have access to the JNDI tree?
For example, in a web application, web.xml has a env-entry declaration which I want to access from a POJO which is called by a JSP in the web app. Is this permissible?Can code outside EJBs, Servlets and JSPs have access
to the JNDI tree?
For example, in a web application, web.xml has a
env-entry declaration which I want to access from a
POJO which is called by a JSP in the web app. Is
this permissible?Yes. Read the JNDI tutorial. -
Strategy for integrating JSF/JSP with EJB?
Both JSF/JSP and EJB seem to be developing independently of each other. What is a good strategy for integrating them? I'm not sure how access my entity/session beans from my web pages.
Follow the MVC architecture. Don't access EJB's from JSF/JSP pages. Here are some basic rules to follow.
1) never put java code in JSP's. JSP's are for viewing data only. They should never contain business logic nor be tied to the business tier.
2) JSP's should always send HTTP requests to servlets. Use the servlets to control the flow of the application and make decisions on which JSP should be returned to the client. Make calls to the EJB's from the servlet to perform business logic. -
Free ebooks for netbean 6.0 with EJB
Hi,
I am a trainee although with a good background in java.
I'm urgently in need of a free ebook for EJB 3.0 with the latest version of Netbean. Pls, help me with one if you have. my email is [email protected]
Again, is container managed bean good for a big project?
Thanks.
EmekaReply same as http://forums.sun.com/thread.jspa?threadID=5322030&tstart=0
Maybe you are looking for
-
Having a problem with gif image not showing up. It will show up in netscape6.2, but not in IE 5.0. Both are using the java 1.4 plugin. They are basic buttons (zoom in, zoom out, etc) and they actions work, just the icons aren't showing. Any help woul
-
I've been away from home the past year, and thus havent logged into my profile during that time on the family iMac. The other profiles on the iMac are all normal, but while my profile username and avatar were the same, when I log in none of my data i
-
How to extract client source ip, which has been embedded in http header?
Can someone please tell me how to extract the client source ip which has been embedded in http header? the web server is running SunOS 5.8 and iPlanet6.0sp6 Thanks.
-
How do i turn off automatic texts when i miss a call?
My iphone is sending out text messages to people when i miss a call from them. How do i turn this feature off? I din't turn it on in the first place either?!!?
-
I created two Automator actions, one to mount a server and one to eject the server. Both actions work fine in the Finder. I saved them both as iCal plug-ins to run the same time every day. While the server is mounted Backup runs and backs up my Mac t