Bean access by specific bean only?

Hi,
We have a few beans that we would like to be accessed from
a specific bean only (let's call bean A), i.e. only bean A can
access those beans.
How can I do that?
The issue being that we want to have the client side access
the system thru the same interface. And the user may screw
up by accessing directly certain back-end beans.
Thanks
Xiaopong

Here at Western Carolina University we have deployed something that might be similar to what you are talking about. We have deployed a PHP based solution that gives specific groups the ability to only edit only certain areas. For Example
We created a Cource called Tech Support
We made a credential of FacultyBody@urn:mace:wcu.edu:techsupport as the editor
When the user clicks on a certain link on a page he is given that credential and has the ability to only edit a certain section.
We would be more than happy to share the code with you, but i don't want to put it out there saying it is an End All Be All solution to your problems, I just want to see if this is along the lines of what you are talking about.
Jacob L. Hackamack
[email protected]

Similar Messages

  • WRT54G: How do I limit access to specific ports, only to local IP's

    Using a WRT54G with Windows XP, and I've setup a web server that I'm still testing. Until I understand the security better, I want to limit access from outside IP's to the port that it's running on, but NOT limit access from the outside to services running on other ports. Is there a way to block a range of IP addresses (or conversely, only permit access for a limited range of IP addresses) to a specific port? So for example (assuming server's on Port 99, and IP address to the outside world is 99.99.99.99: Port 99: Blocked IP Range: 0.0.0.0-99.99.99.98, and 99.99.99.100-255.255.255.255 - OR Port 99: Allowed IP Range: 99.99.99.99 Alternatively, I would be interested to permit access to the web server port, only for certain MAC addresses. Is this pretty secure, and if so, how can this be done? I've poked around the router settings and spent a good deal of time researching this; any help would be greatly appreciated...

    Why do you want to block IP addresses:  "IP Range: 0.0.0.0-99.99.99.98, and 99.99.99.100-255.255.255.255" ?   This is everybody on the web, except your router!    If you really want to block all these people, just unplug your router from your Internet connection.  That is a block that cannot be hacked!
    Normally a server is assigned a fixed LAN IP address.  This address must be outside the DHCP server range of your router, and it cannot end in 0, 1, or 255.
    Next you forward a port (for example, 99) to the server's fixed LAN IP address.
    Data arriving at the Internet port of your WRT54G for port 99 will then be forwarded to your server.  If you have other Internet services (i.e. server B) running on port 1297, then data that arrives at the Internet port of your WRT54G for port 1297 will be directed to server B.   Assuming that you only have port 99 and port 1297 open, then any other unrequested data (for any other port) that arrives at the Internet port of your WRT54G will simply be ignored (and thereby blocked).    If you connect another computer to a LAN port of the WRT54G, connect to the Internet, and request data, then when that data arrives at the Internet port of the WRT54G, it will be allowed to pass, and it will be routed to your computer.
    In summary, by default, all router ports are closed.  The only way to get data through the router is either to open a port (using port forwarding, or alternatively, the UPnP function), or for someone (or some program) on the LAN to request data from the web.
    The router cannot limit the use of a port by MAC address.    When you open a port on your router, you are opening your server to invasion from anyone on the Internet.  So, your server must be setup to protect itself.   Rather than limiting server use by MAC address (which can be faked), your server should be setup to require a user name and password. 

  • Problems accessing fields in a CMP entity bean from a session bean

    Hello everybody,
    I'm getting the next problem: when I try to access a field in a CMP entity bean that I have instantiated from a session bean (trhoug entitybean.getNameOfField), I get the error "the entity bean does not exist in the database".
    This entity bean is accessing a table in an external database (not the DB of the WAS), but I know that it's getting the correct data from the table, since  I check the entitybean.size() and the entitybean.findByPrimaryKey(), and I get the right information. For some reason, the only thing that it doesn't work in the entity bean are the getter/setter methods (I created them automatically after having created the entity fields).
    I access the entity bean through its local interface...
    I know it's really difficult to give an answer with so few details, but... does anybody think I forgot something important to configure??
    Thank very much in advance!!
    Isidro

    getter and setter methods for cmp-fields are abstract.
    getter and setter methods for cmr-fields are abstract.
    "John Lee" <[email protected]> wrote:
    >
    Hi:
    Which method in a CMP Entity bean should be abstract? just only SetXXX
    and
    GetXXX?
    Thanks!
    John Lee

  • NON-transactional session bean access entity bean

    We are currently profiling our product using Borland OptmizeIt tool, and we
    found some interesting issues. Due to our design, we have many session beans which
    are non transactional, and these session beans will access entity beans to do
    the reading operations, such as getWeight, getRate, since it's read only, there
    is no need to do transaction commit stuff which really takes time, this could
    be seen through the profile. I know weblogic support readonly entity bean, but
    it seems that it only has benefit on ejbLoad call, my test program shows that
    weblogic still creates local transaction even I specified it as transaction not
    supported, and Transaction.commit() will always be called in postInvoke(), from
    the profile, we got that for a single method call, such as getRate(), 80% time
    spent on postInvoke(), any suggestion on this? BTW, most of our entity beans are
    using Exclusive lock, that's the reason that we use non-transactional session
    bean to avoid dead lock problem.
    Thanks

    Slava,
    Thanks for the link, actually I read it before, and following is what I extracted
    it from the doc:
    <weblogic-doc>
    Do not set db-is-shared to "false" if you set the entity bean's concurrency
    strategy to the "Database" option. If you do, WebLogic Server will ignore the
    db-is-shared setting.
    </weblogic-doc>
    Thanks
    "Slava Imeshev" <[email protected]> wrote:
    Hi Jinsong,
    You may want to read this to get more detailed explanation
    on db-is-shared (cache-between-transactions for 7.0):
    http://e-docs.bea.com/wls/docs61/ejb/EJB_environment.html#1127563
    Let me know if you have any questions.
    Regards,
    Slava Imeshev
    "Jinsong HU" <[email protected]> wrote in message
    news:[email protected]...
    Thanks.
    But it's still not clear to me in db-is-shared setting, if I specifiedentity
    lock as database lock, I assumed db-is-shared is useless, because foreach
    new
    transaction, entity bean will reload data anyway. Correct me if I amwrong.
    Jinsong
    "Slava Imeshev" <[email protected]> wrote:
    Jinsong,
    See my answers inline.
    "Jinsong Hu" <[email protected]> wrote in message
    news:[email protected]...
    Hi Slava,
    Thanks for your reply, actually, I agree with you, we need to
    review
    our db
    schema and seperate business logic to avoid db lock. I can not say,guys,
    we need
    to change this and that, since it's a big application and developedsince
    EJB1.0
    spec, I think they are afraid to do such a big change.Total rewrite is the worst thing that can happen to an app. The
    better aproach would be identifying the most critical piece and
    make a surgery on it.
    Following are questions in my mind:
    (1) I think there should be many companies using weblogic serverto
    develop
    large enterprise applications, I am just wondering what's the maintransaction/lock
    mechanism that is used? Transional session / database lock,
    db-is-shared
    entity
    I can't say for the whole community, as for my experience the standard
    usage patthern is session fasades calling Entity EJBs while having
    Required TX attribute plus plain transacted JDBC calls for bulk
    reads or inserts.
    is the dominant one? It seems that if you speficy database lock,
    the
    db-is-shared
    should be true, right?Basically it's not true. One will need db-is-shared only if thereare
    changes
    to the database done from outside of the app server.
    (2) For RO bean, if I specify read-idle-timeout to 0, it shouldonly
    load
    once at the first use time, right?I assume read-timeout-seconds was meant. That's right, but if
    an application constantly reads new RO data, RO beans will be
    constantly dropped from cache and new ones will be loaded.
    You may want to looks at server console to see if there's a lot
    of passivation for RO beans.
    (3) For clustering part, have anyone use it in real enterpriseapplication?
    My concern, since database lock is the only way to choose, how aboutthe
    affect
    of ejbLoad to performance, since most transactions are short live,if high
    volume
    transactions are in processing, I am just scared to death about
    the
    ejbLoad overhead.
    ejbLoad is a part of bean's lifecycle, how would you be scared ofit?
    If ejbLoads take too much time, it could be a good idea to profile
    used SQLs. Right index optimization can make huge difference.
    Also you may want cosider using CMP beans to let weblogic
    take care about load optimization.
    (4) If using Optimization lock, all the ejbStore need to do
    version
    check
    or timestamp check, right? How about this overhead?As for optimistic concurrency, it performs quite well as you can
    use lighter isolation levels.
    HTH,
    Slava Imeshev
    "Jinsong Hu" <[email protected]> wrote in message
    news:[email protected]...
    We are using Exclusive Lock for entity bean, because of we do
    not
    want
    to
    load
    data in each new transaction. If we use Database lock, that means
    we
    dedicate
    data access calls to database, if database deadlock happens,
    it's
    hard
    to
    detect,
    while using Exclusive lock, we could detect this dead lock in
    container
    level.
    The problem is, using Exclusive concurrency mode you serialize
    access to data represented by the bean. This aproach has negative
    effect on ablity of application to process concurrent requests.As
    a
    result the app may have performance problems under load.
    Actually, at the beginnning, we did use database lock and usingtransactional
    The fact that you had database deadlocking issues tells that
    application logic / database schema may need some review.
    Normally to avoid deadlocking it's good to group database
    operations mixing in updattes and inserts into one place so
    that db locking sequence is not spreaded in time. Moving to
    forced serialized data access just hides design/implementation
    problems.
    session bean, but the database dead lock and frequent ejbLoad
    really
    kill
    us,
    so we decided to move to use Exclusive lock and to avoid dead
    lock,
    we
    change
    some session bean to non-transactional.Making session beans non-transactions makes container
    creating short-living transactions for each call to entity bean
    methods. It's a costly process and it puts additional load to
    both container and database.
    We could use ReadOnly lock for some entity beans, but since weblogicserver will
    always create local transaction for entity bean, and we found
    transaction
    commit
    is expensive, I am arguing why do we need create container leveltransaction for
    read only bean.First, read-only beans still need to load data. Also, you may seeRO
    beans
    contanly loading data if db-is-shared set to true. Other reason
    can
    be
    that
    RO semantics is not applicable the data presented by RO bean (forinstance,
    you have a reporting engine that constantly produces "RO" data,
    while
    application-consumer of that data retrieves only new data and neverasks
    for "old" data). RO beans are good when there is a relatively stable
    data
    accessed repeatedly for read only access.
    You may want to tell us more about your app, we may be of help.
    Regards,
    Slava Imeshev
    I will post the performance data, let's see how costful
    transaction.commit
    is.
    "Cameron Purdy" <[email protected]> wrote:
    We are currently profiling our product using Borland
    OptmizeIt
    tool,
    and we
    found some interesting issues. Due to our design, we have
    many
    session
    beans which
    are non transactional, and these session beans will access
    entity
    beans
    to
    do
    the reading operations, such as getWeight, getRate, since
    it's
    read
    only,
    there
    is no need to do transaction commit stuff which really takes
    time,
    this
    could
    be seen through the profile. I know weblogic support readonly
    entity
    bean,
    but
    it seems that it only has benefit on ejbLoad call, my test
    program
    shows
    that
    weblogic still creates local transaction even I specified
    it
    as
    transaction not
    supported, and Transaction.commit() will always be called
    in
    postInvoke(),
    from
    the profile, we got that for a single method call, such as
    getRate(),
    80%
    time
    spent on postInvoke(), any suggestion on this? BTW, most of
    our
    entity
    beans are
    using Exclusive lock, that's the reason that we use
    non-transactional
    session
    bean to avoid dead lock problem.I am worried that you have made some decisions based on an improper
    understand of what WebLogic is doing.
    First, you say "non transactional", but from your description
    you
    should
    have those marked as tx REQUIRED to avoid multiple transactions
    (since
    non-transactional just means that the database operation becomesits
    own
    little transaction).
    Second, you say you are using exclusive lock, which you shouldonly
    use
    if
    you are absolutely sure that you need it, (and note that it
    does
    not
    work in
    a cluster).
    Peace,
    Cameron Purdy
    Tangosol, Inc.
    http://www.tangosol.com/coherence.jsp
    Tangosol Coherence: Clustered Replicated Cache for Weblogic
    "Jinsong Hu" <[email protected]> wrote in message
    news:[email protected]...
    >

  • JNDI Naming Problem accessing Session Bean from Message Driven Bean

    Hi,
         I am facing a very strange problem in JNDI look up accessing a Session Bean from a Message Driven Bean. I have a session fa�ade bean(Remote Bean) which is being called from Struts Action class getting the home reference from the ServiceLocator (I have implemented ServiceLocator pattern to obtain JNDI reference for all EJBs). When I am calling the session fa�ade EJB from the Struts Action class everything is working fine.
         But when I am trying to call the same EJB from my Message Driven Bean, I am getting a JNDI exception (NameNotFoundException - No Object bound to name �java:comp/env/ejb/EJBJNDIName�). I am trying to get the remote reference from the same ServiceLocator which is successfully providing me a reference while calling from the struts action class. But the same ServiceLocator is not able to provide me a reference while calling from the Message Driven Bean. If I use the JNDI name directly like �EJBJNDIName� in the lookup it is working fine. The lookup for the name is working fine and I am able to call the Session Fa�ade bean with that reference.
         I am really not sure what exactly the problem is. If I have any problem in the ServiceLocator, it should have given me the same error while calling from Struts Action class. But it is working fine with the full name �java:comp/env/ejb/EJBJNDIName� calling from the struts action class. I am not sure whether Message Driven Bean has something to do with it. Why I am not able to get a reference of the EJB with the full name? Please Help.
    Thanks
    Amit

    Hi Bhagya,
    Thanks for your response. I think from EJB container we can call Local EJBs with the full JNDI name. The session facade bean which is being called is a remote bean. From the session facade bean I am calling a local stateless session bean for database access. I am getting the reference of the local EJB from my session facade bean with full JNDI name "java:comp/env/ejb/EJBJNDIName". It is working fine with out any problem. My servicelocator is able to provide me the reference of the local EJB from the session facade remote bean with Full JNDI name. I am only having this problem calling from the MDB. I am really not sure whether what is causing it?
    Thanks
    Amit

  • Local bean access via JNDI returns a proxy object?

    Hi,
    I am using JBoss, and trying to access a local bean from another bean. One would think simple enough no, with the following code adequate:
    Context initialContext = new InitialContext();
    CartHome cartHome = (CartHome) initialContext.lookup(&#8220;java:comp/env/ejb/cart&#8221;);Which returns the home interface, right, but no in fact a $Proxy77 is returned. Can anyone tell me why this is? Or a solution please.
    Thanks in advance.
    Mike

    Thanks, it works. But do you think calling the executeQuery from a backing bean is against any ADF related coding standards? Should that call be only in Application Module? Please comment.

  • Accessing XI Repository Beans

    Hi,
    I'm going to query some of the Session stateless beans from XI like sap.com/com.sap.xi.directory/DirQueryServiceBean.
    This gives an object of com.sap.aii.ib.sbeans.query.QueryServiceHome_Stub. I can only cast this object to a QueryServiceHome object, which has a create method. The create method on QueryServiceHome return a  remote object.
    Context ctx = new InitialContext(env);
    // Look up an object
    Object obj = ctx.lookup(name);
    // Print it
    out.println(name + " is bound to: " + obj + " type " + obj.getClass());
    QueryServiceHome home= (QueryServiceHome) obj;
    out.println("-home found-");
    QueryServiceHome_Stub stub = (QueryServiceHome_Stub)home.create();
    I get -home found- printed, but the I get at ClassCastException.
    Does any body have an answert to how I can get access to the bean and query it for information.

    Hi Daniel,
    In general, when you want to use some application, at least you must have the classes that you access in your client's classpath. That is how it works. Otherwise, can you explain me how you have access to the QueryServiceHome interface but not to the QueryService interface?
    In particular in your case you must find the application "com.sap.xi.directory" and include its jars in your client's classpath. Then proceed as already described.
    Best regards,
    Vladimir

  • Bean Access

    Hi!
    I'm working with JBuilder7 and Weblogic7.
    I wanna configure my application to access my Entity Bean (BMP) for read simultaneously. I mean: I'd like to have 2 Session Beans calling the get methods for the same Entity at the same time.
    The container has only one instance for this entity.
    Please, could any body help me?
    * The session is BMT and the database is not shared.

    Could anybody help me?

  • Remote Delta link setup problem with Bean / Access Service

    Hello,
    I am trying to setup Remote Delta Link (RDL) between two portals. (Both portals same version - EP 7.0 EHP1 SP 05 - are in the same domain)
    I already have the Remote Role Assignment working without any issues.
    The following have been done successfully:
    1. Same user repository has been setup for both the portals
    2. Setup trust between producer and consumer (SSO working fine)
    3. Producer added and registered succesfully on consumer
    4. Permissions setup on producer and consumer
    4. pcd_service user with required UME actions setup
    I am able to see all the remote content in the Consumer portal.
    When I try to copy the remote content and paste it as local content, I am getting the following error:
    Could not create remote delta link to object 'page id'. Could not connect to the remote portal. The remote portal may be down, there may be a network problem, or your connection settings to the remote portal may be configured incorrectly.
    After increasing the log severity, I am able to see the following in Default Trace:
    com.sap.portal.fpn.transport.Trying to lookup access service (P4-RMI) for connecting to producer 'ess_int' with information: com.sap.portal.fpn.remote.AccessServiceInformation@31c92207[connectionURL=hostname.mycompany.com:50004, shouldUseSSL=false, RemoteName=AccessService]
    com.sap.portal.fpn.transport.Unable to lookup access service (P4-RMI) with information: com.sap.portal.fpn.remote.AccessServiceInformation@31c92207[connectionURL=hostname.mycompany.com:50004, shouldUseSSL=false, RemoteName=AccessService]
    AbstractAdvancedOperation.handleDirOperationException
    [EXCEPTION]
    com.sap.portal.pcm.admin.exceptions.DirOperationFailedException: Could not retrieve the bean / access service to connect with producer
    Could not retrieve the bean / access service to connect with producer
    Like you can see above, there is some bean / access service which is not retrieved successfully. I am not sure if this is a permission problem on the consumer.
    I have checked that the P4 ports are configured correctly (standard - not changed) and I am able to telnet from producer to consumer (and vice versa) on the P4 port.
    I am stuck at this point and am not able to find any information on this.
    I would really appreciate if some one can point me in the right direction.
    Thank you for reading.
    - Raj

    Hi Raj,
    Please check your config of the P4 port on the producer.  Is it really 50004 (check SystemInfo of the producer)?
    I do think there's a problem with the P4 communication since RDL requires P4 connection.
    Do you have load balanced consumer-producer connection? Please refer to this blog for further details
    Little known ways to create a load balanced Consumer – Producer connection in a FPN scenario
    Regards,
    Dao

  • Java Bean access in a JSP Tag handler class

    Hello Everybody,
    I am trying to access my java bean(ErrorBean.java) in th doEndTag() method of the tag handler class(MyTagHandler.java) and iam getting an "CLASSCAST EXCEPTION"
    I am doing it like this in the tag handler class.
    MyBeans.ErrorBean errorBean = (MyBeans.ErrorBean)pageContext.getSession().getAttribute("ErrorBean");
    Where MyBeans is the package in which my Error Bean is and iam placing the ErrorBean object in the session object before it comes to the jsp page where i have the jsp Custom tag:
    <%@ taglib uri="/WEB-INF/taglib.tld" prefix="errors" %>
    <errors:message/>
    <%@ include file="footer.jsp"%>
    I was of the opinion that i was casting it right...can anyone help me to find ...where iam doing it wrong...its really URGENT ..PLEASE

    Friend that did not work either ...
    u know what...the ErrorTagHandler class is comiling fine with out errors but in the jsp page when the custom tag is hit..this error is showing up when i see the server log.
    can you throw some light on this..
    thanks..
    Firasath

  • Cross Bean Access gives me NoClassDefFoundError error

    Hi Everyone,
    I am trying to access a CMP bean from a session bean and when I try to
    access it, I get the "NoClassDefFoundError". I am attaching the code here
    as a .zip file. please someone have a look at it and let me know where I
    went wrong, I looked at all the examples provided by the Iplanet people in
    the ias-samples/j2eeguide directory, I could not get a satisfied result till
    now. I tried to set the classpath using the kregedit tool and modifying the
    classpath under the java node. I even tried with extracting the other bean
    class files and dumping them in the classes directory of the IPlanet. still
    my bean is unable to look for the class.. I also tried by deploying my first
    bean and then deploying this bean, but still no luck. same error. I
    modified the ejb-jar.xml and the ias-ejb-jar .xml files and gave the bean
    references and still then my luck doesn;t favour me.
    I am pasting the error what I am getting when I try to deploy the bean
    Customer which in turn accesses the UserMaster bean.
    D:\final\Customer\assemble\jar>iasdeploy deployapp j2eeguide-customerEjb.jar
    iasdeploy for iPlanet Application Server 6.0 SP3 Test Drive
    Connected to LDAP server on shravan port 389
    208.28.177.39:null
    208.28.177.39:10 kas> deployment action ''J2EEInstallEar''
    (d:/iplanet/ias6/ias/JAR/j2eeguide-customerEjb.jar) running.
    208.28.177.39:j2eeappreg -nodeprecated
    d:/iplanet/ias6/ias/JAR/j2eeguide-customerEjb.jar 2>&1
    208.28.177.39:10 Connected to LDAP server on shravan port 389
    208.28.177.39:10 ------ Register EJB Module ------
    208.28.177.39:10 ------Register Enterprise Beans: ------
    208.28.177.39:10 MyCustomer
    208.28.177.39:10 java.lang.NoClassDefFoundError:
    com/se/sales/customer/UserMaster
    208.28.177.39:10 at java.lang.Class.getMethods0(Native Method)
    208.28.177.39:10 at java.lang.Class.getMethods(Class.java:718)
    208.28.177.39:10 at
    com.netscape.server.deployment.EjbMetaUtil.addMethods(Unknown Source)
    208.28.177.39:10 at
    com.netscape.server.deployment.EjbJARGDSUtil.setupMethodFromClass(Unknown
    Source)
    208.28.177.39:10 at
    com.netscape.server.deployment.EjbReg.registerEjbJar(Unknown Source)
    208.28.177.39:10 at
    com.netscape.server.deployment.J2eeAppReg.run(Unknown Source)
    208.28.177.39:10 at
    com.netscape.server.deployment.J2eeAppReg.main(Unknown Source)
    208.28.177.39:10 j2eeappreg done.
    208.28.177.39:20 kas> deployment action ''J2EEInstallEar''
    (d:/iplanet/ias6/ias/JAR/j2eeguide-customerEjb.jar) complete.
    208.28.177.39:
    Finished deploying to 208.28.177.39 at [18/Sep/2001 11:50:54]
    Thanks everyone in advance
    Shravan
    [Attachment UserMaster.zip, see below]
    [Attachment Customer.zip, see below]

    Hi, I have exact the same problem. Have you got any answer for this problem yet? Please forward it to me if you have one. Many thanks.

  • Accessing Managed Session Bean in Servlet Filter

    I wrote a Servlet Filter to handle user authentication. Now I'm trying to access my Managed Session Bean in the filter in order to save the current user. Unfortunately the Session Bean is created after the Filter executes for the first time.
    I'm trying to access the Session Bean in this way:
    (SessionBean) FacesContext.getCurrentInstance().getExternalContext().getSessionMap().get("sessionBean");
    In this case getExternalContext() is equals null.
    Is there any way to create the Session bean before the filter executes or any other ideas how to handle this?
    I already searched around the internet but couldnt figure out something.
    Thanks guys,
    Paul

    Ok, fixed it like this. Works perfect. JSF finds and uses the handmade Session Bean as well.
    if(request.getSession().getAttribute(BeanNames.SESSION_SCOPE_BEAN) == null) {
         SessionBean sessionBean = new SessionBean();
         request.getSession().setAttribute(BeanNames.SESSION_SCOPE_BEAN, sessionBean);
    }Thanks,
    Paul

  • ADF BC how to access session backing bean value in servlet

    Hi everyone,
    How do I access session backing bean value in a servlet?

    Frank, thanks for your reply.
    I'm not sure how I can incorporate this example into my situation. Let me explain more detail about my problem.
    "servlet" in my post here actually means a custom servlet I wrote for rendering an image that is stored in db as ordimage. In this servlet, I get hold of my appmodule by using Configuation.createRootApplicationModule(). By doing so (If I'm not wrong) a new database session/connection is created. What I'm going to achieve is set application context for this new session/connection in db with the data stored in a session backing bean in the view layer.
    I can pass the required data to the servlet thru url parameter, but I don't want to do it this way for the reason that the data may contains sensitive information.
    I hope I have explained myself well.
    Message was edited by:
    bsmt

  • Access Limitations of Bean

    I added a Print class that implements Printable in the declaration section of a JSP. The print() method is part of the class and works fine, but the declaration section will not recognize the bean that contains the data to print(the rest of the page does).
    I need to instanciate an object the print class inorder to print. Should I move the Print class out of the JSP? If so, how would I access the bean in the print() method. Any suggestions on best practices?

    Is bean access not allowed from a class/method declared in the declaration section?

  • Concurrent entity beans access

    I have failed to come up with a workable solution for concurrent entity bean access on the SUN reference implementation together with cloudscape.
    I have created a test case and a webpage which describes my problem. If anyone can come up with a working solution (must work on the RI) I would be very thankful.
    Please have a look at
    http://www.offermanns.de/~rolf/ejb-concurrency/
    and tell me what you think.
    -Rolf

    Hi,
    I thought that this is a problem. But this isn't just
    about this pattern. It is a general question about how
    to get concurrent access to entity beans to work on
    the RI.Entity Beans are the shared components , same instance is being shared between all the concurrent users so if the same component is a part of the longer transaction then the component can lead to the data corruption and to avoid that you have to set the ISOLATION Level for the concurrent running long transactions.Remember the Entity beans are shared components and are shared between all the cliens not like the Sessoin BEans where different clients can get different instances.
    I tried to alter the cloudscape setting to SERIAZABLE,
    but that won't help. (from the cloudscape log, it
    seems, that the container switches back to READ_COMMIT
    before every transaction.You dont have to change the setting in the Cloudscape,you require add the Isolation-level tag in the deployment descriptor.These can take the values as
    1)READ_COMMITED
    2)READ_UNCOMMITTED
    3)REPEATABLE_READ
    4)SERIALIZABLEI hope this will help.
    Regards
    Vicky

Maybe you are looking for