A coherent db application

Hello,
The examples I obtained so far only "read" the database once thru main.
Are there any examples (transactional) that continuously add/update and delete records thru listeners? I want to interact with the database coherently.
Thanks
Jack
Edited by: luckiejacky on Jan 29, 2008 11:07 PM
Edited by: luckiejacky on Jan 29, 2008 11:08 PM

import java.awt.Button;
import java.awt.Color;
import java.awt.BorderLayout;
import java.awt.TextField;
import java.awt.Frame;
import java.awt.Font;
import java.awt.Label;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.event.WindowListener;
import java.awt.event.WindowEvent;
import java.awt.event.WindowAdapter;
import java.awt.event.FocusEvent;
import java.awt.event.FocusAdapter;
import java.awt.event.KeyAdapter;
import java.awt.event.KeyEvent;
import java.awt.event.MouseAdapter;
import java.awt.event.MouseEvent;
import org.apache.commons.dbutils.DbUtils;
import org.apache.commons.dbutils.QueryRunner;
import org.apache.commons.dbutils.handlers.MapListHandler;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;
import java.util.Map;
import java.util.List;
class Quotation
   // please dynamically maintain an array for database use
   // By putting this onto the heap
   String QuotationID;
   String QuotationType;
   Quotation()
     QuotationID = null;
     QuotationType = null;
   String FindByQuotationNo(String Type)
     if (Type == "Test") {
      return "Q08011132";
     return "Error";
public class TestSwing extends Frame implements ActionListener
    Button post = new Button("Find");
    Label mouseLabel = new Label("");
    static Label QIDLabel = new Label("");
    static Label QTypeLabel = new Label("");
    private Label label = null;
    static Quotation quo = new Quotation();
    TestSwing(String title)
       super(title);
       super.setSize(500,400);
       mouseLabel.setFont(new Font("Arial", Font.BOLD, 20));
       mouseLabel.setBackground(Color.PINK);
       QIDLabel.setFont (new Font("Arial", Font.BOLD, 20));
       QIDLabel.setBackground(Color.PINK);
       QTypeLabel.setFont (new Font("Arial", Font.BOLD, 20));
       QTypeLabel.setBackground(Color.PINK);
       super.add(post, BorderLayout.NORTH);
     //  super.addWindowListener(new MyWindowListener());
       super.add(mouseLabel, BorderLayout.CENTER);
       super.add(QIDLabel, BorderLayout.CENTER);
       super.add(QTypeLabel, BorderLayout.CENTER);
  //     mouseLabel.addMouseListener(this);      // here //mouseLabel.addMouseListener(new MyMouseAdapter(mouseLabel));
//       QIDLabel.addMouseListener (new MyMouseAdapter(QIDLabel));
//     QTypeLabel.addMouseListener (new MyMouseAdapter(QTypeLabel));
    public void actionPerformed(ActionEvent e) {
      //  if (e.getSource() == exitButton) {
      //    dispose();
      //    System.exit(0);
         System.out.println("Hello");
    public void mouseClicked(MouseEvent e)
        int x = e.getX();
        int y = e.getY();
        String key = null;
        if (e.getButton() == e.BUTTON1)
           key = "left key";
        else if (e.getButton() == e.BUTTON3)
           key = "right key";
        label.setText ("X-" + x + "Y-" + y + "," +key);
    public static void main(String[] args)
      Connection conn = null;
      String jdbcURL = "jdbc:mysql://localhost/test";
      String jdbcDriver = "com.mysql.jdbc.Driver";
      String user = "root";
      String password = "football";
      TestSwing demo = new TestSwing("Hello World");
      demo.setVisible(true);
      String QuoType = quo.FindByQuotationNo ("Test");
      System.out.println(QuoType);
      try {
         DbUtils.loadDriver(jdbcDriver);
         conn = DriverManager.getConnection(jdbcURL, user, password);
         QueryRunner qRunner = new QueryRunner();
         List mapList = (List) qRunner.query (conn, "select * from testtable",
                  new MapListHandler());
         for (int i = 0; i < mapList.size(); i++) {
             Map map = (Map) mapList.get(i);
             System.out.println ("Quotation_ID          Type");
             System.out.println ("==========================");
//             System.out.println (map.get("QID").toString()+ map.get("QTYPE").toString());
             QIDLabel.setText(map.get("QID").toString());
             QTypeLabel.setText(map.get("QTYPE").toString()); 
      } catch (SQLException e) {
        e.printStackTrace();
      } finally {
        DbUtils.closeQuietly(conn);
}Changed something
Thanks
Jack
Edited by: luckiejacky on Jan 31, 2008 10:12 PM

Similar Messages

  • Problem with application item and session state

    Okay, let's see if I can explain this problem coherently.
    I have a small app (one page), with an application item, F_WHERE_CLAUSE.
    This page has three regions in which there are items that the users can populate for search conditions. A couple of these items are "select list with submit" (I still need to upgrade to the AJAX method, I know). There is another region which has one hidden field, called P1_WHERE_CLAUSE. This field is defined to "Always, replacing any value in session state..." with source type of "Item (application or page.....", and a source value of F_WHERE_CLAUSE with no default value.
    I have a button called "Search" which submits the page and fires a PL/SQL process which builds a where condition based upon the other page items and stores the value to the application item F_WHERE_CLAUSE (correctly).
    For testing, I've made the P1_WHERE_CLAUSE field visible so that I can see what's going on. I've also clicked the debug and session buttons to help trace this. After I click the "Search" button and the page submits, debug shows:
    0.02: ...Session State: Save "P1_WHERE_CLAUSE" - saving same value: "1=1"
    followed later by:
    0.05: ...Session State: Saved Item "F_WHERE_CLAUSE" New Value="lower(primary_class) = 'rock' and country = 'Spain'"
    The field P1_WHERE_CLAUSE displays with the correct search criteria as signified by F_WHERE_CLAUSE above. However, If I click the "session" button to view the session state values, P1_WHERE_CLAUSE shows up as:
    P1_WHERE_CLAUSE Textarea    1=1    U while F_WHERE_CLAUSE displays the correct value still.
    The reason this "problem" came up, is that this page also has three SQL report regions which use &P1_WHERE_CLAUSE. for the where condition. While they display the correct results on-screen, each report region also has the "Export to csv" enabled, and the export seems to be using the "1=1" condition (from the "session" window) instead of the search criteria that the on-screen region is using (F_WHERE_CLAUSE and the displayed P1_WHERE_CLAUSE), resulting in a retreival of all records.
    Anybody have any idea what's going on and why, and how to get the csv export to use the correct value for the where condition?
    Thanks,
    Bill Ferguson

    It appears the "Export to CSV" functionality requires the item value to be set in session state. The P1_WHERE_CLAUSE item value never gets saved to session state. The page is rendered and the value is put in the item on the page but until you submit the page session state doesn't know what P1_WHERE_CLAUSE is.
    Create a before header computation or process to set the value of P1_WHERE_CLAUSE (which will save it to session state). It is interesting that the report regions didn't need to look at the value in session state but the "export to csv" does.
    --Jeff                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Deploying adf application to WebLogic Server Version: 10.3.6.0

    hi i have develope application in adf using jdeveloper 11.1.1.6.0 i have deploy the application to weblogic 10.3.6.0
    this is what i have done
    1. i have created a new Managed server in my weblogic=under Environment->Servers
    2.the state of my new server is shutdown
    3.deployment method
    -in my jdeveloper i click application->Application properties->Deployment->new->Archive Type->EAR FILE->applicationName->OK
    TO deploy from jdeveloper to weblogic server
    in my jdeveloper i click application APPLICATION->Deploy->applicationName->Deploy to Application Server-applicationserver i choose the new server i created in my weblogic->weblogic Option->deploy to selected instance->i select the name of the server i created in my weblogic->next->finish
    after that the deployment configuration screen pop up than i click deploy then screen MDS CONFIGURATION invalid pop up with message MDS CONFIGURATION information appear invalid metadata Repository not found in target server.deploy anyway then i click yes
    i got this meaasge in my deployment log
    [08:33:46 AM] Entering Oracle Deployment Plan Editor
    [08:38:56 AM] Deploying Application...
    [08:38:57 AM] [Deployer:149195]Operation 'deploy' on application 'UAMOrganisation' has been deferred since 'UamOrganisation' is unavailable
    [08:38:57 AM] [Deployer:149034]An exception occurred for task [Deployer:149026]deploy application UAMOrganisation on UamOrganisation.: .
    [08:38:57 AM] Application Deployed Successfully.
    [08:38:57 AM] Elapsed time for deployment:  5 minutes, 21 seconds
    [08:38:57 AM] ----  Deployment finished.  ----than i go to my weblogic under deployment there i found my deploy application with a state=new and type=Enterprise application
    than i click start->Servircing all request->start application assistance->yes->Start requests have been sent to the selected Deployments.
    but now i what to test my application am geting this Internet Explorer cannot display the webpage,do i need to start my Managed server how do i do that,i try to click server start but it does not start how can i start my new created Managed server
    the listern port of my new created server is 8003
    my problem is am not able to test the application i have deploy
    Edited by: adf009 on 2013/01/30 11:26 AM
    Edited by: adf009 on 2013/01/30 11:39 AM
    Edited by: adf009 on 2013/01/30 11:41 AM
    Edited by: adf009 on 2013/01/30 12:33 PM

    i did this,am in window 7 64 bit
    start startNodeManager.cmd
    C:\Oracle\weblogic\wlserver_10.3\server\bin>set CLASSPATH=.;C:\Oracle\weblogic\p
    atch_wls1036\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\Oracl
    e\weblogic\patch_ocp371\profiles\default\sys_manifest_classpath\weblogic_patch.j
    ar;C:\Oracle\MIDDLE~1\JDK160~1\lib\tools.jar;C:\Oracle\weblogic\WLSERV~1.3\serve
    r\lib\weblogic_sp.jar;C:\Oracle\weblogic\WLSERV~1.3\server\lib\weblogic.jar;C:\O
    racle\weblogic\modules\features\weblogic.server.modules_10.3.6.0.jar;C:\Oracle\w
    eblogic\WLSERV~1.3\server\lib\webservices.jar;C:\Oracle\weblogic\modules\ORGAPA~
    1.1/lib/ant-all.jar;C:\Oracle\weblogic\modules\NETSFA~1.0_1/lib/ant-contrib.jar;
    C:\Oracle\MIDDLE~1\WLSERV~1.1\server\lib\xqrl.jar
    C:\Oracle\weblogic\wlserver_10.3\server\bin>if not "" == "" set CLASSPATH=;.;C:\
    Oracle\weblogic\patch_wls1036\profiles\default\sys_manifest_classpath\weblogic_p
    atch.jar;C:\Oracle\weblogic\patch_ocp371\profiles\default\sys_manifest_classpath
    \weblogic_patch.jar;C:\Oracle\MIDDLE~1\JDK160~1\lib\tools.jar;C:\Oracle\weblogic
    \WLSERV~1.3\server\lib\weblogic_sp.jar;C:\Oracle\weblogic\WLSERV~1.3\server\lib\
    weblogic.jar;C:\Oracle\weblogic\modules\features\weblogic.server.modules_10.3.6.
    0.jar;C:\Oracle\weblogic\WLSERV~1.3\server\lib\webservices.jar;C:\Oracle\weblogi
    c\modules\ORGAPA~1.1/lib/ant-all.jar;C:\Oracle\weblogic\modules\NETSFA~1.0_1/lib
    /ant-contrib.jar;C:\Oracle\MIDDLE~1\WLSERV~1.1\server\lib\xqrl.jar
    C:\Oracle\weblogic\wlserver_10.3\server\bin>if not "C:\Oracle\MIDDLE~1\WLSERV~1.
    1\server\lib\xqrl.jar" == "" set CLASSPATH=.;C:\Oracle\weblogic\patch_wls1036\pr
    ofiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\Oracle\weblogic\patc
    h_ocp371\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\Oracle\MI
    DDLE~1\JDK160~1\lib\tools.jar;C:\Oracle\weblogic\WLSERV~1.3\server\lib\weblogic_
    sp.jar;C:\Oracle\weblogic\WLSERV~1.3\server\lib\weblogic.jar;C:\Oracle\weblogic\
    modules\features\weblogic.server.modules_10.3.6.0.jar;C:\Oracle\weblogic\WLSERV~
    1.3\server\lib\webservices.jar;C:\Oracle\weblogic\modules\ORGAPA~1.1/lib/ant-all
    .jar;C:\Oracle\weblogic\modules\NETSFA~1.0_1/lib/ant-contrib.jar;C:\Oracle\MIDDL
    E~1\WLSERV~1.1\server\lib\xqrl.jar;C:\Oracle\MIDDLE~1\WLSERV~1.1\server\lib\xqrl
    .jar
    C:\Oracle\weblogic\wlserver_10.3\server\bin>cd C:\Oracle\weblogic\WLSERV~1.3\com
    mon\NODEMA~1
    C:\Oracle\weblogic\WLSERV~1.3\common\NODEMA~1>if not "" == "" if not "" == "" go
    to runNMWithListenAddressAndPort
    C:\Oracle\weblogic\WLSERV~1.3\common\NODEMA~1>if not "" == "" goto runNMWithList
    enAddress
    C:\Oracle\weblogic\WLSERV~1.3\common\NODEMA~1>if not "" == "" goto runNMWithList
    enPort
    C:\Oracle\weblogic\WLSERV~1.3\common\NODEMA~1>"C:\Oracle\MIDDLE~1\JDK160~1\bin\j
    ava.exe" -server -Xms32m -Xmx200m -XX:MaxPermSize=128m -XX:+UseSpinning -Dcohere
    nce.home=C:\Oracle\weblogic\COHERE~1.7 -Dbea.home=C:\Oracle\weblogic  -Dweblogic
    .ProductionModeEnabled=true   -da -Dplatform.home=C:\Oracle\MIDDLE~1\WLSERV~1.1
    -Dwls.home=C:\Oracle\MIDDLE~1\WLSERV~1.1\server -Dweblogic.home=C:\Oracle\MIDDLE
    ~1\WLSERV~1.1\server   -Dweblogic.management.discover=true  -Dwlw.iterativeDev=f
    alse -Dwlw.testConsole=false -Dwlw.logErrorsToConsole=false "-Djava.security.pol
    icy=C:\Oracle\weblogic\WLSERV~1.3\server\lib\weblogic.policy" "-Dweblogic.nodema
    nager.javaHome=C:\Oracle\MIDDLE~1\JDK160~1" weblogic.NodeManager -v
    <30 Jan 2013 1:14:37 PM> <INFO> <Loading domains file: C:\Oracle\weblogic\WLSERV
    ~1.3\common\NODEMA~1\nodemanager.domains>
    30 Jan 2013 1:14:37 PM weblogic.nodemanager.server.NMServerConfig initDomainsMap
    INFO: Loading domains file: C:\Oracle\weblogic\WLSERV~1.3\common\NODEMA~1\nodema
    nager.domains
    <30 Jan 2013 1:14:38 PM> <INFO> <Loading identity key store: FileName=C:\Oracle\
    MIDDLE~1\WLSERV~1.1\server\lib\DemoIdentity.jks, Type=jks, PassPhraseUsed=true>
    30 Jan 2013 1:14:38 PM weblogic.nodemanager.server.SSLConfig loadKeyStoreConfig
    INFO: Loading identity key store: FileName=C:\Oracle\MIDDLE~1\WLSERV~1.1\server\
    lib\DemoIdentity.jks, Type=jks, PassPhraseUsed=true
    <30 Jan 2013 1:14:38 PM> <SEVERE> <Fatal error in node manager server>
    weblogic.nodemanager.common.ConfigException: Identity key store file not found:
    C:\Oracle\MIDDLE~1\WLSERV~1.1\server\lib\DemoIdentity.jks
            at weblogic.nodemanager.server.SSLConfig.loadKeyStoreConfig(SSLConfig.ja
    va:153)
            at weblogic.nodemanager.server.SSLConfig.<init>(SSLConfig.java:102)
            at weblogic.nodemanager.server.NMServer.init(NMServer.java:186)
            at weblogic.nodemanager.server.NMServer.<init>(NMServer.java:148)
            at weblogic.nodemanager.server.NMServer.main(NMServer.java:380)
            at weblogic.NodeManager.main(NodeManager.java:31)
    30 Jan 2013 1:14:38 PM weblogic.nodemanager.server.NMServer main
    SEVERE: Fatal error in node manager server
    weblogic.nodemanager.common.ConfigException: Identity key store file not found:
    C:\Oracle\MIDDLE~1\WLSERV~1.1\server\lib\DemoIdentity.jks
            at weblogic.nodemanager.server.SSLConfig.loadKeyStoreConfig(SSLConfig.ja
    va:153)
            at weblogic.nodemanager.server.SSLConfig.<init>(SSLConfig.java:102)
            at weblogic.nodemanager.server.NMServer.init(NMServer.java:186)
            at weblogic.nodemanager.server.NMServer.<init>(NMServer.java:148)
            at weblogic.nodemanager.server.NMServer.main(NMServer.java:380)
            at weblogic.NodeManager.main(NodeManager.java:31)
    C:\Oracle\weblogic\WLSERV~1.3\common\NODEMA~1>goto finish
    C:\Oracle\weblogic\WLSERV~1.3\common\NODEMA~1>ENDLOCAL
    C:\Oracle\weblogic\wlserver_10.3\server\bin>can i test my application without manged server started
    link is http://italianknows.blogspot.com/2011/02/weblogic-1034-ps3-nodemanager-wont.html
    Edited by: adf009 on 2013/01/30 1:43 PM
    Edited by: adf009 on 2013/01/30 1:56 PM
    Edited by: adf009 on 2013/01/30 1:57 PM
    Edited by: adf009 on 2013/01/30 2:14 PM
    Edited by: adf009 on 2013/01/30 2:15 PM
    Edited by: adf009 on 2013/01/30 2:16 PM

  • Application scoped objects in a cluster

    Hi -
              Will weblogic clustering provide failover for Application scoped
              objects (in the ServletContext)? I've read through most of the
              documentation, and it doesn't mention anything. Also, the servlet 2.3
              spec says
              "Context attributes are local to the VM in which they were created.
              This prevents
              ServletContext attributes from being a shared memory store in a
              distributed
              container. When information needs to be shared between servlets
              running in a
              distributed environment, the information should be placed into a
              session (See
              Chapter SRV.7, &#8220;Sessions&#8221;), stored in a database, or set
              in an Enterprise
              JavaBeans TM component." (Section 3.4)
              However, it doesn't mention anything about failover.
              We have lots of application scoped objects that will need to failover
              somehow - anyone have experience with this?
              Thanks,
              Scott
              

    Hi Scott,
              The application scoped objects (ServletContext) are per Web Container as
              explained in the spec. When the server hosting that Web Container dies, so
              too do the objects in the ServletContext.
              If you are looking something like ServletContext that is replicated across
              the cluster and supports failover, you should check out our Coherence
              product at http://www.tangosol.com/ -- that is exactly what it does.
              Peace,
              Cameron Purdy
              Tangosol Inc.
              Tangosol Coherence: Clustered Coherent Cache for J2EE
              Information at http://www.tangosol.com/
              "Scott Gilpin" <[email protected]> wrote in message
              news:[email protected]...
              > Hi -
              >
              > Will weblogic clustering provide failover for Application scoped
              > objects (in the ServletContext)? I've read through most of the
              > documentation, and it doesn't mention anything. Also, the servlet 2.3
              > spec says
              >
              > "Context attributes are local to the VM in which they were created.
              > This prevents
              > ServletContext attributes from being a shared memory store in a
              > distributed
              > container. When information needs to be shared between servlets
              > running in a
              > distributed environment, the information should be placed into a
              > session (See
              > Chapter SRV.7, &#8220;Sessions&#8221;), stored in a database, or set
              > in an Enterprise
              > JavaBeans TM component." (Section 3.4)
              >
              > However, it doesn't mention anything about failover.
              >
              > We have lots of application scoped objects that will need to failover
              > somehow - anyone have experience with this?
              >
              > Thanks,
              > Scott
              

  • CAF (Composite Application Framework) and ESA

    Hi,
    As far as I understand, XApps is presented as a piece of Netweaver (the column on the left side of the NetWeaver stack), an XApps is also a kind of business process based on several applications (or services ?).
    XApps runtime and composition platform is the CAF and not NetWeaver ?
    So I am confused and I do not understand if
    - ESA and XApps is the same concept
    - ESA and XApps are not based on the same technology
    - XApps will be part of the Enterprise Services Repository and CAF will be rewrtitten to be based on XI so that the vision and the strategy is coherent
    If someone ca nclarify, I will greatly appreciate.
    Cheers.Christophe

    XApps is a concept. There is no general implementation of it. You can write Xapps in Java, In ABAP, or whatever. However, there are nice tools in development to do XApps, which are completely Java based.
    > XApps runtime and composition platform is the CAF and
    > not NetWeaver ?
    CAF does run on NetWeaver. As it has a "Framework" in it's name it naturally should not contain a server environment, should it?
    >
    > So I am confused and I do not understand if
    > - ESA and XApps is the same concept
    No.
    > - ESA and XApps are not based on the same technology
    Yes.
    > - XApps will be part of the Enterprise Services
    > Repository and CAF will be rewrtitten to be based on
    > XI so that the vision and the strategy is coherent
    where did you hear this?
    Regards,
    Benny

  • Oracle coherance

    I am struggling to understand basis of Oracle coherance .... please it is possible to update on following points,
    1) Where actually Oracle coherance is created.
    2) How data is populated first time in cache.
    3) What happens if we updated / Insert / delete data from oracle coherance how it is updated in database.
    4) Hw data is synchronized between different application server if I have more than 2 apps server

    Not that I want to chase you away, but Coherence is a middleware product, not a database product.
    It has a fairly active forum at Forum Home » Application Server » Coherence Support (Coherence Support The people there are knowledgeable on the topic and are helpful.
    In addition, http://download.oracle.com/docs/cd/E14526_01/index.htm is the doc site.
    Also find white papers and general info at http://www.oracle.com/technology/products/coherence/index.html and http://www.oracle.com/technology/products/coherence/coherence_suite.html

  • Multithread applications in SAP environment

    Hello folks ,
    I just got a huge task which require a lot of processing power.
    i wonder if there's any way to build ABAP applications in way that multithreading or somthing similar could implemented
    even with some patterns or any other technology .
    Thanks for any ideas .

    Hello Jerry
    thank for your information but it's not was very clear from my side .
    there's an difference between process and Thread .
    A single process can have multiple threads that share global data and address space with other threads running in the same process, and therefore can operate on the same data set easily. Processes do not share address space and a different mechanism must be used if they are to share data.
    If we consider running a word processing program to be a process, then the auto-save and spell check features that occur in the background are different threads of that process which are all operating on the same data set (your document in this case ).
    process
    In SAP computing env. , a process is an instance of a program that is being sequentially executed by a computer system that has the ability to run several computer programs concurrently.
    for a Thread
    A single process may contain several executable programs (threads) that work together as a coherent whole. One thread might, for example, handle error signals, another might send a message about the error to the user, while a third thread is executing the actual task of the...
    i wonder if there's a way to implement the multitherading like in c++ for instance .

  • Application server sizing

    Can some one help in sizing the Sun application server for 1000 Users (For BEA application server). There will be 400 concurrent users in terms of hard disk space, memory and speed etc.
    Thanks
    Afsar

    There is no way to tell from the information that you provided. You will
    need to load test and see how the application responds to a growing number
    of simulated users on some particular amount of hardware. Usually CPU and to
    a lesser extent memory are the resources that your app server runs out of
    first.
    Peace,
    Cameron Purdy
    Tangosol Inc.
    Tangosol Coherence: Clustered Coherent Cache for J2EE
    Information at http://www.tangosol.com/
    "M Afsar Alam" <[email protected]> wrote in message
    news:3c2dccda$[email protected]..
    Can some one help in sizing the Sun application server for 1000 Users (ForBEA application server). There will be 400 concurrent users in terms of hard
    disk space, memory and speed etc.
    Thanks
    Afsar

  • Cache / application node configuration

    Hi!
    I am doing a Coherense evaluation and yesterday I talked to the UK Tangosol office that suggested I post these questions here to more quickly get answers. I hope you can help.
    I would like to configure a number of nodes to ONLY hold data for a distributed cache. Let us call them cache nodes.
    A number of other nodes should be configured to participate in the same distributed cache but not hold any data. They will use a "near" cache with the distributed cache as "back cache". This is the nodes were my application logic will go. Let us call them application nodes.
    My first question is if I must have the same configuration on the cache nodes as I have on the application nodes (i.e. must I use a "near cache" even though I do not need or want a "front cache" here since nobody will access the data locally? I assume that the invalidation of even an empty front cache has some associated cost and this is another reason to not have one when not needed.
    My second question is if I must make som special provisions in my CacheStore (that will use JDBC to sync with a database) to ensure that modified data will either not be written to either the cache or the database or both (for instance in the event of a critical hardware failure of the cache node calling the CacheStore during a call to one of the "store" or "erase" methods) - or is this "automagically" taken care of some how by the layer above the CacheStore? Is the answer the same or different if I use replication of the data in the replicated cache or not? My plan is to NOT use replication and instead take the hit that some cache data is lost (will be reloaded if needed later) in the event of a critical error killing one of the cache nodes. If I must do something special in the CacheStore to ensure that the database and cache is always coherent I would like some example code that i can start from...
    My third question is if my proposed configuration is fully coherent or is it theoretically possible that a client can send a request that modify an object to one of the application node and then (assuming my load balancer is NOT sticky) immediately requests the same data from another application node and get the OLD object value back? I.e. is the update/invalidation from/to the near caches synchronous or asynchronous? If this is a "possible" scenario is there anything that can be done to avoid it with this setup (except getting a sticky load balancer)?
    Lastly if you happen to sit on some configuration examples that set up exactly this kind of scenario (or something very close to it) I would appreciate having a look at them. I have found some examples on the forum but none that do the same thing...
    Best Regards
    MagnusE

    Thanks for your quick and informative answer Jon! I need to think more about some of your points to make sure i understand the implications. A few quick follow-up questions though:
    With a write-through cache, Coherence will call your
    CacheStore implementation before updating the cache,
    and so the database will always have the most current
    version of the data, even in the event of a cache
    server failure.But will the cache also get the new verssion of thew data somehow in the event of a failure (that oocur just after the data has been stored in the database but before the storage node managed to put it in the cache) or will this cause non-coherence between database and cache? Will the application node get an exception back from its put operation in this case (so it at least is aware that the data may not have gone into both the cache and the database)?
    What happens if the data store fail to put the data in the database (due to a database constraint or a database failure etc) and the store method in the datastore class throws an exception? Will the storage node still put the new (or changed) object in the cache (causing a non-coherence between databse and cache) or not?
    Do you have some documentation that explains how the product handles all the known "corner cases" (like failures during or just after the datastore methods are called etc - it would be valuable since they are often the cause of the rare but really nasty problems...
    Best Regards
    Magnus
    Message was edited by: Magnus
    Message was edited by: Magnus

  • Error when content coherance cache is cofigured.

    HI All, 
    we have build a portal application and followed this blog to configure content coherance cache for content presneter:
    http://www.ateam-oracle.com/configure-coherence-for-oracle-webcenter-portal-framework-content-presenter-task-flow/
    environment is cluster, after this configuration we are facing intermittent error and content wont come once the exception occur.
    we check the coherance config xml is picked and is correctly added to app class path.
    <Sep 24, 2013 4:24:12 PM EDT> <Error> <oracle.webcenter.doclib.internal.model.presenter.PresenterRetrievalException> <WCS-07897> <Error retrieving node(s).
    oracle.webcenter.doclib.internal.model.presenter.PresenterRetrievalException: Sep 24, 2013 4:24:12 PM oracle.webcenter.doclib.internal.model.presenter.PresenterRetrievalException asError
    ALL: Error retrieving node(s).
            at oracle.webcenter.doclib.internal.model.presenter.PresenterRetrievalException.asError(PresenterRetrievalException.java:55)
            at oracle.webcenter.doclib.internal.model.presenter.vcr.MultiNodeRetrieverImpl.getNodes(MultiNodeRetrieverImpl.java:72)
            at oracle.webcenter.doclib.internal.view.presenter.PresenterRetrievalService.getNodes(PresenterRetrievalService.java:78)
            at oracle.webcenter.doclib.internal.view.presenter.ContentPresenterBackingBean.getDatasourceResults(ContentPresenterBackingBean.java:252)
            at oracle.webcenter.doclib.internal.view.presenter.ContentPresenterBackingBean.getNodes(ContentPresenterBackingBean.java:167)
            at oracle.webcenter.doclib.internal.view.presenter.ContentPresenterBackingBean.getResults(ContentPresenterBackingBean.java:137)
    Caused By: oracle.webcenter.content.integration.AuthenticationException: Sep 24, 2013 4:24:12 PM oracle.webcenter.content.integration.federated.internal.delegate.RepositoryHelper validateSessionAuthenticated
    SEVERE: Error authenticating to repository: UCM. Possible cause could include, but is not limited to a bad repository configuration or the repository is unknown.  Error message: java.lang.IllegalStateException: Service "LocalCache" has been started by the factory with a different configuration descriptor
    Caused By: oracle.webcenter.content.integration.RepositoryRuntimeException: java.lang.IllegalStateException: Service "LocalCache" has been started by the factory with a different configuration descriptor
            at oracle.webcenter.content.integration.spi.ucm.UCMBridge.getBridge(UCMBridge.java:355)
            at oracle.webcenter.content.integration.spi.ucm.RepositoryImpl.getCapabilitySupport(RepositoryImpl.java:166)
            at oracle.webcenter.content.integration.federated.internal.delegate.RepositoryManagerDelegate.readExtensibleCapabilitySupport(RepositoryManagerDelegate.java:353)
            at oracle.webcenter.content.integration.federated.internal.delegate.RepositoryManagerDelegate.findRepositoryCapabilities(RepositoryManagerDelegate.java:408)
            at oracle.webcenter.content.integration.federated.internal.delegate.RepositoryManagerDelegate.createRepoMetaForRepositoryInterfaces(RepositoryManagerDelegate.java:719)
            at oracle.webcenter.content.integration.federated.internal.delegate.RepositoryManagerDelegate.connectToRepository(RepositoryManagerDelegate.java:894)
            at oracle.webcenter.content.integration.federated.internal.delegate.RepositoryManagerDelegate.ensureConnectedToRepository(RepositoryManagerDelegate.java:798)
            at oracle.webcenter.content.integration.federated.internal.delegate.RepositoryManagerDelegate.connect(RepositoryManagerDelegate.java:1098)
    Caused By: oracle.webcenter.content.integration.RepositoryException: java.lang.IllegalStateException: Service "LocalCache" has been started by the factory with a different configuration descriptor
            at oracle.webcenter.content.internal.stellent.VCRConfigProvider.executeTask(VCRConfigProvider.java:70)
            at oracle.webcenter.content.integration.spi.ucm.UCMBridge.connectToServer(UCMBridge.java:1873)
            at oracle.webcenter.content.integration.spi.ucm.UCMBridge.getBridge(UCMBridge.java:338)
            at oracle.webcenter.content.integration.spi.ucm.RepositoryImpl.getCapabilitySupport(RepositoryImpl.java:166)
            at oracle.webcenter.content.integration.federated.internal.delegate.RepositoryManagerDelegate.readExtensibleCapabilitySupport(RepositoryManagerDelegate.java:353)
    Caused By: java.lang.IllegalStateException: Service "LocalCache" has been started by the factory with a different configuration descriptor
            at com.tangosol.net.DefaultConfigurableCacheFactory.validateBackingMapManager(DefaultConfigurableCacheFactory.java:1246)
            at com.tangosol.net.DefaultConfigurableCacheFactory.ensureServiceInternal(DefaultConfigurableCacheFactory.java:1043)
            at com.tangosol.net.DefaultConfigurableCacheFactory.ensureService(DefaultConfigurableCacheFactory.java:937)
            at com.tangosol.net.DefaultConfigurableCacheFactory.ensureCache(DefaultConfigurableCacheFactory.java:919)
            at com.tangosol.net.DefaultConfigurableCacheFactory.configureCache(DefaultConfigurableCacheFactory.java:1288)
            at com.tangosol.net.DefaultConfigurableCacheFactory.ensureCache(DefaultConfigurableCacheFactory.java:297)
            at oracle.wcps.cache.internal.coherence.CoherenceCacheFactory.createCache(CoherenceCacheFactory.java:31)
            at oracle.wcps.cache.CacheFactory.getCache(CacheFactory.java:271)
            at oracle.wcps.cache.CacheFactory.getCache(CacheFactory.java:220)
            at oracle.wcps.cache.CacheFactory.getCache(CacheFactory.java:334)
            at oracle.webcenter.content.integration.spi.ucm.UCMCacheHelper.getProfileTriggerValueCache(UCMCacheHelper.java:423)
            at oracle.webcenter.content.integration.spi.ucm.UCMCacheHelper.cacheProfileTriggerValue(UCMCacheHelper.java:259)
            at oracle.webcenter.content.integration.spi.ucm.UCMBridge.parseDocProfiles(UCMBridge.java:2068)
            at oracle.webcenter.content.integration.spi.ucm.UCMBridge.verifyDocProfileTriggerFieldDefined(UCMBridge.java:2079)
            at oracle.webcenter.content.integration.spi.ucm.UCMBridge.access$300(UCMBridge.java:50)
            at oracle.webcenter.content.integration.spi.ucm.UCMBridge$1.run(UCMBridge.java:1864)
            at oracle.vcr.jam.ConnectionWrapperTask.call(ConnectionWrapperTask.java:81)
            at oracle.vcr.jam.ConnectionWrapperTask.call(ConnectionWrapperTask.java:35)
            at oracle.webcenter.concurrent.Submission$2.run(Submission.java:484)
            at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:315)
            at oracle.webcenter.concurrent.Submission.runAsPrivileged(Submission.java:498)
            at oracle.webcenter.concurrent.Submission.run(Submission.java:424)
            at oracle.webcenter.concurrent.Submission$SubmissionFutureTask.run(Submission.java:889)
            at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:440)
            at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
            at java.util.concurrent.FutureTask.run(FutureTask.java:139)
            at oracle.webcenter.concurrent.ModifiedThreadPoolExecutor$Worker.runTask(ModifiedThreadPoolExecutor.java:657)
            at oracle.webcenter.concurrent.ModifiedThreadPoolExecutor$Worker.run(ModifiedThreadPoolExecutor.java:683)
            at java.lang.Thread.run(Thread.java:662)
    any pointer regarding the error. is it related to caching.
    thansk
    -somesh

    yes you are correct. we have two EAR one for mobile and other for desktop both are configured for cache. we tried to disable coherence cache for mobile and it worked. now next step would be to keep different name.

  • Developing desktop applications

    Hi.
    I'm coming back to desktop development. I've been away for a long time.
    In order to productively develop professional desktop applications, is JavaFX mature enough to become the right choice? Is JavaFX a complete replacement of Swing?
    Thank you.

    It would be great if there were any means of developing n-tier applications using java desktop (JavaFX in this case) as the front-end, loading dynamically both content and views. There are a few examples of potentially helpful third party frameworks and libraries to assist with this.
    It would be interesting to see if Oracle came up with an official end to end development, runtime and tooling stack for n-tier JavaFX apps.
    Consider the webfx approach of a JavaFX "browser" that consumes and renders fxml documents with attached scripts.
    https://github.com/brunoborges/webfx
    Or the sadly defunct JFX Flow project (Managing navigation flows in JavaFX clients):
    http://www.zenjava.com/jfx-flow/
    The zenjava enterprise series (connecting Spring Servers with JavaFX):
    http://www.zenjava.com/series/building-jee-applications-in-javafx-2-0/
    There is also captiancasa (merges JavaFX and JSF):
    http://www.captaincasa.com
    And open dolphin (client/server framework for JavaFX):
    https://github.com/canoo/open-dolphin
    The Henley Data sales sample app (nice example of connecting a JavaFX client app over REST to an application server backed by a relational database):
    http://www.oracle.com/technetwork/java/javafx/samples/index.html
    And j-rebirth (work in progress but includes a bunch of client application framework facilities for JavaFX):
    http://www.jrebirth.org
    And datafx (simplifies taking data streams and getting the data into the complex virtual flow JavaFX controls such as TableView and TreeView):
    http://www.javafxdata.org
    Most of the above frameworks are immature enough that you could reasonably consider developing your own rather than reusing something existing (depending upon your project). It's not like you have develop everything yourself. It's java and there is lots of existing stuff out there, especially when you start looking at client/server comms and server side processing and database access. But unfortunately there is not much that helps really pull it all together into a coherent end-to-end platform for rapid development.
    Drag and drop prototyping tools which go from UI to database aware app, like you get with something like MS Access, don't really exist for JavaFX. You can mock up the UI quick in SceneBuilder, and code up the logic for the UI controls quickly and easily enough. Systems which manage the flow of screens though aren't all that great, so you'll need to spend some time on that. You will also you need to choose and make use of appropriate libraries for stuff like session management, server communications, data transfer, etc.

  • Running Multiple Same Applications

    Hello All. I was really wondering if OSX has the ability to run the same application at the same time. Example would be like Firefox, Safari, World Of War Craft ETC... I know on a PC I can run as many instances of the same app on my PC as I needed and would like to know if this is at all possible on a MAC. Very Much appreciated for any and all intel on this subject. Please Advise...

    Brian Postow wrote:
    nerowolfe wrote:
    If you right-click textedit.app, for example, one of the options is "Show Package Contents"
    This is a NEW feature in 10.5.3 IIRC. And a feature that I am very happy with.
    It came along with the first version of Leopard, 10.5.0
    http://www.appletell.com/apple/comment/show-package-contents-can-now-be-a-simple -keystroke/
    Remember that Leopard, like most of an iceberg, is below the surface. Knowing how to use the entirety of Leopard is important for some of us. It's fun and one never stops learning new things.
    I'm not disagreeing with any of that. I'm just wondering if there is documentation on opening the actual executable files. open is NOT a standard unix command. I believe it's a mac specific thing, it doesn't exist in BSD based Ultrix, SunOS or any other unix I've used. So Apple CAN decided how it gets used, and what it does, and the documentation would have to be Apple's.
    It may be Mac-specific. The man says it was introduced with NextStep.
    However, the ancient Unix command 'exec' is nearly identical and if you replace 'open' with 'exec' in my examples, you get the same result
    For example:
    exec /Applications/TextEdit.app/Contents/MacOS/TextEdit
    runs an instance of textedit just as does 'open'
    And I still want to know how applescript interacts with this feature. Because you usually just say "tell textedit.app ....." If there are two instances, which one gets the message? and where is this documented?
    AppleScript is a different animal. I don't think 'tell' is a BSD item.
    Also, my main point above was that your comment of "look at the man page" didn't actually answer my question.
    I suggested that as a way of understanding the command, 'open' not a general tutorial on how BSD supports multiple instances of programs internally.
    For example, one may not find a document describing exactly a very complex and complicated pipe command, but a good working knowledge of the OS is sufficient to create it. Same with shell programming. There are hundreds of book on dozens of programming languages, Ruby, PHP, built-in, to name a few. And there are dozens of shells. There is no one document to describe all of it.
    I go back to Kernighan and Pike and Richie days, when I ran Coherent at home on an old PC and used Unix on mainframe terminals where I was consulting.

  • Urgent: How to execute a Client application

    Hi All,
    I have deployed a very simple ear file ( consisting of 1 session bean ) called
    HelloEjbsApp.ear in Weblogic 6.1. I want to access the method in this ejb from
    a client application. Please can anybody tell me the steps to do the same? I have
    referred to the documentation, but it isn't too clear.
    I have a HelloClient.java class inside a jar file called HelloClientJAR.jar,
    which is inside the client application called HelloClientApp.ear. As I understand,
    I should have the following 3 files for the same.
    application.xml
    application-client.xml
    HelloClientJAR.runtime.xml ( This exists in the same directory as the HelloClientApp.ear
    I then ran the following command
    java appclient.ClientDeployer HelloClientApp.ear HelloClientJAR
    It deployed properly, without any errors.
    After this, how do I exceute the HelloClient class? Please if anybody knows the
    solution to my problem, help me.
    Thanks,
    Vani

    Unless it's a J2EE "application client" which is packaged in the ear.
    Unfortunately 6.1 still doesn't support that standard.
    "Vani" <[email protected]> wrote in message
    news:[email protected]...
    >
    Thank you very much. It works now. As you said, I should use only the JNDIname
    to do lookup outside an ejb.
    Thanks,
    Vani
    "Cameron Purdy" <[email protected]> wrote:
    That means that you can only look up java:comp/env/* from inside (for
    example) an EJB. You cannot do that from a Java client. From a Java
    client,
    you look up the EJB using its "global" JNDI name. Use the WL console
    to
    peruse your JNDI tree.
    Peace,
    Cameron Purdy
    Tangosol Inc.
    Tangosol Coherence: Clustered Coherent Cache for J2EE
    Information at http://www.tangosol.com/
    "Vani" <[email protected]> wrote in message
    news:[email protected]...
    Hi All,
    I am able to execute the client application. But when I do that,I get
    the following
    exception.
    javax.naming.NamingException: java:comp/env namespace is only availablefrom within
    a J2EE component
    at
    com.sun.enterprise.naming.java.javaURLContext.getComponentContext(javaURLCon
    text.java:392)
    at
    com.sun.enterprise.naming.java.javaURLContext.lookup(javaURLContext.java:51)
    at javax.naming.InitialContext.lookup(InitialContext.java:350)
    at HelloClient.main(Unknown Source)
    Please if anybody knows the reason for this, help me.
    Thanks,
    Vani
    "Vani" <[email protected]> wrote:
    Hi All,
    I have deployed a very simple ear file ( consisting of 1 session
    bean
    ) called
    HelloEjbsApp.ear in Weblogic 6.1. I want to access the method in this
    ejb from
    a client application. Please can anybody tell me the steps to do the
    same? I have
    referred to the documentation, but it isn't too clear.
    I have a HelloClient.java class inside a jar file calledHelloClientJAR.jar,
    which is inside the client application called HelloClientApp.ear.As
    I understand,
    I should have the following 3 files for the same.
    application.xml
    application-client.xml
    HelloClientJAR.runtime.xml ( This exists in the same directory asthe
    HelloClientApp.ear
    I then ran the following command
    java appclient.ClientDeployer HelloClientApp.ear HelloClientJAR
    It deployed properly, without any errors.
    After this, how do I exceute the HelloClient class? Please if anybody
    knows the
    solution to my problem, help me.
    Thanks,
    Vani

  • Is Adobe ever going to make their products coherent?

    It's truly driving me nuts that each product has it's own behavior, it's own shortcuts and so.
    I know you eg. bought Flash with it's wierd shortcuts, but coudn't you just add an option to install CS as it is now (that means handfull of stand-alone applications which don't have much in common for those who are already used to it) and another installation variant with coherent and unified control and behavior over all CS produtcs?

    Well, nothing is impossible but my personal guess (and it is just a guess)  would be that the more OS X sandboxes, the less likely this becomes.

  • Optimizing a cad/cam application

    We have rolled out the 512 wae's to the edges and 7326 wae's to the core and having an issue with a cad/cam app as it's very slow...Does anybody have any experience with "taming" a cad/cam app in the wae's?
    thanks..

    If the files are accessed using a CIFS share, or via NFSv2 (neither sound like they are the case, but CAD/CAM applications typically involve accessing a file share), we can provide latency reduction, caching, and protocol optimizations, which dramatically increase performance of accessing packages and files contained within packages without compromising coherency. DRE will minimize the transfer of repeated chunks of TCP data and should be very effective with CAD/CAM files as they are uncompressed and contain repeatable sequences.

Maybe you are looking for

  • Pls help me with this installation problem. Your advice is highly needed.

    I am installing oracle 11.1.6.0 on windows xp professional everything was going fine untill there was a pop up that reads below INFO: exit-tool: Launch browser INFO: saving exit only tools ... INFO: no detached only tools in this session INFO: exit-o

  • Itouch 2.1 update

    Hey Everybody! I have an itouch 1.1.5 (jailbroken) i bought the 2.1 update for my itouch so i could access the app store. but the update wont install on my itouch and the app store wont appear. what do i do?

  • Adding Pictures/Video to Drop Zones

    Hello All, I've created a drop zone in motion and saved it as a master template. However when I bring it into FCP I have no idea how to place my footage into the drop zone. Whenever I drag something into the canvas it just overwrites the template. Al

  • Problem with downloading TRAILERS from MusicStore

    Hello I'm trying to download a few movie trailers from the MusicStore. I've searched through this forum an found out that other users had the same question: How does it work??? There are people who say that there is a button "iPod" near "Small, Mediu

  • Why do you not use projects? When to use them.

    I responded to a post about what mistakes novice LabVIEW developers commonly make.  One I feel is a common problem is not wrapping up closely coupled reuse code into projects that modularize code sections. As examples there are nice Instrument driver