Alexis Li

Greenhorn
+ Follow
since Jul 22, 2002
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Alexis Li

Where did u hear the changes?
Hi,another question that troubles me.
Well, i have a system using VB and EJB.When i update a state to the db using VB and i want to view the state back using CMP bean,it seems that the state has not been updated yet.
The update has not been processed through the EJB
container because i just update it outside using VB(or directly update it through the db client).
Does EJB container sychronize with the db when
I view the update (in fact ejbFindByPrimaryKey() is called).From the ejb spec,it states that
at least one ejbLoad() would be called at the beginning of the first transaction method call.
So synchroniztion doesn't seem to be a problem.
Any comment?
Hi,
What i think is that stateless session beans are often pooled in the container.(would
create new instances when the workload of the container increases).Even though there are many client requests,they are assigned to the same bean instance(I am sure this because only one ejbCreate() is called among the requests.)So,the state is shared and seen by all clients.
This is harmless because we assume that we won't
use the state after the method call.
Regards
Alexis
Some odds about using stateless session bean.
First of all,stateless beans carry no states
between method calls or between clients.The
state would be cleared after the method call.This
is the feature of stateless session bean.
However,when i add a member variable (say a counter) in my stateless session bean and increment the counter by one when "getCounter()"
method is called by a client.
sth like this..
...
public class AStatelessBean implements SessionBean
{
public int counter = 0 ;
public getCounter()
{
counter++ ;
}
...continue here
}
When the first client call "getCounter()",
the output is 1;
When the second client call "getCounter()",
the output is 2;
When the nth client call "getCounter()",
the output is n;
Oddly,the state would be keeped!!
I know that stateless beans are pooled in
the container.But i don't think the state
should be keeped.
Any comment about this? The EJB container i used is JBoss
Regrads,
Alexis
To all,
Actually,Craig Berry doesn't exist in the real world and of course he won't give you anything to review.
Forget him right now!!
Start preparing SCEA partI right out,I am asking myself a question.Do i need to study too deep about the J2EE concepts?Or am I wasting my own time to prepare it because the SCEA exam won't
test it.
For examples-Security. I am preparing this part
by searching the materials like Security architectures and APIs in Java,what is ProtectionDomain,Policy,AccessController,AccessControllerContext,GuardObject? What is the APIs and how these stuffs(JAAS,JSSE,GSS-API,Kerbero V5 addedin J2SE1.4,X509 ,PKCS certificate) can be
used in API levels?
Is that overkill to cover the stuffs in API levels?Or just know the concepts in shallow
is ENOUGH?
Need past-SCEAs to guide me to the right track.
Thx a lot!!
Alexis
/SCJP2,SCWCD
Hi,
I am studying for SCEA part 1 right now.So i think i am suitable to be the previewer.Including me in the list,too.
(alexis_lht@hotmail.com)
/Alexis (SCJP2,SCWCD)
I got SCWCD today with 56 correct answers out of
59.The percentage should be 94.9%..
I don't know why i got 94% instead of 95%.Does Sun truncate all the things after the decimal places without rounding up my mark?
By the way, the exam is very easy if you have
some background on JSP/servlet.I got many tag-lib
questions but all of them are very straight- forward.I even think that i would score 100% after the exam.
Regards,
Alexis
20 years ago