Help coderanch get a
new server
by contributing to the fundraiser

liang sun

Ranch Hand
+ Follow
since May 12, 2001
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by liang sun

how do struts and ejb combine to a web application, have example? thanks
how do struts and ejb combine to a web application
20 years ago
I use struts to develop a web application.
Homepage's URL is http://www.aaaaa.com/web/aaa.do
But our client hope when they type www.aaaa.com, page that IE shows is same as page that is http://www.aaaaa.com/web/aaa.do
Please ask how to solve. Thank you reading and help!
20 years ago
I have code that is related to connection pool.
Context ctx = new InitialContext();
DataSource ds = (DataSource) ctx.lookup("java:comp/env/jdbc/myoracle");
conn = ds.getConnection();
Many of struts's action need call it.
I know 2 ways.
1) Codes is written in every action that use it.
2) encapsulating code into one class's static method.then every action class all call the class'static method
using 1), I fell CODE is redundancy!
using 2), when many user access application,if encapsulating class is single thread, performance will be bad.
or,if I have other choice?
Thanks
[note]: Basically I Don't intend to use mutiple-tie structure,so I directly wirte sql into action class
I have code that is related to connection pool.
Context ctx = new InitialContext();
DataSource ds = (DataSource) ctx.lookup("java:comp/env/jdbc/myoracle");
conn = ds.getConnection();
Many of struts's action need call it.
I know 2 ways.
1) Codes is written in every action that use it.
2) encapsulating code into one class's static method.then every action class all call the class'static method
using 1), I fell CODE is redundancy!
using 2), when many user access application,if encapsulating class is single thread, performance will be bad.
or,if I have other choice?
Thanks
[note]: Basically I Don't intend to use mutiple-tie structure,so I directly wirte sql into action class
20 years ago
Hi,firstly, thank for your reply.
In fact , I know what you said. What I really want to know is as below:
Example:
how many lay should ejb be divided into? How is these lay's relation each other? Have such example?
I want to use struts Framework for web lay , then I want to know which Framework I should use for Ejb that belongs business lay.
Thanks very much!
Evan Sun
I want to use struts Framework for web lay , then I want to know which Framework I should use for Ejb that belongs business lay.
Thanks very much!
Evan Sun
20 years ago
How to get DISK absolute path according URL
Example: convert "http://sun:8080/a.jsp"
to "c:\aaa\a.jsp"
20 years ago
I can program ejb,but I don't konw how to program ejb that communicate with delphi(client) Via corba.
thanks reading
urgency!!! In Japplet, how to make Image as JApplet background image,hope u see completely.

I have get Image Object as blow,then how to do?
Image image=getImage(url,"hill.jpg");

*********************************************************
note!!!
I hope swing GUI on Japplet can still be seen after loading Image
I found if using code as below
/* g.drawImage(0,0,image,this) */
I will only see Image.It means all GUI will disappear but image。
so u will don't tell me answer is It.

Thanks
******************************************************
22 years ago
Thanks BillBailey very much。In fact, what u wrote is understood by me early,but I still don't understand
some question at work。If I found farther question, I will go on posting。

Diamond Sun
I feel difference is if method ejbCreate'parameter can be saved。
is it right?
besides it, has other difference?
1.A session bean(bean1)'s method, with Required Attibute of Transaction
2. it call a entity bean's setXX("")(ex:setAccount(""))
3.call bea1.remove(),then happens the error,as if is not successful in Step 2.
4.when i switch the Required attribute to Support in Step 1, and it Did!
why?
Thanks a lot.