Servlets in Multi tier Architecture

Hi
We plan to use a three tier architecture with
Client --- Applet (JDK 1.2)
Middle tier -- WebServer and servlets
Database Server -- Oracle 8i
Our application should have data entry for several (5 - 12 ) tabs each consisting of around 15 fields . A few Jtables will also be used .
Arounf 5 to 10 validations or queries are required to be done with the database in the applet. Around 300 entries will be made by 12 different users in a day.
Is it advisable to use the above architecture ?
Is it required to use Enterprise JavaBeans ?
Will the use of servlets bring down the validations ?
Overall is our architecture feasible for the requirement ?
We will be greatfull to your suggestions
Please mail to the folowing id also
[email protected]
N.Suresh
null

<joemessina> wrote in message news:202463294@jserv5...
Scenario
I am currently using a combined-tier architecture (Servlets & EJB in same WLS instance) on a WLS Cluster.
I would like to keep to option of going to a multi-tier architecture (Servlets & EJB in different WLS instances) on a WLS Clusteropen without having to change application code.
Questions
1. If I code & deploy my EJB?s with remote interfaces only, will WLS automatically make local method calls to my co-located EJB?swithout me having to set up the local interfaces?
It depends on version of weblogic. 5.1, 6.5 and 7.0 did it automatically.
8.1 requires to set it in weblogic-specific bean's descriptor (weblogic-ejb-jar.xml).
2. If so, is there any reason to ever code & deploy local interfaces other than for entity beans?No, there is no such reason.
3. Is there a standard practice regarding the coding & deployment of local & remote interfaces for combined-tier & multi-tierarchitectures?
Sure. Don't use local interfaces except when defining CMR relationships.
I know this all sounds very affirmative, but that fact is that by the time
local interfaces arrived, all J2EE vendors with weblogic pioneering already
provided implicit and explicit colocation optimization, that was the main
Local's promise... So, Local's use is limited to defining CMR.
Regards,
Slava Imeshev

Similar Messages

  • Servlets in three tier Architecture

    Hi
    We plan to use a three tier architecture with
    Client --- Applet (JDK 1.2)
    Middle tier -- WebServer and servlets
    Database Server -- Oracle 8i
    Our application should have data entry for several (5 - 12 ) tabs each consisting of around 15 fields . A few Jtables will also be used .
    Arounf 5 to 10 validations or queries are required to be done with the database in the applet. Around 300 entries will be made by 12 different users in a day.
    Is it advisable to use the above architecture ?
    Is it required to use Enterprise JavaBeans ?
    Will the use of servlets bring down the performance?
    Overall is our architecture feasible for the requirement ?
    We will be greatfull to your suggestions
    Please also mail to [email protected]
    N.Suresh

    Hello,
    We plan to use a three tier architecture with
    Client --- Applet (JDK 1.2)
    Middle tier -- WebServer and servlets
    Database Server -- Oracle 8i
    Our application should have data entry for several (5 - 12 ) tabs each consisting of around 15 fields . A few Jtables will also >be used .
    Arounf 5 to 10 validations or queries are required to be done with the database in the applet. Around 300 entries will be made >by 12 different users in a day.Have you considered using Business Components for Java to develop your application? From what you have described about your application BC4J seems to be the ideal candidate.
    Is it advisable to use the above architecture ?I see not limitation with your architecture. The only thing to keep in mind is that you should use applets only if you absolutely need to. Overall development and maintenance is much easier if you are just using servlets and JSPs.
    Is it required to use Enterprise JavaBeans ?See below.
    Will the use of servlets bring down the performance? No.
    Overall is our architecture feasible for the requirement ?If you had not needed applets then I'd have recommended the following:
    Scenario #1
    Client --- Browser
    Presentation Server -- Standard WebServer(Apache,OAS etc) running Servlets, JSPs talking to BC4J classes available on the local classpath
    Database Server -- Any Oracle Database
    Simplicity and ease of maintenance are some of the benefits of the above model. The limitation in the above scenario is that you cannot have a thin remote client(Java application or applet).
    If you want a remote client then I'd recommend:
    Scenario #2
    Client --- Browser|Applet (if you know you have a small number of users then you can go for a client side Application too)
    Presentation Server -- Standard WebServer(Apache,OAS etc) running Servlets, JSPs
    Application Server -- Standard AppServer (VisiBroker|OAS|JServer) running BC4J components as EJB session beans or CORBA server objects
    Database Server -- Any Oracle Database
    In this scenario the servlets|JSPs will be going over IIOP to talk to the application server. On the client side, the BC4J framework ensures that the network traffic is minimized and also the client side Java application or applet is as thin as it can be.
    Whether you go with scenario#1 or scenario#2 the cool thing about using BC4J is that you have to write your business logic only once and then you can deploy it in multiple platforms(local,EJB,CORBA) and access it from different clients(JSP,Servlets,Java,XML...) without modifying your business logic.
    Hope this helps.
    Please let me know if you have any questions.
    Regards,
    Arun
    null

  • Number of scokets for httpsession replication in multi-tiered architecture

              In the weblogic's document on clustering the
              section "Configuration Notes for Multi-tier Architecture" states
              In particular, during peak socket usage, each WebLogic Server in
              the cluster that hosts servlets and JSPs may potentially use a
              maximum of:
              Two sockets for replicating HTTP session states between primary
              and secondary servers.
              I don't understand why 2 sockets are required. Won't just one do the job. What's
              the 2nd one for?
              pradeep
              

              hi,
              The doc mentions toally 3 sockets. I have pasted the doc
              content FYI
              "In particular, during peak socket usage, each WebLogic Server in the cluster
              that hosts servlets and JSPs may potentially use a maximum of:
              Two sockets for replicating HTTP session states between primary and secondary
              servers, plus
              One socket for each WebLogic Server in the EJB cluster, for accessing remote objects
              Toally 3 sockets. 2 for httpsession replication and 1 for accessing remote objects.
              Why 2 sockets are required for replicating HTTP session states between primary
              and secondary servers
              pradeep
              Kumar Allamraju <[email protected]> wrote:
              ><!doctype html public "-//w3c//dtd html 4.0 transitional//en">
              ><html>
              >the docs also says
              ><p>One socket for replicating HTTP session states between primary and
              >secondary
              >servers, plus
              ><p>One socket for each WebLogic Server in the EJB cluster, for accessing
              >remote objects
              ><p>pradeep bhat wrote:
              ><blockquote TYPE=CITE>In the weblogic's document on clustering the
              ><br>section "Configuration Notes for Multi-tier Architecture" states
              ><p>In particular, during peak socket usage, each WebLogic Server in
              ><br>the cluster that hosts servlets and JSPs may potentially use a
              ><br>maximum of:
              ><br>Two sockets for replicating HTTP session states between primary
              ><br>and secondary servers.
              ><p>I don't understand why 2 sockets are required. Won't just one do the
              >job. What's
              ><br>the 2nd one for?
              ><p>pradeep</blockquote>
              ></html>
              >
              

  • How to install oracle applicatons in a three tier architecture

    Hi,
    i want to install oracle apps in a three tier architecture?
    application tier -- middle tier
    database tier -- database tier
    Any steps or a meta link document
    Regards
    Sudharshan

    Hi,
    http://download.oracle.com/docs/cd/B34956_01/current/acrobat/120oaig.pdf
    Pages 2-10 and Pages 2-19 don't specify this ???
    They indicate only having to install with rapidwiz 1 time (as root user if appl/ora accounts setup) ??It is mentioned in Page 1-2
    Release 12 utilizes the conf_<SID>.txt file in certain situations, for example where the database has not yet been created. The configuration file is also employed in multi-node (distributed) installs, where you only need to enter the install information once, on one machine, and can then copy the configuration file to other machines as required.
    If you are installing in an environment where different machines are used to support the database and Applications tiers (as is typically the case), you would run Rapid Install on each machine in turn, starting with the database machine.
    Regards,
    Hussein

  • Three tier architecture questions

    Hello,
    My question is in regards to using Toplink in a three tier architecture situation. If I wish to send an object A which has a collection of Bs and B has a collection of C ( A nested object structure with two or more levels of indirection). Is the best solution to have the named query be part of a unit of work so that even if on the client side somebody unknowingly were to make the modification to one of the entity objects ( a POJO) the shared session cache would not be affected ?
    This is assuming the client side HTTP layer and the RMI/EJB layer are on different JVMs.
    Some of the other suggestions I have heard is to retrieve it from the shared session cache directly and if in case I need to modify one or more of the objects do a named query lookup on that object alone and then proceed to register that object in a unit of work and then commit the changes.
    Also the indirection would have to be utilised before the data objects are sent to the Servlet layer I presume ?(That is if I do a a.getAllOfBObjects() on the servlet side I would get a nullpointer exception unless all of B were already instatiated on the server side). Also when the objects are sent back to the server do I do a registerObject on all the ones that have changed and then do a deepMergeClone() before the uow.commit() ?
    Thanks,
    Aswin.

    Aswin,
    If your client is remote to the EJB tier then all persistent entities are detached through serialization. In this architecture you do not need to worry about reading and modifying the shared instance as it never the one being changed on the client (due to serialization).
    Yes, you do need to ensure that all required indirect relationships are instantiated on the server prior to returning them from the EJB call.
    Yes, you do need to merge the changes of the detached instance when returned to the server. I would also recommend first doing a read for the entity being merged (by primary key) on the new UnitOfWork prior to the merge. This will handle the case where you are merging into a different node of the cluster then where you read as well as allowing you to check for the case where the entity no longer exists in the database (if the read returns null then the merge will result in an INSERT and this may not be desired).
    Here is an example test case that does this:
        public void test() throws Exception {
            Employee detachedEmp = getDeatchedEmployee("Jill", "May");
            assertNotNull(detachedEmp);
            // Remove the first phone number
            PhoneNumber phone = detachedEmp.getPhoneNumber("Work");
            assertNotNull("Employee does not have a Work Phone Number",
                          detachedEmp.getPhoneNumber("Work"));
            detachedEmp.removePhoneNumber(phone);
            UnitOfWork uow = session.acquireUnitOfWork();
            Employee empWC = (Employee) uow.readObject(detachedEmp);
            if (empWC == null) { // Deleted
                throw new RuntimeException("Could not update deleted employee: " + detachedEmp);
            uow.deepMergeClone(detachedEmp);
            uow.commit();
         * Return a detached Employee found by provided first name and last name.
         * Its phone number relationship is instantiated.
        public Employee getDeatchedEmployee(String firstName, String lastName) {
            ReadObjectQuery roq = new ReadObjectQuery(Employee.class);
            ExpressionBuilder builder = roq.getExpressionBuilder();
            roq.setSelectionCriteria((builder.get("firstName").equal(firstName)).and(builder.get("lastName").equal(lastName)));
            Employee employee = (Employee)session.executeQuery(roq);
            employee.getPhoneNumbers().size();
            return (Employee)SerializationHelper.serialize(employee);
        }One other note: In these types of application optimistic locking is very important. You should also make sure that the locking field(s) are mapped into the object and not stored only in the TopLink cache. This will ensure the locking semantics are maintained across the detachment to the client and the merge back.
    Doug

  • Using Basic or Multi-tier configuration for WLS Clusters...

    Ok,
              The scenario is: I'm using WLS6.1 (hopefully, version doesn't matter here)
              with three instances clustered. Each instance provides all Services:
              Servlets / JSPs/ EJBs / Database communication... I'm using the Basic
              configuration described on the BEA documentation....
              Now, I want to move forward to a Multi-tier configuration, where the first
              layer will serve Servlets and JSPs and the second layer will serve EJBs.
              The problem: On the first scenario, I was looking EJBs with the Default
              InitialContext() constructor without the environment, since everybody was on
              the same JVM...
              What do I have to do, so my Servlets start looking for EJBs on the second
              cluster now? Do I have to re-write every single lookup? Can I use a
              jndi.properties file on the first layer - on the presentation tier?
              Thanks in Advance,
              Marcelo.
              

              Thanks Patrick!
              But my actual problem starts here. The Servlets aren't mine. We have to support
              applications which run atop our product(which is a bunch of beans+RMI Objects
              running on the top of WLS) in a backward compatible way with a standalone.
              Will try and make a post if I can find a 'configurable' way out.
              Harish
              Robert Patrick <[email protected]> wrote:
              >Put the other server's PROVIDER_URL in a system property, property file,
              >whatever and
              >have the servlets explicitly use it when creating the InitialContext
              >to talk with the
              >other server...
              >
              >Harish Vajha wrote:
              >
              >> Hi Cameron,
              >>
              >> A -Djava.naming.provider.url nor jndi.properties would work. The problem
              >is like
              >> this:
              >> Say I have two WL servers hosting just EJBs: E1, E2. And I have a single
              >WL Server
              >> hosting just servlets: S1. Now I give the -Djava.naming.provider.url=E1(using
              >> http or t3) (or I provide the same thing using my own jndi.properties).
              >>
              >> The problem with this setup is that while starting up, the Server will
              >try binding
              >> every object(including the System bindings like wl.transaction.TransactionManager,
              >> wl.common.T3Services) to the other NS (in this case E1's naming service)
              >which
              >> is bound to fail, as they're already bound in that Server.
              >>
              >> The solution has to be a way to specify the java.naming.provider.url
              >only for
              >> the servlets (or the web app).
              >>
              >> Any ideas on how to provide a Webapp specific lookup address?
              >>
              >> Marcelo, if you've found a way out to separate, pl. make a post.. Thanks!
              >>
              >> Harish
              >>
              >> "Cameron Purdy" <[email protected]> wrote:
              >> >Hi Marcelo,
              >> >
              >> >With Weblogic, your performance will typically decrease if you go
              >the
              >> >route
              >> >that you are describing.
              >> >
              >> >Yes, you can do jndi.properties, however I believe you will find it
              >inside
              >> >one of the WL jars.
              >> >
              >> >Note that you can use java -D instead to define some of the JNDI properties
              >> >to point to the other cluster, but I can't remember them off-hand.
              >> >
              >> >Peace,
              >> >
              >> >--
              >> >Cameron Purdy
              >> >Tangosol Inc.
              >> ><< Tangosol Server: How Weblogic applications are customized >>
              >> ><< Download now from http://www.tangosol.com/download.jsp >>
              >> >
              >> >
              >> >"Marcelo Caldas" <[email protected]> wrote in message
              >> >news:[email protected]...
              >> >> Ok,
              >> >> The scenario is: I'm using WLS6.1 (hopefully, version doesn't matter
              >> >here)
              >> >> with three instances clustered. Each instance provides all Services:
              >> >> Servlets / JSPs/ EJBs / Database communication... I'm using the
              >Basic
              >> >> configuration described on the BEA documentation....
              >> >>
              >> >> Now, I want to move forward to a Multi-tier configuration, where
              >the
              >> >first
              >> >> layer will serve Servlets and JSPs and the second layer will serve
              >> >EJBs.
              >> >>
              >> >> The problem: On the first scenario, I was looking EJBs with the
              >Default
              >> >> InitialContext() constructor without the environment, since everybody
              >> >was
              >> >on
              >> >> the same JVM...
              >> >> What do I have to do, so my Servlets start looking for EJBs on the
              >> >second
              >> >> cluster now? Do I have to re-write every single lookup? Can I use
              >a
              >> >> jndi.properties file on the first layer - on the presentation tier?
              >> >>
              >> >> Thanks in Advance,
              >> >> Marcelo.
              >> >>
              >> >>
              >> >
              >> >
              >
              

  • Single Sign on in a 3 tier architecture between SAP Netweaver CE and R/3

    Hi All,
    I am trying to implement SSO using SAP logon tickets in a 3 tier architecture between NW CE and R/3. But so far I have not been able to crack this.
    Let me describe the scenario in detail:
    We have two Java EE applications on Netweaver CE7.2 Application Server:
    1. UI: Just handles all the UI logic : js, jsp, css, html, extjs .It calls the Business Layer Java EE application to get data from back-end systems.
    2. Business Layer: Calls R/3 SOAP services does some processing on them and exposes the data back to the UI via a Restful JSON service (implemented using Java Spring framework)
    Both UI and Business Layer Java EE applications define login modules to be used for SAP logon tickets. So the architecture is like this:
    UI-RESTfull-->Business LayerSOAP->ABAP R/3
    So ideally when the UI link is clicked it prompts the user for authentication (uses CE UME) and then the UI applications calls the Business Layer which then calls R/3. This unfortunately doesn't work. The authentication between UI and Business Layer Application fails.
    However if you remove the Business Layer Java EE application and call the SOAP service directly from the UI. SAP logon tickets starts working.
    So I have been able to make SAP logon tickets work with the following 2 tier architecture:
    UI---SOAP--->R/3
    So my Question is:
    Is there a way to use SAP logon tickets in a 3 tier architecture between NW CE and R/3 (For the scenario described above)? Any help/pointers/documentation links would be great

    Hey Martin,
    To enable SSO I updated web.xml and engine-j2ee.xml for both UI and Business Layer application according to the login module stacks defined (the first one) in the following link:
    http://help.sap.com/saphelp_NW70EHP1/helpdata/en/04/120b40c6c01961e10000000a155106/content.htm
    Initially both UI and Business Layer had the same entries for web.xml and engine.xml. But since this was not working I did all kinds of testing. For UI i used FORM based authentication and for Business Layer I was using "BASIC" authentication.
    I tested the following Scenarios:
    1. Without any changes to the above XML files: The Business layer rejects any requests from the UI . I checked the Browser and "MYSAPSSO2" cookie was created. Somehow UI doesnt use this to call Business Layer. Or the Business Layer rejects the token itself
    2. I removed authentication from the Business Layer application (Web.xml) keeping the UI same: The call went to R3 but returned a "UnAuthorized" error back. In this case also at the browser level "MYSAPSSO2" token was created but was not used by the business layer to call R3.
    3. The did all sorts of permutation and combination with the sample login modules provided (See link above) on both UI and Business Layer application . Nothing worked. All combinations led to two results which were the same as 1 and 2
    It seems all this is happening because of another application in between UI and R3.
    Hope this Clarifies.
    Thanks,
    Dhannajay

  • Reports Multi-tier server from Dev 2000:v 1.6.1 don't start on solaris 8

    Reports Multi-tier server from Oracle Developer 2000:version 1.6.1 don't start on Sun Sparc Solaris 8, it writes:
    Segmentation Fault (core dumped). What i have to do?

    Reports Multi-tier server from Oracle Developer 2000:version 1.6.1 don't start on Sun Sparc Solaris 8, it writes:
    Segmentation Fault (core dumped). What i have to do?

  • SharePoint 2013 three-tier architecture

    Hi all, I am going to install SharePoint 2013 in a three-tier farm environment.
    I understand that the only difference between web server and app server is whether or not the "Microsoft SharePoint Foundation Web Application" service application is running or not. If yes = web server, if no = app server. App server is also where
    CA is installed. Both web server and app server will have connection to DB. When web server serves web page requests from users, it will go to DB directly to get the page content.
    However, the real three-tier architecture actually means that only app server should have access to DB. Web server will get the information it needs from the app server.
    Is my understanding correct so far? Why is there a difference between three-tier architecture when it is applied in SharePoint context?

    No, all SharePoint servers directly interface with databases for services that they host (with some exceptions). 3 tier just means you have a "WFE" which end users interact with, and it doesn't matter what services are on that "WFE",
    another SharePoint server which may do the same or other things, but users don't directly interact with, and of course the SQL Server.
    Trevor Seward
    Follow or contact me at...
    &nbsp&nbsp
    This post is my own opinion and does not necessarily reflect the opinion or view of Microsoft, its employees, or other MVPs.

  • Best practice to create multi tier (atleast 3 level) table

    What is the best practice to create multi tier (minimum 3 levels) of table?. Could any one provide a sample structure?.
    Thanks.

    Can u b more specific as to what you are trying to do. What u mean by 3 level table?

  • Multi tier debugging VS2008 - ODAC 1110620

    Hi,
    I'm trying to get the multi-tier debugging working in the above environment and am hitting the 'ORA-30683: failure establishing connection to debugger' exception.
    I can debug by right click on the server explorer and doing step-into.
    I have Tools - Oracle Application Debugging checked.
    In Tools -> Options ->Oracle Developer Tools i have the connection checked and the port range 49152 - 65535. No firewall is running.
    Any ideas what's causing this?

    Hi, a few questions:
    1. Does your debugger machine use IVP6 address? How about the database?
    2. Does the debugger machine have multiple IP addresses to use?

  • Multi-tier ssl

    Here is quick question for you weblogic Guru's :P
    I have a multi tier setup with 3 web servers and 3 app servers
    My web servers are apache running the weblogic proxy plugin.
    Now.. As far as i can tell my web servers (apache) are handling all the SSL information,
    and in my apache cluster configuration my 443 ports point to my 4701 (non SSL
    weblogic port). I currently have SSL turned on in WeblogicCommerceServer3.1 and
    i am wondering. Do i really need it turned on? as far as i can tell, Weblogic
    starts up a SSL ThreadPool at startup and i dont think it is being used..
    Please Give me whatever feedback you guys may have?
    i just want to understand what exaclty is going on and how it interferes with
    my servers/application..
    thanks everyone
    Quintin...

    Hey Quintin
    my two pennies:
    If you're totally sure that your Apache server is handling all SSL connection and WebLogic
    is just doing normal, cleartext HTTP on the backend, then you are right.
    There is no reason for you to have https enabled on WebLogic with your configuration. If
    you're concerned about the SSLThread pool, I recommend disabling https. It should not
    interfere with anything in your server or application, to my knowledge.
    Hit the admin console, click "servers->myserver" and then on the right look for the SSL tag
    and disable it. Restart your server. The SSL port (4701) should now be free (not used) and
    the SSLThreadPool should not exist within the VM, as far as I know.
    If you ever decide to make the traffic between Apache and WebLogic SSL, then just make sure
    you're using the plug-in from at least WLS 6.0sp2-- prior to that you can't do SSL between
    Apache and WebLogic.
    Then check out http://edocs.beasys.com/wls/docs61/adminguide/plugin_params.html#1143055 for
    the details.
    Hope this helps.
    Joe Jerry
    Quintin wrote:
    Here is quick question for you weblogic Guru's :P
    I have a multi tier setup with 3 web servers and 3 app servers
    My web servers are apache running the weblogic proxy plugin.
    Now.. As far as i can tell my web servers (apache) are handling all the SSL information,
    and in my apache cluster configuration my 443 ports point to my 4701 (non SSL
    weblogic port). I currently have SSL turned on in WeblogicCommerceServer3.1 and
    i am wondering. Do i really need it turned on? as far as i can tell, Weblogic
    starts up a SSL ThreadPool at startup and i dont think it is being used..
    Please Give me whatever feedback you guys may have?
    i just want to understand what exaclty is going on and how it interferes with
    my servers/application..
    thanks everyone
    Quintin...

  • Single-Tier in Dev / Multi-Tier in Prod - BPC5.1 - are there any issues?

    Background: We are a new install of SAP BPC 5.1 and initially planned to have both Dev and Prod as a single tier install.  In the Blueprint design review, the recommendation was made and accepted to have production as a Multi-Tier landscape.  Due to tight timelines, the customer will go-live on the Production Multi-tier landscape and Dev in a Single Tier configuration. As soon as possible, we will move Dev to a Multi-Tier install as well to synchronise Dev to Prod.
    Question: Other than being uncommon, is there any know issues with having this current dissimilar landscape?
    Edited by: Penelope Thomson on Dec 17, 2007 12:15 PM

    There's nothing uncommon about having a development environment that isn't an exact macth to production.  Many clients that have large mutli-server configurations don't invest that much money and resources in thier development environment.  The downside is that when you do things such as stress testing, user acceptance testing and other configurations in development, you really have to do them again in production if you want a fully tested environement.
    Also, if you have different software components (e.g. 64bit OS in production and 32bit in development) you are dealing with different service packs and other components that can have different issues.  I've also run into differences in authentication issues between a simple and more complex environment depending on how the components are arranged.
    These should all be issues the technical consultant that is doing the server configurations can discuss with you.  The bottom line is you'll want to make sure you have the production environment setup with enough time to do a through testing before go-live.  As far as moving the application from development to production, going from a single server to mutli-server shouldn't be an issues as long as you're using server mananger to do the backup and restore.

  • Three(two)-tier architecture - need help

    Hello,
    very need your advice about implementing 3-tier architecture with .NET.
    My intention was to organize the following architecture: server contains data access layer and business layer, and ODP.NET is installed on the server, client requests business layer on the server through .NET Remoting. Business layer on the server returns typed data sets;objects on the server implement interfaces, which return data sets. So, client dlls need to reference only this data sets declaration (which are vendor independent) and interfaces, and no ODP.NET is needed on the client. The problem is that when I generate data source in Visual Studio 2008, it generates also references on ODP.NET, so I cannot reference this project in client application! While I need "pure" data sets, without ODP.NET references, but, at the same time, I want to use auto-generated adapters and not write code manually!
    How can I do it?
    Thanks in advance.. and need your reply!

    For me, I will use Web Services to achieve this. Somehow, you can use other remoting method to do that as well.
    Ming Man

  • Pessimistic locking in a three-tier architecture

    Hello,
    we use a three-tier architecture to edit data in a database (Oracle 10g) with a rich-client application and we want to use pessimistic locking.
    The client is communicating with a stateless bean on the application server (Jboss 4.2.3).
    This bean-facade has methods for reading, writing and locking records that are transferred to the client encapsulated in entity beans.
    The client controls the transactions as JPA-User-Transactions.
    The methods in the container managed bean have the transaction attribute REQUIRED.
    Before doing any modification on the client a method setLock() is called in the bean to lock the records in the database.
    The lock is implemented with query hints:
    Query query = em.createQuery("select e from Person e WHERE e.id = 252");
    query.setHint(QueryHints.PESSIMISTIC_LOCK, PessimisticLock.LockNoWait);
    So much for this theroy...
    Practically we can set a lock on a record in the database.
    But removing the lock is working when changing and committing the record only.
    The record remains locked if performing a rollback or a commit without any changes.
    Any idea what's missing in our implementation?
    Our approach should work - theoretically...
    Thanks in advance for any hint
    Best regards,
    Martin Kubitza
    T&P, Bochum/Germany

    Thank you for the hint on JPA - we are analyzing this now.
    Meanwhile we tried something "easier": Optimistic locking
    Optimistic locking works well with a version-column and the @VERSION annotation. But we get a problem with the @OptimisticLocking(type = OptimisticLockingType.ALL_COLUMNS annotation (see Optimistic Locking with OptimisticLockingType.ALL_COLUMNS
    We are using Eclipselink V1.1 and (now) a bean managed transaction type)
    Martin Kubitza
    T&P, Bochum/Germany

Maybe you are looking for

  • Problem with GUI in applet

    Hai to all, I am having a problem with GUI in applets My first class extends a JPanel named A_a import javax.swing .*; import java.awt.*; import java.awt.event.*; public class A_a extends JPanel JButton jb; JTextArea text; public A_a() setLayout(new

  • HDMI to DVI

    Hi, I just ordered a recent MacMini with HDMI and Thunderbolt. I already own an older Apple Cinema Display (2005, I think 20'') with a DVI port. Will I be able to connect this display to the new mini via the HDMI to DVI adapter, or do I need to buy a

  • Problem related to HU

    Hello, While creating outbound delivery, weight is copied from handling unit into outbound delivery but volume is not getting copied. Kindly guide. Nikhil

  • HT5313 OS x 10.7.5

    I have OS x 10.6.8 but I apparently need OS x 10.7.5 to run airport utility software for a new airport extreme. Can I just download the OS X 10.7.5 update or do I need to install OS X lion first and then the 10.7.5 update?

  • Camera Raw Universal update not working

    Hey there .... heeeeelp .... I've just upgraded to a Mac Book Pro Core 2 Duo system, and it seems like the Camera Raw updater is not functioning on this system. I get no previews with my Canon 400D/XTi on import, which is what this update was suposse