Is BC4J Required?

Can you use JDeveloper without using BC4J?
Thanks.

Yes, you can.
JDeveloper is full fledged IDE to develop Java, J2EE, PL/SQL applications with or without using framework.
raghu
JDev Team

Similar Messages

  • Anyone deploy ADF(UIX,Struts,BC4J) to 9iAS 9.02?

    Has anyone been successful in deploying a ADF 10g app using UIX/Struts/BC4J to Oracle 9iAS 9.02?

    Deploying a UIX application directly from JDeveloper 10g to iAS 9.0.2 isn't supported out of the box. You can deploy directly to iAS 10g (9.0.4), standalone OC4J 10g (9.0.4) instances (one is included with JDeveloper 10g), iAS 9.0.3 Java edition, standalone OC4J 9.0.3, and selected third party servlet engines.
    There are two issues that you would need to workaround to deploy a 10g ADF application to iAS 9.0.2. One issue is that 9.0.2 versions of some of the ADF libraries (BC4J and UIX for example) are on the global application.xml classpath of the iAS 9.0.2 customer home OC4J instance. You would need to manually upgrade your 9.0.2 instance to have all of the ADF 10g libraries. The second issue is that some of the ADF 10g libraries (like BC4J) require JDK 1.4, and iAS 9.0.2 shipped with an earlier version of the JDK. I personally don't know if using iAS 9.0.2 with JDK 1.4 is a supported combination, but I will try to find out for you.
    By the way, you might wonder why we don't have these same problems with with iAS 9.0.3 and 9.0.4 since the ADF 10g libraries are more recent than what shipped with those releases. In OC4J 9.0.3 and 9.0.4 there is a "search-local-classes-first" option in orion-web.xml that allows classes provided as part of a web application to be loaded in preference to what is on the global application.xml classpath. We use this feature to deploy ADF 10g applications (and include the JARs for some of the ADF libraries in the WEB-INF/lib of the application). In addition, there is a tool called the ADF Installer that is part of JDeveloper that will upgrade versions of some of the backward compatible ADF libraries (like BC4J) in the global application.xml.

  • BC4j/JSP Application not responding after some time - when deployed on 9ias BC4j/JSP

    Hi,
    We are using BC4j/jsp application on 9ias. The application is not responding
    after some time. We have installed 9ias on PIII(384MB RAM). We tried to accesses
    with 10 users, and server is not responding to BC4J/JSP application.
    However the server could able to publish the JSP pages with standerad JDBC code even after that.
    Please....help us.........
    many many thanks in advance

    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Is there any mechanism that cleans up these connections (back down to the initial or some other minimum I would guess) or do they hang around until either the app server or database shuts down?<HR></BLOCKQUOTE>
    There is currently no mechanism for reducing the connection pool size after a period of high activity. Recently this has been frequently requested and as such will be implemented in the next production release.
    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>We have verified this in manual testing. However, when the load tool script exits it doesn't seem to release resources. We know this because we keep seeing our database connections go up and up as more tests are run. Further, we also seem to see more than one connection per "virtual user". For example, when I connect 5 users to the app in manual testing, I get 5 connections. But, when we run a test using the tool, we get 395 database sessions for 200 users. We are having a bit of difficulty understanding why the behavior is different.<HR></BLOCKQUOTE>
    Assuming that the you are performing your manual testing against the same instance of the application on which you are performing your load testing, I would assume that the connections are being released to the pool at the end of the request. One possible reason for the approximate 2:1 ratio between connections and virtual users may be BC4J's use of internal connections. What version of BC4J are you using?
    BC4J requires an internal connection to support state management and spill to disk. The internal connections are pooled with the transaction connection and only held for the duration of the persistence operation. However, if the web server is very busy then a large number of synchronous persistence requests may be received which would explain the eventual 2:1 ratio in the pool's high water mark.
    If the user start times and think times are staggered in order to reduce the incidence of synchronous persistence requests does the ratio of connections to web sessions stabilize at some lower number (i.e. 1.5:1)

  • Does BC4J need high network bandwidth ?

    Hi,
    Recently i've done some development with BC4J and test it out against another vendor (BEA,IBM).
    Our test scenario is using 5 PC, each running some applications.
    for LAN : i run 30 applications in each PC ( 5 PC x 20 applications = 100 Applications Concurrent )
    for Modem 64 Kbps : i run 1 applications in each PC ( 5 PC x 1 applications = 5 Applications Concurrent )
    Problem:
    for LAN the result is fine, but for Modem 64 Kbps i have to increase the concurrent applications since the number of applications is still to small( 5 ),when i monitor the network usage,it seems that my application used all available bandwidth (64Kbps) at apprx.7 concurrent applications.
    Questions:
    is BC4J need high bandwidth ? or where should i look to tune my applications to use lower bandwidth ?
    Thanks in advance,
    Ricky HP

    Hi Shay,
    sorry for late respons..
    finally we have finished the POC (Prove Of Concept) session,and comes out with one big question why bc4j require high network bandwidth.
    Weblogic team is doing good, they have good performance and good usage of network.But the good news is our client want to use Oracle ADF Framework as their development tools. :)
    so here i am, i have to solve about this network bandwidh usage issue.
    to answer your question about architecture:
    In last POC process,we developed simple client(without gui).
    the bc4j components is placed in another linux machine with Oracle 10g Java Edition installed,so the communication between client and bc4j is made through RMI/JNDI,and the communication is made using dial up connection with limited bandwidth network ( 64Kbps modem)
    client program is design to loop for several times,to call method in bc4j components.we calculate the time before method is called and after the method is called.
    BC4J has good performance but lack in usage network bandwidth.
    i've read steve muench tips and tricks for tuning,but seems didn't help a lot in limited network bandwidth environment.
    Any help will be appreciated.
    Sorry again for late response and thanks a lot
    Cheers,
    Ricky H.P.
    System Analyst / Analyst Programmer
    PT.Perkasa Pilar Utama
    Jakarta - Indonesia

  • Attribute required during remove of Row (BC4J)

    Hi people,
    I'm getting an "JBO-27014: Attribute <attributeName> in <viewObjectName> is required" when I try to issue a commit after a myRow.remove() using BC4J. This behaviour ocurs only when the row has been inserted in the same Application Module instance.
    I have tried clearing the view's cache, synchronizing the entire application module, etc. And nothing seems to work.
    Can you give me an advice?
    This is the piece of code where I get the exception:
    ComidaAppImpl comidaApp = (CcsComidaAppImpl)request.getSession().getAttribute("APPMODULE");
    comidaApp.clearVOCaches(null,false);
    ProductosProvEstViewImpl prdProvEstView = comidaApp.getProductosProvEstView();
    Row prdRow = prdProvEstView.getRow(new Key(new Object[] {"SV","CER",new Number(40)}));
    prdRow.remove();
    comidaApp.getTransaction().commit();
    by the way, the exception happens while trying to commit the transaction.
    Best regards,
    Mauricio Peccorini

    Can you give me an advice?For some reason validate() is being called on an entity that's been removed. It'd help if you can post the "stack trace" of this exception to know where the validate() gets called.

  • Websphere deployment required edit of bc4j.xcfg file

    Coming from this thread:
    Websphere 5.1 and ADF/UIX
    We've deployed an ADFUIX application to IBM Websphere, but are seeing strange requirements. The server could not get a jdbc connection until we edited the bc4j.xcfg file from having an encrypted password to a human readable one. Can someone from Oracle address this? It would seem the encryption isn't making it through. Do we need to use a different set of drivers?
    Thanks.

    Hello!
    I got the same problem with Tomcat 3.2. Now I tried Tomcat 4.0.1
    and it works.
    Bye,
    Andreas

  • JBO:33001 bc4j.xcfg file not found in class path

    Hi,
    I am yet another victim of the age-old error JBO:33001 bc4j.xcfg file not found in class path, When i have my BC4JApp.jar in Tomcat Web-inf/lib directory. All the other jar files and class files in my webserver-application web-inf classes and lib directory works.
    But Tomcat server is not able to read this bc4j.xcfg file. I can see in my jar file that this bc4j.xcfg exists and in the specified package directory. still the problem persists. My BC4JApp.jar is perfectly working when i use JDeveloper. but not when i use tomcat4.0 and call a JSP using BC4JApp.jar from browser (My environment is Jdeveloper3.2, Tomcat4.0+IIS in middle tier and oracle 8i as DB, everything on windows2k)
    I have gone through almost all the threads possible that relates to this error in this form. None of them have a answer except to say "put the file in classpath". and last reply is "will fix in jDeveloper 9i. So what happens to us who are working in Jdeveloper 3.2?
    1. I have this file in my jar file.
    2. I also tried creating a seperate directory manually, with the same name as my package under web-inf/classes, web-inf/lib , just under web-inf directory and atlast under approot directory also. I tried having my package directory containing bc4j.xcfg in these folders one at a time and also tried having this directory in all these folders at the same time.
    Still no solution.
    Itz frustrating that neither proper documentation nor a right url page nor i am aware of available addressing this. page links given in above threads only gives me the wonderful page of ie's "Page cannot be displayed".
    Is there a answer to this error and my problem. If this doesn't work, then i have to all the way develop from scratch creating my jsp using JDBC calls and Stored packages etc.
    I don't want to give up on this Jdeveloper at this final moment because if this bc4j.xcfg file is found, my application will work perfectly. on these final moments, if this doesn't work, i am frightened to imagine to develop my application in standard way. Atlast, if thatz the option left,we have to do that bcos our production date is close by.
    Please can some one in this forum or Jdeveloper help me to solve this problem. I am desperate and very urgent.
    Waiting for a reply from Jdev team very much...
    ( I just posted in the other thread which is pretty old, dated backto May 2001, which was relevant to this error. Just to make sure it is noticed, I am posting it seperately too)
    Thanks
    Hari(2/3/02)

    Hi All,
    For those who are following this thread, I got a solution for this error with the help of Jdev Team.
    This solution may work, if you have deployed your application in Tomcat4.0.1. This is the environment in which I work and tested.
    As you may be aware, Tomcat ignores value in CLASSPATH variable.
    To see any files that are existing or newly deployed, it has it own way of detecting it.
    Addition information on Tomcat working, you can follow this link,
    http://jakarta.apache.org/tomcat/tomcat-4.0-doc/index.html
    Coming to point, Tomcat has got five classloaders and each classloader invoked, looks in their related directories for files in following order.
    1. /WEB-INF/classes of your web-application
    2. /WEB-INF/lib/*.jar of your web application
    3. BootStrap classes of your JVM (Tomcat's $JAVA_HOME/jre/lib/ext)
    4. System class loader classes($CATALINA_HOME/bin/bootstrap.jar,CATALINA_HOME/lib/tools.jar)
    5. $CATALINA_HOME/common/classes
    6. $CATALINA_HOME/common/lib/*.jar
    7. $CATALINA_HOME//classes
    8. $CATALINA_HOME/lib/*.jar
    So All your individual application related files should be deployed in your application's WEB-INF/classes or WEB-INF/lib directory accordingly.
    If your application files are unpacked, they should be deployed or copied under WEB-INF/classes directory
    if the files are within a jar, they should be under WEB-INF/lib directory.
    If your Jar-files contains bc4j components, then those jar files should be deployed under WEB-INF/lib directory. Also,do the next step to copy all relavant BC4J runtime libraries under lib directory.
    IMPORTANT: Please remember to copy and paste all the required BC4j runtime libraries in the Same WEB-INF/lib directory along with your application jar files. This is the real reason which can solve this JBO:33001 to disappear. It worked for me.
    To configure your directory for tag-lib uri's, use web.xml to set the taglib-uri attribute.
    Put your web.xml and DataTags.tld in the WEB-INF directory.
    Your simple web.xml may look like as follows.
    <?xml version="1.0" encoding="ISO-8859-1"?>
    <!DOCTYPE web-app
    PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
    "http://java.sun.com/dtd/web-app_2_3.dtd">
    <web-app>
         <taglib>
              <taglib-uri>
                   /webapp/DataTags.tld
              </taglib-uri>
              <taglib-location>
                   /WEB-INF/DataTags.tld
              </taglib-location>
         </taglib>
    </web-app>
    You may then modify this web.xml to suit further requirements of your application.
    Remember to stop and restart the Tomcat Server (service) by using shutdown and startup scripts after updating any jar files/class files/ JSP or source files deployed in Tomcat.
    Sometimes, only this helps even though your context's reloadable attribute is set to true in Tomcat Server's server.xml file.
    Hope this above information helps you to solve this error in Tomcat environment. My Sincere thanks once again to Juan and Jdev team for their help and efforts to solve this problem.
    Thanks
    Hari

  • HOW TO: Set up your application server to run BC4J

    How To set up your application server to run BC4J.
    INTRODUCTION
    A running BC4J application is actually the combination of:
    * Your own application files
    * BC4J runtime libraries
    In order to successfully run your BC4J application in local mode, the first requirement is
    that your application server contains the necessary BC4J libraries.
    This How To describes the steps required to ensure that you have a functional
    BC4J runtime environment installed on your application server.
    Oracle IAS 1.0.2 and Tomcat 3.1 will be used as examples.
    THE BC4J RUNTIME LIBRARIES
    Whatever application server you deploy to, the following libraries
    are required in the following order to be in the classpath.
    BC4J Libraries:
    xmlparserv2.jar
    jdev-rt.zip
    jbojdbcpatch.zip
    connectionmanager.zip
    jbohtml.zip
    jboimdomains.zip
    ordim817.zip
    ordvir817.zip
    ordhttp.zip
    jbomt.zip
    jbodomorcl.zip
    jboremote.zip
    jndi.jar
    jbodatum12.zip
    These libraries can be found in <JDEV_HOME>/lib/
    INSTALLING THE LIBRARIES ON IAS:
    Installing the libraries is simply a matter of copying them to the
    application server's filesystem and adding them to the classpath.
    IAS's classpath can be modified by editing the file:
    <IAS_HOME>\Apache\Jserv\conf\jserv.properties
    In this file you'll find the existing pre-installed BC4J libraries which
    looks like this:
    wrapper.classpath=<IAS_HOME>\Apache\BC4J\lib\ordvir817.zip
    wrapper.classpath=<IAS_HOME>\Apache\BC4J\lib\ordim817.zip
    etc.
    Note! These BC4J libraries correspond to JDeveloper 3.1.1.
    In order to run JDev 3.2 based applications you will have to update these libraries
    to JDeveloper 3.2 production.
    Steps:
    1. Copy (or FTP) the JDev 3.2 BC4J libraries from <JDEV_HOME>\lib to a NEW directory on the
    appserver's filesystem called:
    <IAS_HOME>\Apache\BC4J\newlib
    2. Modify the classpath by editing <IAS_HOME>\Apache\Jserv\conf\jserv.properties.
    Example: (modified classpath entries)
    # New 3.2 BC4J Runtime libraries
    wrapper.classpath=<IAS_HOME>\Apache\BC4J\newlib\xmlparserv2.jar
    wrapper.classpath=<IAS_HOME>\Apache\BC4J\newlib\jdev-rt.zip
    wrapper.classpath=<IAS_HOME>\Apache\BC4J\newlib\jbojdbcpatch.zip
    wrapper.classpath=<IAS_HOME>\Apache\BC4J\newlib\connectionmanager.zip
    wrapper.classpath=<IAS_HOME>\Apache\BC4J\newlib\jbohtml.zip
    wrapper.classpath=<IAS_HOME>\Apache\BC4J\newlib\jboimdomains.zip
    wrapper.classpath=<IAS_HOME>\Apache\BC4J\newlib\ordim817.zip
    wrapper.classpath=<IAS_HOME>\Apache\BC4J\newlib\ordvir817.zip
    wrapper.classpath=<IAS_HOME>\Apache\BC4J\newlib\ordhttp.zip
    wrapper.classpath=<IAS_HOME>\Apache\BC4J\newlib\jbomt.zip
    wrapper.classpath=<IAS_HOME>\Apache\BC4J\newlib\jbodomorcl.zip
    wrapper.classpath=<IAS_HOME>\Apache\BC4J\newlib\jboremote.zip
    wrapper.classpath=<IAS_HOME>\Apache\BC4J\newlib\jndi.jar
    wrapper.classpath=<IAS_HOME>\Apache\BC4J\newlib\jbodatum12.zip
    Note: Make sure to remove or comment out the existing 3.1.1 BC4J library entries!
    To see the changes, you must restart IAS and that's it, your IAS will be updated with
    the JDev 3.2 BC4J libraries which allow you to run BC4J Data Tags among other
    things!
    INSTALLING THE LIBRARIES ON TOMCAT
    As before, this process involves both the copying of the libraries
    and modifying the classpath.
    After copying the BC4J libraries to a path accessible from Tomcat,
    you can modify Tomcat's classpath by editing it's startup script:
    <TOMCAT_HOME>\bin\tomcat.bat (NT)
    <TOMCAT_HOME>\bin\tomcat.sh (Unix)
    Here is a portion of a modified tomcat.bat (on NT)
    rem Add BC4J libraries
    set CLASSPATH=%CLASSPATH%;D:\bc4j_lib\xmlparserv2.jar
    set CLASSPATH=%CLASSPATH%;D:\bc4j_lib\jdev-rt.zip
    set CLASSPATH=%CLASSPATH%;D:\bc4j_lib\jbojdbcpatch.zip
    set CLASSPATH=%CLASSPATH%;D:\bc4j_lib\connectionmanager.zip
    set CLASSPATH=%CLASSPATH%;D:\bc4j_lib\jbohtml.zip
    set CLASSPATH=%CLASSPATH%;D:\bc4j_lib\jboimdomains.zip
    set CLASSPATH=%CLASSPATH%;D:\bc4j_lib\or dim817.zip
    set CLASSPATH=%CLASSPATH%;D:\bc4j_lib\ordvir817.zip
    set CLASSPATH=%CLASSPATH%;D:\bc4j_lib\ordhttp.zip
    set CLASSPATH=%CLASSPATH%;D:\bc4j_lib\jbomt.zip
    set CLASSPATH=%CLASSPATH%;D:\bc4j_lib\jbodomorcl.zip
    set CLASSPATH=%CLASSPATH%;D:\bc4j_lib\jboremote.zip
    set CLASSPATH=%CLASSPATH%;D:\bc4j_lib\jndi.jar
    set CLASSPATH=%CLASSPATH%;D:\bc4j_lib\jbodatum12.zip
    rem Add Oracle JDBC library
    set CLASSPATH=%CLASSPATH%;D:\bc4j_lib\classes12.zip
    Note: I also added the Oracle JDBC library since Tomcat does not have it.
    It is found at:
    <JDEV_HOME>\jdbc\lib\oracle8.1.7\classes12.zip
    And That's It!
    When Tomcat is restarted using this script, the necessary BC4J libraries
    will be in the classpath..
    A follow up How To:"How To Deploy a BC4J JSP Application on IAS and Tomcat"
    will be posted shortly!

    I copied the following files in jserv classpath
    bc4jct.jar
    bc4jctejb.jar
    bc4jdomorcl.jar
    bc4jhtml.jar
    bc4jimdomains.jar
    bc4jmt.jar
    bc4jmtejb.jar
    bc4juixtags.jar
    collections.jar
    datatags.jar
    jdev-cm.jar
    regexp.jar
    share.jar
    uix2.jar
    cabo.war
    classes12.jar
    nls_charset12.jar
    ordim.jar
    ordhttp.jar
    runtime12.jar
    jdev-rt.jar
    xmlparserv2.jar
    bc4j_jclient_common.jar
    webapp.war
    I got this list from Jdev 9031 on-line help
    I also copied the new DataTags.tld file to /webapp directory
    When i run my jsp page i get this error..
    java.lang.NoClassDefFoundError: java/util/TimerTask
         at oracle.jbo.http.HttpContainer.findSessionCookie(HttpContainer.java:693)
         at oracle.jbo.html.jsp.datatags.ApplicationModuleTag.doStartTag(ApplicationModuleTag.java:148)
         at jspapp.odrjsp__html._menu._jspService(Compiled Code)
         at oracle.jsp.runtime.HttpJsp.service(HttpJsp.java:119)
         at oracle.jsp.app.JspApplication.dispatchRequest(Compiled Code)
         at oracle.jsp.JspServlet.doDispatch(Compiled Code)
         at oracle.jsp.JspServlet.internalService(Compiled Code)
         at oracle.jsp.JspServlet.service(Compiled Code)
         at javax.servlet.http.HttpServlet.service(Compiled Code)
         at oracle.portal.provider.v1.http.JspRenderer.renderBody(JspRenderer.java:116)
         at oracle.portal.provider.v1.RenderManager.render(RenderManager.java:164)
         at oracle.portal.provider.v1.http.ServletProviderResponse.showPortlet(Compiled Code)
         at oracle.portal.provider.v1.http.HttpProvider.dispatchProviderAction(Compiled Code)
         at oracle.portal.provider.v1.http.HttpProvider.service(Compiled Code)
         at javax.servlet.http.HttpServlet.service(Compiled Code)
         at org.apache.jserv.JServConnection.processRequest(Compiled Code)
         at org.apache.jserv.JServConnection.run(Compiled Code)
         at java.lang.Thread.run(Compiled Code)
    In the JDK 1.3 APi docs, i found that TimerTask was introduced only in JDK 1.3
    Does this mean that BC4J (in jdev 9031) will only work
    with JDK 1.3 or later?
    Thanks for your time.
    Harish

  • Jsp,bc4j,Data web Bean , error : NO ROWS AVAILABLE FOR EDITING

    HI
    I'm developping a jsp application based on Bc4j. when trying to insert a new row with missing fields which must be not null,
    in order to be able to edit the row and correct the non seized fields, I display the edit page and it works for several views. but this time when editing fields and submitting the edit form an error is raised with the message no rows available for editing.
    the particularity for these views(which causes the error) is that are details for a view which is detail for an other.
    can someone please suggest some solution for such a problem
    thanks in advance
    Ghassen
    null

    ghassen
    this is a typicall error that occurs when trying to execute the Row data tag with action "Update" and there is not row obtained through the rowkeyparam (normally MyRowKey url parameter passed from the Edit page). I don4t have sufficient information to give you an exact solution.
    I don4t understand all your escenario, you spoke about "Insert new row with missing values in required fields", but if you don4t specify a right value to that fields, the insert fail.
    Then you display the Edit page to edit that just inserted row, to correct (specify?) the values of that fields. The error occurs in the EditSubmit page.
    The EditSubmit page execute de Row data tag, according to the implementation of Rowtag, first recover the row reference (from rowkeyparam url parameter) and then, if that row reference is null, throws the "No rows available for editing" Runtime Exception. This means that the datasource used in your EditSubmit page not include that RowKey reference (obtained from Edit page as Url parameter).
    HTH
    Pepe

  • JUNIT test failure-Configuration file bc4j.xcfg not found in the classpath

    Hi All,
    As part of an ESS project,Im having a model project containing a VO(parameters VO).This VO is configured to have Read-only access through SQL query and have only one transient attribute each.For the model projects containing the VO for pre merge checker compliance I had to create JUNIT Test projects containing new AMs for testing the parametersVO. While running the JUNIT tests I got an exception like
    “oracle.jbo.JboException: JBO-29000: Unexpected exception caught: oracle.jbo.ConfigException, msg=JBO-33001: Configuration file /oracle/apps/hcm/goals/core/dataMigration/publicEssModel/test/applicationModule/common/bc4j.xcfg is not found in the classpath.”.—even though this file is contained in both the src/classes folder of the project.
    When i try to run the TestAM I'm getting an exception like 'configuration tester.xcfg not found in the calsspath.
    While debugging this error, we found that we are able to successfully run the JUNIT tests if we make some changes in the adf-config.xml file of the Application. The change required is to comment out the mdsC:adf-mds-config tag in the xml file.
    After doing this change Im also able to run my AM without any exception.
    Is this a known issue?.
    Since modifying the adf-config.xml is not a recommended practice is there any workaround that we can get rid of this exception.
    Regards,
    Ajin.

    Just checked but could only find this thread Unable to run ADFBC JUNIT Test Classes with JDEV11G 11.1.1.6
    As it's also dealing with junit and 11.1.1.6.0 you might want to read it.
    Timo

  • What is the benefit of using BC4J?

    Folks,
    After working with BC4J for three months, I still can not convince my manager to use BC4J. His major arguments are:
    1. Which applications or web sites are implemented using BC4J? Are they real application or just a demo. For the time being, I even can not show him a demo, not to say any real web applications.
    2. His developers told him that the O-R mapping provided by BC4J, which is probabably one of the key benefit of BC4J can be easily coded manually with a couple of days work for the current task and we have the full control over our own code while BC4J is not an open source and the lack of the support from Oracle really worries him.
    Can someone in Jdev team give me a clear evidence to convince him?
    Thanks,
    Yibing

    [list]
    [*]With regard to struts integration with BC4J, I have done some investigations of the new release and know that BC4JActionForm is only good for simple view and does not work for a joint table view as I have reported a few days ago in this group and no response is received yet.
    This should not be the case. Should work for any view object. View objects can contain join queries with any number of updateable tables in them. Please email me the URL to the forum posting so I can track down the issue.
    [*]I have been recently told indirectly from Oracle that the consulting group at oracle are not using BC4J and instead they think that BC4J only applies to simple applications with limited number of tables and relationships.
    This is plain incorrect. We have very large applications using BC4J both internal in Oracle Applications, for Oracle iLearning, and many external customers. Many of these projects have involved (and are currently involving) Oracle Consulting. Not sure where got this information, but it is incorrect.
    [*]Other commecial O-R mapping products such as top-link should be used for large applications
    The key difference between Oracle9i TopLink and Oracle9i BC4J has nothing to do with the size of your project. The fundamental difference is that toplink is for customers who have already written a custom application framework and who require just a persistence architecture, because they've already hand-written code to implement all of the other J2EE design patterns that are required to build real J2EE applications.
    Conversely, BC4J is for customers who want a complete J2EE Application Framework (and tightly integrated, award-winning toolset to go with it) to avoid having to write, test, debug, and maintain their own application framework.
    There is simply no evidence to backup your statement that BC4J only works for small applications. I am aware of at least 20 (and by now after a summer full of training additional Oracle Apps development teams in BC4J, perhaps over 30) that are using BC4J for full-scale, self-service J2EE web applications. Our BC4J reference info pages (link in this thread above) have references to customers who are using BC4J for large applications as well.
    [list]
    Hope this helps.

  • HOWTO: Use BC4J With or Without DB Triggers

    This HowTo describes how to use BC4J, database sequences and triggers
    and what are the ramifications.
    INTRODUCTION
    BC4J has the ability to work with database sequences in order to obtain a
    unique value when inserting records. BC4J also has the ability to
    work either with a 'before insert' trigger which automatically creates
    a new unique value for the primary key or without a trigger. When not using
    a database trigger, BC4J also has the ability to obtain the sequence value
    and set the primary key value.
    Before discussing the ramifications of using one approach or the other, let's
    show examples of how to use both approaches:
    BC4J & sequences WITH a database trigger
    and
    BC4J & sequences WITHOUT a database trigger
    HOWTO DEMONSTRATION STEPS
    To illustrate both scenarios a simple database setup script is provided which
    creates two tables:
    CUSTOMER_NT which DOES NOT have a before insert trigger and
    CUSTOMER_WT which DOES have a trigger.
    Database Install Script:
    <code>
    drop trigger customer_insert_trigger;
    drop table customer_wt;
    drop table customer_nt;
    drop sequence customer_wt_seq;
    drop sequence customer_nt_seq;
    create sequence customer_wt_seq start with 1;
    create sequence customer_nt_seq start with 101;
    create table customer_wt(
    id number,
    name varchar2(30),
    constraint
    customer_wt_pk
    primary key (id)
    create table customer_nt(
    id number,
    name varchar2(30),
    constraint
    customer_nt_pk
    primary key (id)
    prompt Inserting data...
    insert into customer_wt (id, name)
    values (customer_wt_seq.nextval, 'Mickey');
    insert into customer_wt (id, name)
    values (customer_wt_seq.nextval, 'Goofy');
    insert into customer_nt (id, name)
    values (customer_nt_seq.nextval, 'Daffy');
    insert into customer_nt (id, name)
    values (customer_nt_seq.nextval, 'Porky');
    commit
    prompt Creating trigger
    create trigger customer_insert_trigger
    before insert on customer_wt for each row
    begin
    select customer_wt_seq.nextval into :new.id from dual ;
    end;
    </code>
    The next step is to create the DEFAULT Entity Objects and View Objects using
    the Business Components Wizard.
    USING BC4J WITH A DATABASE TRIGGER
    Let's modify the entity object CustomerWt so it can use the database trigger.
    Edit the entity object CustomerWt by right-clicking in the navigator.
    Click on the 'Attribute Settings' tab and edit the ID attribute.
    - Uncheck 'Mandatory'checkbox. This allows you to insert without a value for the primary key
    - Check 'Refresh after Insert'. This obtains the value from the database generated by the trigger.
    - Check 'Updateable While New'. Id is only updateable when inserting.
    Click finish to complete the wizard. Save all and recompile the project.
    Now let's test our work.
    In the navigator right-click the application module and select 'Test..'. This will launch
    BC4J's built in tester. Connect to the application.
    In the tester double-click the CustomerWtView view object to run a test edit form.
    After the edit form renders, navigate through the existing records using the navigate
    buttons on the edit form. Now let's insert a record to execute the trigger.
    click on the '+' button to insert a record. Enter a value in the 'Name' field and commit the change.
    Observe that a new value has automatically been inserted into the Id field.
    That's it! You have successfully used BC4J and a database trigger.
    Now let's try it without a trigger..
    USING BC4J WITHOUT A DATABASE TRIGGER
    Now edit the entity object CustomerNT so it doesn't need a database trigger.
    Similar to before, edit the entity object CustomerNt by right-clicking in the navigator.
    Click on the 'Attribute Settings' tab and edit the ID attribute.
    - Uncheck 'Mandatory'checkbox.
    - Check 'Updateable While New'.
    An additional step is also required. The Create method will have to be modified to extract
    the value of the sequence.
    In the Edit EntityObject Wizard click the Java tab and select Create method and click Finish.
    The create method is generated in your Java fil e. In the Workspace view of the Navigator,
    expand the CustomerNt entity object in the navigator. Double-click
    CustomerNtImpl.java to open it in the Source Editor. In the Structure pane, double-click
    create(AttributeList). Modify the Create method so it looks like this:
    <code>
    public void create(AttributeList attributeList) {
    super.create(attributeList);
    SequenceImpl s = new SequenceImpl("customer_nt_seq", getDBTransaction());
    Integer next = (Integer)s.getData();
    setId(new Number(next.intValue())); }
    </code>
    Save and compile the project.
    Now test the ViewObject CustomerNtView using the tester as before.
    In the edit form of CustomerNTView click on the '+' to insert a record. Observe that
    just as before a new value has automatically been inserted in the ID field!
    TO USE A DB TRIGGER OR NOT TO USE A DB TRIGGER.
    Using a Database trigger sometimes preferable if you have non BC4J applications
    also sharing the database. In this case it is still safest to just let the database
    update it's own primary keys.
    If you don't have any other non-BC4J applications sharing the database, then not using
    a database trigger is perfectly acceptable and can have slightly better performance.
    The important thing to remember is that the option is yours to use either approach!
    null

    Thank you for the reply Jonathon. I am using a ViewObject which
    consist of several tables. I haven't tried the DB trigger
    approach but just using the BC4 approach in overriding the
    create method.
    Here is the parent class create as a part of the
    FasNameImpl.java file which does the job correctly.
    public void create(AttributeList attributeList) {
    super.create(attributeList);
    SequenceImpl l_seq = new SequenceImpl
    ("SEQ_CUSTOMER_ID",getDBTransaction());
    Integer l_next = (Integer)l_seq.getData();
    setCustomerId(new Number(l_next.intValue()));
    This is when I triedpassing the value to the child table. But I
    can't figure it out. I think the link is working fine if I had a
    ViewLink deployed but it doesn't look like it's doing the job
    for ViewObject.
    I am trying to call the childclass.method
    (FasCustomer.setCustomerId(l_next);
    But I am getting error.
    Thanks a lot for your suggestions,
    Kamran
    703 696 1121

  • RowSetInfo; bc4j; how to get the View Object

    So I'm trying to get/update/insert/delete records in a database that contain an interMedia image in a blob.
    I've figured out that I can't simply set the ImmediateAccess attribute. It doesn't like that...
    So I'm trying to go after the view object, since the interMedia white paper uses a VO row setAttribute to accomplish the write.
    RowSetInfo extends ResultSetInfo which has a method getViewObject(). Cool.
    So I try it... and get an error that getViewObject() has protected access.
    Anyone know what I am doing wrong? Or should I be even taking this approach?!?!?!
    If I go exclusively with the VO layer... how do I preserve the navigationBar functionality? Or do I need to roll my own?
    ( NOTE: This hilights another example of the perception of 'friction' between rowsetinfos and the view objects/entity objects. An approach that makes "sense" to me as a naive novice didn't pan out. And oddly, most of the bc4j examples go against VOs when, if you are an application programmer, you may never see or use the VO methods ( although it looks like we should be)... we're working at the ResultSetInfo layer. )
    Is the the observation of other folk who are building Java Applications/Applets? Or do you all work directly with VOs instead of going through the ResultSetInfo "layer"?

    Here is some sample code that I am currently working on and will post on OTN when complete. The code shows how to access a BC4J Domain based on an Oracle type. Working with interMedia is similar since interMedia utilizes Oracle Object types. Please note that I have not tested this yet against interMedia, but I'm hoping that you may find the general process useful.
    // Copyright (c) 2000 Oracle Corporation
    package ObjectSampleDAC;
    import oracle.dacf.control.swing.*;
    import javax.swing.*;
    import oracle.dacf.dataset.*;
    import oracle.dacf.dataset.connections.*;
    import java.awt.*;
    import oracle.jdeveloper.layout.*;
    import java.awt.event.*;
    import javax.infobus.*;
    import oracle.jbo.domain.DomainInterface;
    import ObjectSampleBC4J.common.TAddress;
    import java.sql.SQLException;
    * A Frame class.
    * <P>
    * @author Scott Tiger
    public class Frame1 extends InfoFrame {
    * Constructs a new instance.
    public Frame1() {
    super();
    try {
    jbInit();
    sessionInfo1.publishSession();
    // call my initialization method
    bfInit();
    catch (Exception e) {
    e.printStackTrace();
    * Initializes the state of this instance.
    private void jbInit() throws Exception {
    /* All of the following code in this method was added by the designer except where noted below
    EmailrowSetInfo1.setName("Email");
    jPanel3.setLayout(gridBagLayout1);
    StatusrowSetInfo1.setName("Status");
    AddressrowSetInfo1.setName("Address");
    PasswordrowSetInfo1.setName("Password");
    UsernamerowSetInfo1.setName("Username");
    LastnamerowSetInfo1.setName("Lastname");
    FirstnamerowSetInfo1.setName("Firstname");
    IdrowSetInfo1.setName("Id");
    rowSetInfo1.setAttributeInfo( new AttributeInfo[] {
    IdrowSetInfo1,
    FirstnamerowSetInfo1,
    LastnamerowSetInfo1,
    UsernamerowSetInfo1,
    PasswordrowSetInfo1,
    AddressrowSetInfo1,
    StatusrowSetInfo1,
    EmailrowSetInfo1} );
    this.setDataItemName("infobus:/oracle/sessionInfo1");
    this.setTitle("Customer Information");
    this.getContentPane().setLayout(borderLayout1);
    this.setSize(new Dimension(536, 473));
    jPanel1.setLayout(borderLayout2);
    sessionInfo1.setAppModuleInfo(new ModuleInfo("ObjectSampleBC4J", "ObjectSampleBC4JModule"));
    sessionInfo1.setConnectionInfo(new LocalConnection("MyJdbcConn"));
    sessionInfo1.setName("sessionInfo1");
    rowSetInfo1.setQueryInfo(new QueryViewInfo(
    "CustomerView",
    rowSetInfo1.setSession(sessionInfo1);
    rowSetInfo1.setName("rowSetInfo1");
    /* The following listener was added using the event tab in the property inspector in design
    mode. The rowsetPopulated method is called when the rowset is queried/requeried.
    rowSetInfo1.addChangeListener(new oracle.dacf.dataset.ChangeAdapter() {
    public void rowsetPopulated(RowSetChangeEvent e) {
    rowSetInfo1_rowsetPopulated(e);
    textFieldControl1.setText("textFieldControl1");
    textFieldControl2.setDataItemName("infobus:/oracle/sessionInfo1/rowSetInfo1/Firstname");
    textFieldControl2.setText("textFieldControl2");
    textFieldControl3.setDataItemName("infobus:/oracle/sessionInfo1/rowSetInfo1/Lastname");
    textFieldControl3.setText("textFieldControl3");
    textFieldControl4.setDataItemName("infobus:/oracle/sessionInfo1/rowSetInfo1/Username");
    textFieldControl4.setText("textFieldControl4");
    textFieldControl5.setDataItemName("infobus:/oracle/sessionInfo1/rowSetInfo1/Password");
    textFieldControl5.setText("textFieldControl5");
    textFieldControl6.setDataItemName("infobus:/oracle/sessionInfo1/rowSetInfo1/Status");
    textFieldControl6.setText("textFieldControl6");
    textFieldControl7.setDataItemName("infobus:/oracle/sessionInfo1/rowSetInfo1/Email");
    textFieldControl7.setText("textFieldControl7");
    navigationBar1.setDataItemName("infobus:/oracle/sessionInfo1/rowSetInfo1");
    jLabel1.setText("ID:");
    jLabel2.setText("First Name:");
    jLabel3.setText("Last Name:");
    jLabel4.setText("User Name:");
    jLabel5.setText("Password:");
    jLabel6.setText("Status:");
    jLabel7.setText("Email:");
    jLabel8.setText("Address:");
    jPanel4.setLayout(      gridBagLayout2);
    textFieldStreet.setColumns(20);
    textFieldStreet.setText("textFieldStreet");
    /* The following listener (as well as the listeners on textFieldCity, textFieldState, and
    textFieldZipcode were added by the designer, but the focusGained and focusLost methods
    were modified in each case to call a common textField_focusGained method
    textFieldStreet.addFocusListener(new java.awt.event.FocusAdapter() {
    public void focusGained(FocusEvent e) {
    textField_focusGained(e);
    public void focusLost(FocusEvent e) {
    textField_focusLost(e);
    textFieldCity.setColumns(20);
    textFieldCity.setText("textFieldCity");
    textFieldCity.addFocusListener(new java.awt.event.FocusAdapter() {
    public void focusGained(FocusEvent e) {
    textField_focusGained(e);
    public void focusLost(FocusEvent e) {
    textField_focusLost(e);
    textFieldState.setColumns(20);
    textFieldState.setText("textFieldState");
    textFieldState.addFocusListener(new java.awt.event.FocusAdapter() {
    public void focusGained(FocusEvent e) {
    textField_focusGained(e);
    public void focusLost(FocusEvent e) {
    textField_focusLost(e);
    textFieldZipcode.setColumns(20);
    textFieldZipcode.setText("textFieldZipcode");
    textFieldZipcode.addFocusListener(new java.awt.event.FocusAdapter() {
    public void focusGained(FocusEvent e) {
    textField_focusGained(e);
    public void focusLost(FocusEvent e) {
    textField_focusLost(e);
    jLabel9.setText("Street:");
    jLabel10.setText("City:");
    jLabel11.setText("State:");
    jLabel12.setText("Zip Code:");
    textFieldControl1.setDataItemName("infobus:/oracle/sessionInfo1/rowSetInfo1/Id");
    this.getContentPane().add(jPanel1, BorderLayout.CENTER);
    jPanel1.add(jPanel2, BorderLayout.NORTH);
    jPanel2.add(navigationBar1, null);
    jPanel1.add(jPanel3, BorderLayout.CENTER);
    jPanel3.add(textFieldControl1, new GridBagConstraints2(1, 0, 1, 1, 1.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(37, 11, 0, 0), 0, 0));
    jPanel3.add(textFieldControl2, new GridBagConstraints2(1, 1, 1, 1, 1.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(7, 11, 0, 0), 0, 0));
    jPanel3.add(textFieldControl3, new GridBagConstraints2(1, 2, 1, 1, 1.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(7, 11, 0, 0), 0, 0));
    jPanel3.add(textFieldControl4, new GridBagConstraints2(1, 3, 1, 1, 1.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(6, 11, 0, 0), 0, 0));
    jPanel3.add(textFieldControl5, new GridBagConstraints2(1, 4, 1, 1, 1.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(6, 11, 0, 0), 0, 0));
    jPanel3.add(textFieldControl6, new GridBagConstraints2(1, 5, 1, 1, 1.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(7, 11, 0, 0), 0, 0));
    jPanel3.add(textFieldControl7, new GridBagConstraints2(1, 6, 1, 1, 1.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(6, 11, 0, 0), 0, 0));
    jPanel3.add(jLabel1, new GridBagConstraints2(0, 0, 1, 1, 0.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(37, 106, 0, 0), 0, 0));
    jPanel3.add(jLabel2, new GridBagConstraints2(0, 1, 1, 1, 0.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(8, 54, 0, 0), 0, 0));
    jPanel3.add(jLabel3, new GridBagConstraints2(0, 2, 1, 1, 0.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(8, 54, 0, 0), 0, 0));
    jPanel3.add(jLabel4, new GridBagConstraints2(0, 3, 1, 1, 0.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(10, 54, 0, 0), 0, 0));
    jPanel3.add(jLabel5, new GridBagConstraints2(0, 4, 1, 1, 0.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(8, 62, 0, 0), 0, 0));
    jPanel3.add(jLabel6, new GridBagConstraints2(0, 5, 1, 1, 0.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(9, 83, 0, 0), 0, 0));
    jPanel3.add(jLabel7, new GridBagConstraints2(0, 6, 1, 1, 0.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(9, 86, 0, 0), 0, 0));
    jPanel3.add(jLabel8, new GridBagConstraints2(0, 7, 1, 1, 0.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(7, 72, 94, 0), 0, 0));
    jPanel3.add(jPanel4, new GridBagConstraints2(1, 7, 1, 1, 0.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(0, 0, 0, 0), 0, 0));
    jPanel4.add(textFieldZipcode, new GridBagConstraints2(1, 3, 1, 1, 0.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(0, 10, 0, 0), 0, 0));
    jPanel4.add(textFieldState, new GridBagConstraints2(1, 2, 1, 1, 0.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(0, 10, 0, 0), 0, 0));
    jPanel4.add(jLabel9, new GridBagConstraints2(0, 0, 1, 1, 0.0, 0.0,
    GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 0, 0, 0), 0, 0));
    jPanel4.add(textFieldStreet, new GridBagConstraints2(1, 0, 1, 1, 0.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(0, 10, 0, 0), 0, 0));
    jPanel4.add(jLabel10, new GridBagConstraints2(0, 1, 1, 1, 0.0, 0.0,
    GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 0, 0, 0), 0, 0));
    jPanel4.add(jLabel11, new GridBagConstraints2(0, 2, 1, 1, 0.0, 0.0,
    GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 0, 0, 0), 0, 0));
    jPanel4.add(jLabel12, new GridBagConstraints2(0, 3, 1, 1, 0.0, 0.0,
    GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 0, 0, 0), 0, 0));
    jPanel4.add(textFieldCity, new GridBagConstraints2(1, 1, 1, 1, 0.0, 0.0,
    GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(0, 10, 0, 0), 0, 0));
    /* The following vaiable declarations were made by the designer
    BorderLayout borderLayout1 = new BorderLayout();
    JPanel jPanel1 = new JPanel();
    SessionInfo sessionInfo1 = new SessionInfo();
    RowSetInfo rowSetInfo1 = new RowSetInfo();
    AttributeInfo IdrowSetInfo1 = new AttributeInfo(java.sql.Types.NUMERIC);
    AttributeInfo FirstnamerowSetInfo1 = new AttributeInfo(java.sql.Types.VARCHAR);
    AttributeInfo LastnamerowSetInfo1 = new AttributeInfo(java.sql.Types.VARCHAR);
    AttributeInfo UsernamerowSetInfo1 = new AttributeInfo(java.sql.Types.VARCHAR);
    AttributeInfo PasswordrowSetInfo1 = new AttributeInfo(java.sql.Types.VARCHAR);
    AttributeInfo AddressrowSetInfo1 = new AttributeInfo();
    AttributeInfo StatusrowSetInfo1 = new AttributeInfo(java.sql.Types.VARCHAR);
    AttributeInfo EmailrowSetInfo1 = new AttributeInfo(java.sql.Types.VARCHAR);
    JPanel jPanel2 = new JPanel();
    JPanel jPanel3 = new JPanel();
    TextFieldControl textFieldControl1 = new TextFieldControl();
    TextFieldControl textFieldControl2 = new TextFieldControl();
    TextFieldControl textFieldControl3 = new TextFieldControl();
    TextFieldControl textFieldControl4 = new TextFieldControl();
    TextFieldControl textFieldControl5 = new TextFieldControl();
    TextFieldControl textFieldControl6 = new TextFieldControl();
    TextFieldControl textFieldControl7 = new TextFieldControl();
    BorderLayout borderLayout2 = new BorderLayout();
    NavigationBar navigationBar1 = new NavigationBar();
    JLabel jLabel1 = new JLabel();
    JLabel jLabel2 = new JLabel();
    JLabel jLabel3 = new JLabel();
    JLabel jLabel4 = new JLabel();
    JLabel jLabel5 = new JLabel();
    JLabel jLabel6 = new JLabel();
    JLabel jLabel7 = new JLabel();
    JLabel jLabel8 = new JLabel();
    GridBagLayout gridBagLayout1 = new GridBagLayout();
    JPanel jPanel4 = new JPanel();
    JTextField textFieldStreet = new JTextField();
    JTextField textFieldCity = new JTextField();
    JTextField textFieldState = new JTextField();
    JTextField textFieldZipcode = new JTextField();
    JLabel jLabel9 = new JLabel();
    JLabel jLabel10 = new JLabel();
    JLabel jLabel11 = new JLabel();
    JLabel jLabel12 = new JLabel();
    GridBagLayout gridBagLayout2 = new GridBagLayout();
    /* The following declarations were made manually
    /* DomainAccess provides a means for getting and setting values of a column object as domain
    DomainAccess da = null;
    /* TAddress is the domain class
    TAddress addr = null;
    /* Declare variables for determining if JTextField values have been changed by user
    String oldVal = null;
    String newVal = null;
    /* The following method is generated by the wizard when the frame was created
    protected void processWindowEvent(WindowEvent e) {
    super.processWindowEvent(e);
    if (e.getID() == WindowEvent.WINDOW_CLOSED) {
    System.exit(0);
    public void bfInit () throws Exception {
    /* To add code to be invoked when the user moves from one row to another, get the
    DataItemChangeManager from the RowSetInfo (via RowsetAccess) and add a
    DataItemChangeListener. The specific method we want to use here is rowsetCursorMoved
    which is invoked when the user moves from one row to another; the other methods are
    defined simply because the interface requires them.
    RowsetAccess ra = rowSetInfo1.getRowsetAccess();
    DataItemChangeManager dcm = (DataItemChangeManager)ra;
    dcm.addDataItemChangeListener(new DataItemChangeListener() {
    public void rowsetCursorMoved(RowsetCursorMovedEvent e) {
    rowSetInfo1_rowsetCursorMoved(e);
    public void dataItemAdded(DataItemAddedEvent e) {
    public void dataItemDeleted(DataItemDeletedEvent e) {
    public void dataItemRevoked(DataItemRevokedEvent e) {
    public void dataItemValueChanged(DataItemValueChangedEvent e) {
    /* This method was generated by the designer. See rowSetInfo1.addChangeListener(...) in jbInit
    above.
    void rowSetInfo1_rowsetPopulated(RowSetChangeEvent e) {
    try {
    /* When the rowset is populated, set the JTextField values based on the domain. See
    updateFields() below.
    updateFields();
    catch (Exception ex) {
    System.out.println("Error occurred while retrieving values");
    ex.printStackTrace();
    /* This method was added manually to track row navigation. See dcm.addDataItemChangeListener(...)
    in jbInit above.
    void rowSetInfo1_rowsetCursorMoved(RowsetCursorMovedEvent e) {
    try {
    /* When the user moves from one row to another, set the JTextField values based on the
    domain. See updateFields() below.
    updateFields();
    catch (Exception ex) {
    System.out.println("Error occured while assigning values");
    ex.printStackTrace();
    /* This method finds the values from each field of the column object by using the domain, then
    sets the values of the JTextFields respectively. It is invoked when the rowset is initially
    populated, and each time the user moves from one row to another.
    public void updateFields () throws Exception {
    /* Get DataItem for the Address column object and cast to DomainAccess for to prepare for
    getting and setting column value as domain.
    da = (DomainAccess)AddressrowSetInfo1.getImmediateAccess();
    /* Get the value of the attribute as a Domain and cast to DomainInterface.
    DomainInterface di = da.getValueAsDomain();
    /* null out addr. Otherwise, if the address column is null for a particular record, when
    the user navigates to the record with the null values, addr will retain the previous record's
    values. This ensures a clean slate.
    addr = null;
    /* Using DomainInterface allows us to cast the domain object to the specific Domain class for
    that type. So, cast the address attribute's value to TAddress, the class that
    represents the T_ADDRESS type created in the database. This provides getters and setters
    for each of the fields of the Object Type.
    if ( di instanceof TAddress ) {
    addr = (TAddress) di;
    /* If the above statement resulted in some non-null object assigned to addr, it is because
    one or more of the fields of the domain contained non-null values. Therefore, if addr is
    not null, get the values from each field of the domain and assign them to their
    respective JTextFields. Otherwise, set each JTextField to an empty string.
    if (addr != null) {
    textFieldStreet.setText(addr.getStreet());
    textFieldCity.setText(addr.getCity());
    textFieldState.setText(addr.getState());
    textFieldZipcode.setText(addr.getZipcode());
    else {
    textFieldStreet.setText("");
    textFieldCity.setText("");
    textFieldState.setText("");
    textFieldZipcode.setText("");
    /* If addr is null, after making sure the JTextFields are cleared, create a new TAddress
    object so that we have something to assign values to if the user edits the JTextFields.
    try {
    addr = new TAddress();
    catch (SQLException ex) {
    System.out.println("Error creating domain TAddress");
    ex.printStackTrace();
    /* The method below is invoked when the user navigates to textFieldStreet, textFieldCity,
    textFieldState, or textFieldZipcode. It's used just to find the value of the field when
    the user enters the field (the "before" value).
    void textField_focusGained(FocusEvent e) {
    Object obj = e.getSource();
    if (obj instanceof JTextField) {
    JTextField field = (JTextField)obj;
    oldVal = field.getText();
    /* The method below is invoked when the user navigates away from textFieldStreet, textFieldCity,
    textFieldState, or textFieldZipcode. It checks to see if the user changes the value of the
    field, and if so, updates the value of the address attribute.
    void textField_focusLost(FocusEvent e) {
    /* Find out the value of the JTextField now that the user is attempting to leave the field.
    Object obj = e.getSource();
    if (obj instanceof JTextField) {
    JTextField field = (JTextField)obj;
    newVal = field.getText();
    /* Compare the new value of the field ("after" value) to the "before" value captured
    in textField_focusGained above. If they are equal, we do nothing. If they are not equal,
    then the user must have changes the value in the field, and we have some work to do.
    if (!oldVal.equals(newVal)) {
    /* Since this same method is called regardless of which JTextField has been left, we find
    out which text field the user is leaving, and then set the value of the appropriate
    element of the addr domain.
    if (obj.equals(textFieldStreet)) {
    addr.setStreet(newVal);
    if (obj.equals(textFieldCity)) {
    addr.setCity(newVal);
    if (obj.equals(textFieldState)) {
    addr.setState(newVal);
    if (obj.equals(textFieldZipcode)) {
    addr.setZipcode(newVal);
    /* So, we've set the value of the appropriate element of the addr domain, but we have not
    "posted" those changes to the BC4J (middle-tier), so if we were to commit at this point
    our changes would not get saved to the database (because BC4J is not aware of these
    changes). The next step is to notify BC4J of the changes.
    try {
    da.setValueAsDomain(addr);
    catch (InvalidDataException ex) {
    System.out.println("Invalid Data assigned to TAddress");
    ex.printStackTrace();
    /* Clear out the oldVal and newVal variable so we are ready to track more changes.
    oldVal = null;
    newVal = null;
    }-- Brian

  • BC4J,Setting a default Value In a View With Data From An Other View

    hi
    I'm developping A BC4J. I want to set the default value of a field By counting the number of rows in an other view.
    So I want to instanciate the view and execute the sql statement and get the result.
    Is that the right manner to do it or not.
    can someone help me to do that
    cheers
    ghassen

    There's lots of ways to skin this cat depending upon whether you mean "database view" or "view object" when you say "view", and individual requirements.
    Given database views v1 and v2 with a common key between them
    select v1.x, count(*) from v1,v2 where v1.key = v2.key group by v1.x;
    either in the database view or in expert mode for the view object ( I think it'll take group by, but never done it ). ( assumption is that v1.x is a primary key for v1 )...
    Try this from sql*Plus first to get a feel for how this works.
    The catch with the above is that it is "static"... if you can ADD rows to v2 in your application... they aren't visible in the count until saved and requeried.
    Another way ( I think... hopefully Oracle folk will kibitz... )
    Create your own attribute on the view object like "TheOtherCount".
    In the view object's RowImpl, find the "getTheOtherCount". Find the count of rows in the second view object or entity object or rowSetInfo through the method of your choice. ( If you've already set up a master detail relationship that is active you can just get the rowcount! ). Refer to earlier postings on how to get the rowcount, or to create a dynamic view query to get the count.
    The nice thing is that this should reflect your counts even if the second view has added or removed rows... but will probably move like a snail.
    Note that if you have a need where you want the row count updated in a frame for v1 whenever v2 is added to or removed from... well... then you need to set up some sort of event listener to do a redisplay of v1's frame, I'd think? Since the attribute you've created in the view object is not based on an entity object attribute, it has no way to know when it has been "updated" via an additional or removed row from the target.
    I'm posting the above because no one has responded yet... it may form a place to start from. And maybe someone in the know will go "No, No, No... KKirk... it doesn't work that way at all!" and fill us in on how this can be accomplished!
    Good Luck

  • HOWTO: Using a BC4J Application Module in an Stateless EJB Session Bean

    HOWTO: Using a BC4J Application Module in an Stateless EJB Session Bean
    by Steve Muench
    Overview
    BC4J provides automatic facilities for deploying any application module as a stateful EJB session bean. If you want to leverage the features of your BC4J application module from a stateless EJB session bean, it's not automatic but it is straightforward to implement. This howto article explains the details.
    For our example, we will create a stateless EJB session bean that uses a container-managed transaction. To keep things simple, let's assume the session bean has a single public method on its remote interface named createDepartment() with the following signature:
    public void createDepartment(int id, String name, String loc) throws AppException
    AppException is an example of an application-specific exception that our method will throw if any problems arise during its execution.The goal of this article is to illustrate how to use the BC4J application module named com.example.hr.HRApp as part of the implementation of this createDepartment method on our stateless enterprise bean. Let's assume that the HRApp application module has a view object member named Departments, based on the com.example.hr.DeptView view object, based on the familiar DEPT table and related to the com.example.hr.Dept entity object so our view can be updateable.
    Creating the Stateless Session Bean
    We can start by using the JDeveloper Enterprise Bean wizard to create a new stateless session bean called StatelessSampleEJB implemented by:[list][*]com.example.StatelessSampleEJBBean (Bean class)[*]com.example.StatelessSampleEJBHome (Home interface)[*]com.example.StatelessSampleEJB (Remote interface)[list]
    We then use the EJB Class Editor to add the createDepartment method to the remote interface of StatelessSampleEJB with the signature above. We edit the remote interface to make sure that it also reflects that the createDepartment method thows the AppException like this:
    package com.example;
    import javax.ejb.EJBObject;
    import java.rmi.RemoteException;
    public interface StatelessSampleEJB extends EJBObject {
      void createDepartment(int id, String name, String loc)
      throws RemoteException,AppException;
    }Before we start adding BC4J into the picture for our implementation, our StatelessSampleEJBBean class looks like this:
    package com.example;
    import javax.ejb.SessionBean;
    import javax.ejb.SessionContext;
    public class StatelessSampleEJBBean implements SessionBean {
      public void ejbCreate(){}
      public void ejbActivate(){}
      public void ejbPassivate(){}
      public void ejbRemove(){}
      public void setSessionContext(SessionContext ctx){
      public void createDepartment(int id, String name, String loc) 
      throws AppException {
        // TODO: Implement method here
    }We can double-click on the ejb-jar.xml file in our project to see the XML deployment descriptor for the bean we just created:
    <ejb-jar>
       <enterprise-beans>
          <session>
             <description>Session Bean ( Stateless )</description>
             <display-name>StatelessSampleEJB</display-name>
             <ejb-name>StatelessSampleEJB</ejb-name>
             <home>com.example.StatelessSampleEJBHome</home>
             <remote>com.example.StatelessSampleEJB</remote>
             <ejb-class>com.example.StatelessSampleEJBBean</ejb-class>
             <session-type>Stateless</session-type>
             <transaction-type>Container</transaction-type>
          </session>
       </enterprise-beans>
    </ejb-jar>We need to add the extra <assembly-descriptor> section in this file to indicate that the createDepartment method will require a transaction. After this edit, the ejb-jar.xml file looks like this:
    <ejb-jar>
       <enterprise-beans>
          <session>
             <description>Session Bean ( Stateless )</description>
             <display-name>StatelessSampleEJB</display-name>
             <ejb-name>StatelessSampleEJB</ejb-name>
             <home>com.example.StatelessSampleEJBHome</home>
             <remote>com.example.StatelessSampleEJB</remote>
             <ejb-class>com.example.StatelessSampleEJBBean</ejb-class>
             <session-type>Stateless</session-type>
             <transaction-type>Container</transaction-type>
          </session>
       </enterprise-beans>
       <assembly-descriptor>
          <container-transaction>
             <method>
                <ejb-name>StatelessSampleEJB</ejb-name>
                <method-name>createDepartment</method-name>
                <method-params>
                   <method-param>int</method-param>
                   <method-param>java.lang.String</method-param>
                   <method-param>java.lang.String</method-param>
                </method-params>
             </method>
             <trans-attribute>Required</trans-attribute>
          </container-transaction>
       </assembly-descriptor>
    </ejb-jar>
    Aggregating a BC4J Application Module
    With the EJB aspects of our bean setup, we can proceed to implementing the BC4J application module aggregation.
    The first thing we do is add private variables to hold the EJB SessionContext and the instance of the aggregated BC4J ApplicationModule, like this:
    // Place to hold onto the aggregated appmodule instance
    transient private ApplicationModule _am  = null;
    // Remember the SessionContext that the EJB container provides us
    private           SessionContext    _ctx = null;and we modify the default, empty implementation of the setSessionContext() method to remember the session context like this:
    public void setSessionContext(SessionContext ctx){ _ctx = ctx; }We add additional constants that hold the names of the J2EE datasource that we want BC4J to use, as well as the fully-qualified name of the BC4J application module that we'll be aggregating:
    // JNDI resource name for the J2EE datasource to use
    private static final String DATASOURCE = "jdbc/OracleCoreDS";
    // Fully-qualified BC4J application module name to aggregate
    private static final String APPMODNAME = "com.example.hr.HRApp";We expand the now-empty ejbCreate() and ejbRemove() methods to create and destory the aggregated instance of the BC4J application module that we'll use for the lifetime of the stateless session bean. When we're done, ejbCreate() it looks like this:
    public void ejbCreate() throws CreateException {
      try {
        // Setup a hashtable of environment parameters for JNDI initial context
        Hashtable env = new Hashtable();
        env.put(JboContext.INITIAL_CONTEXT_FACTORY,JboContext.JBO_CONTEXT_FACTORY);
        // NOTE: we want to use the BC4J app module in local mode as a simple Java class!
        env.put(JboContext.DEPLOY_PLATFORM, JboContext.PLATFORM_LOCAL);
        env.put(PropertyConstants.INTERNAL_CONNECTION_PARAMS,DATASOURCE);
        // Create an initial context, using this hashtable of environment params
        InitialContext ic = new InitialContext(env);
        // Lookup a home interface for the application module
        ApplicationModuleHome home = (ApplicationModuleHome)ic.lookup(APPMODNAME);
        // Using the home, create the instance of the appmodule we'll use
        _am = home.create();
        // Register the BC4J factory to handle EJB container-managed transactions
        registerContainerManagedTransactionHandlerFactory();
      catch(Exception ex) {
         ex.printStackTrace();
        throw new CreateException(ex.getMessage());
    }and ejbRemove() looks like this:
    public void ejbRemove() {
      try {
        // Cleanup any appmodule resources before getting shutdown
        _am.remove();
      catch(JboException ex) { /* Ignore */ }
    }The helper method named reigsterContainerManagedTransactionHandlerFactory() looks like this:
    private void registerContainerManagedTransactionHandlerFactory() {
      SessionImpl session = (SessionImpl)_am.getSession();
      session.setTransactionHandlerFactory(
        new TransactionHandlerFactory() {
          public TransactionHandler  createTransactionHandler() {
            return new ContainerManagedTxnHandlerImpl();
          public JTATransactionHandler createJTATransactionHandler() {
            return new ContainerManagedTxnHandlerImpl();
    }The last detail is to use the BC4J appmodule to implement the createDepartment() method. It ends up looking like this:
    public void createDepartment(int id, String name, String loc)
    throws AppException {
      try {
        // Connect the AM to the datasource we want to use for the duration
        // of this single method call.
        _am.getTransaction().connectToDataSource(null,DATASOURCE,false);
        // Use the "Departments" view object member of this AM
        ViewObject departments = _am.findViewObject("Departments");
        // Create a new row in this view object.
        Row newDept = departments.createRow();
        // Populate the attributes from the parameter arguments.
        newDept.setAttribute("Deptno", new Number(id));
        newDept.setAttribute("Dname", name);
        newDept.setAttribute("Loc", loc);
        // Add the new row to the view object's default rowset
        departments.insertRow(newDept);
        // Post all changes in the AM, but we don't commit them. The EJB
        // container managed transaction handles the commit.
        _am.getTransaction().postChanges();
      catch(JboException ex) {
        // To be good EJB Container-Managed Transaction "citizens" we have
        // to mark the transaction as needing a rollback if there are problems
        _ctx.setRollbackOnly();
        throw new AppException("Error creating dept "+ id +"\n"+ex.getMessage());
      finally {
        try {
          // Disconnect the AM from the datasource we're using
          _am.getTransaction().disconnect();
        catch(Exception ex) { /* Ignore */ }
    Building a Test Client
    With the EJB-Tier work done, we can build a sample client program to test this new stateless EJB Session Bean by selecting the bean in the Oracle9i JDeveloper IDE and choosing "Create Sample Java Client" from the right-mouse menu.
    When the "Sample EJB Client Details" dialog appears, we take the defaults of connecting to embedded OC4J container. Clicking the (OK) button generates the following test class:
    import java.util.Hashtable;
    import javax.naming.Context;
    import javax.naming.InitialContext;
    import com.example.StatelessSampleEJB;
    import com.example.StatelessSampleEJBHome;
    public class SampleStatelessSampleEJBClient {
      public static void main(String [] args) {
        SampleStatelessSampleEJBClient sampleStatelessSampleEJBClient =
           new SampleStatelessSampleEJBClient();
        try {
          Hashtable env = new Hashtable();
          env.put(Context.INITIAL_CONTEXT_FACTORY,
                  "com.evermind.server.rmi.RMIInitialContextFactory");
          env.put(Context.SECURITY_PRINCIPAL, "admin");
          env.put(Context.SECURITY_CREDENTIALS, "welcome");
          env.put(Context.PROVIDER_URL,
                  "ormi://localhost:23891/current-workspace-app");
          Context ctx = new InitialContext(env);
          StatelessSampleEJBHome statelessSampleEJBHome =
               (StatelessSampleEJBHome)ctx.lookup("StatelessSampleEJB");
          StatelessSampleEJB statelessSampleEJB;
          // Use one of the create() methods below to create a new instance
          // statelessSampleEJB = statelessSampleEJBHome.create();
          // Call any of the Remote methods below to access the EJB
          // statelessSampleEJB.createDepartment( int id, java.lang.String name, java.lang.String loc );
        catch(Throwable ex) {
          ex.printStackTrace();
    }We uncomment the call to the create() method and add a few calls to the createDepartment() method so that the body of the test program now looks like this:
    // Use one of the create() methods below to create a new instance
    statelessSampleEJB = statelessSampleEJBHome.create();
    // Call any of the Remote methods below to access the EJB
    statelessSampleEJB.createDepartment( 13, "Test1","Loc1");
    System.out.println("Created department 13");
    statelessSampleEJB.createDepartment( 14, "Test2","Loc2");
    System.out.println("Created department 14");
    try {
      // Try setting a department id that is too large!
      statelessSampleEJB.createDepartment( 23456, "Test3","Loc3");
    catch (AppException ax) {
      System.err.println("AppException: "+ax.getMessage());
    }Before we can successfully run our SampleStatelessSampleEJBClient we need to first run the EJB bean that the client will try to connect to. Since Oracle9i JDeveloper supports local running and debugging of the EJB-Tier without doing through a full J2EE deployment step, to accomplish this prerequisite step we just need to right-mouse on the StatelessSampleEJB node in the System Navigator and select "Run". This starts up the embedded OC4J instance and runs the EJB right out of the current out path.Finally, we can run the SampleStatelessSampleEJBClient, and see the output of the test program in the JDeveloper log window:
    Created department 13
    Created department 14
    AppException: Error creating dept 23456
    JBO-27010: Attribute set with value 23456 for Deptno in Dept has invalid precision/scale
    Troubleshooting
    One error that might arise while running the example is that the database connection information in your data-sources.xml for the jdbc/OracleCoreDS datasource does not correspond to the database you are trying to test against. If this happens, then double-check the file .\jdev\system\oc4j-config\data-sources.xml under the JDeveloper installation home directory to make sure that the url value provided is what you expect. For example, to work against a local Oracle database running on your current machine, listening on port 1521, with SID of ORCL, you would edit this file to have an entry like this for jdbc/OracleCoreDS :
    <data-source
        class="com.evermind.sql.DriverManagerDataSource"
        name="OracleDS"
        location="jdbc/OracleCoreDS"
        xa-location="jdbc/xa/OracleXADS"
        ejb-location="jdbc/OracleDS"
        connection-driver="oracle.jdbc.driver.OracleDriver"
        username="scott"
        password="tiger"
        url="jdbc:oracle:thin:@localhost:1521:ORCL"
        inactivity-timeout="30"
    />This is the data-sources.xml file that gets used by the embedded OC4J instance running in JDeveloper.
    Conclusion
    Hopefully this article has illustrated that it is straightforward to utilize the full power of BC4J in local mode as part of your EJB Stateless Session Beans using container-managed transaction. This example illustrated a single createDepartment method in the enterprise bean, but by replicating the application module interaction code that we've illustrated in createDepartment, any number of methods in your stateless session bean can use the aggregated application module instance created in the ejbCreate() method.
    Code Listing
    The full code listing for the SampleStatelessEJB bean implementation class looks like this:
    * StatelessSampleEJB
    * Illustrates how to use an aggregated BC4J application module
    * in local mode as part of the implementation of a stateless
    * EJB session bean using container-managed transaction.
    * HISTORY
    * smuench/dmutreja 14-FEB-2002 Created
    package com.example;
    import oracle.jbo.*;
    import oracle.jbo.server.*;
    import javax.ejb.*;
    import oracle.jbo.domain.Number;
    import oracle.jbo.common.PropertyConstants;
    import java.util.Hashtable;
    import javax.naming.InitialContext;
    import oracle.jbo.server.ejb.ContainerManagedTxnHandlerImpl;
    public class StatelessSampleEJBBean implements SessionBean {
      // JNDI resource name for the J2EE datasource to use
      private static final String DATASOURCE = "jdbc/OracleCoreDS";
      // Fully-qualified BC4J application module name to aggregate
      private static final String APPMODNAME = "com.example.hr.HRApp";
      // Place to hold onto the aggregated appmodule instance
      transient private ApplicationModule _am  = null;
      // Remember the SessionContext that the EJB container provides us
      private           SessionContext    _ctx = null;
      public void ejbCreate() throws CreateException {
        try {
          // Setup a hashtable of environment parameters for JNDI initial context
          Hashtable env = new Hashtable();
          env.put(JboContext.INITIAL_CONTEXT_FACTORY,JboContext.JBO_CONTEXT_FACTORY);
          env.put(JboContext.DEPLOY_PLATFORM, JboContext.PLATFORM_LOCAL);
          env.put(PropertyConstants.INTERNAL_CONNECTION_PARAMS,DATASOURCE);
          // Create an initial context, using this hashtable of environment params
          InitialContext ic = new InitialContext(env);
          // Lookup a home interface for the application module
          ApplicationModuleHome home = (ApplicationModuleHome)ic.lookup(APPMODNAME);
          // Using the home, create the instance of the appmodule we'll use
          _am = home.create();
          // Register the BC4J factory to handle EJB container-managed transactions
          registerContainerManagedTransactionHandlerFactory();
        catch(Exception ex) {
           ex.printStackTrace();
          throw new CreateException(ex.getMessage());
      public void ejbActivate(){}
      public void ejbPassivate(){}
      public void ejbRemove(){}
      public void setSessionContext(SessionContext ctx){ _ctx = ctx; }
      public void createDepartment(int id, String name, String loc)
      throws AppException {
        try {
          // Connect the AM to the datasource we want to use for the duration
          // of this single method call.
          _am.getTransaction().connectToDataSource(null,DATASOURCE,false);
          // Use the "Departments" view object member of this AM
          ViewObject departments = _am.findViewObject("Departments");
          // Create a new row in this view object.
          Row newDept = departments.createRow();
          // Populate the attributes from the parameter arguments.
          newDept.setAttribute("Deptno", new Number(id));
          newDept.setAttribute("Dname", name);
          newDept.setAttribute("Loc", loc);
          // Add the new row to the view object's default rowset
          departments.insertRow(newDept);
          // Post all changes in the AM, but we don't commit them. The EJB
          // container managed transaction handles the commit.
          _am.getTransaction().postChanges();
        catch(JboException ex) {
          // To be good EJB Container-Managed Transaction "citizens" we have
          // to mark the transaction as needing a rollback if there are problems
          _ctx.setRollbackOnly();
          throw new AppException("Error creating dept "+ id +\n"+ex.getMessage());
        finally {
          try {
            // Disconnect the AM from the datasource we're using
            _am.getTransaction().disconnect();
          catch(Exception ex) { /* Ignore */ }
      private void registerContainerManagedTransactionHandlerFactory() {
        SessionImpl session = (SessionImpl)_am.getSession();
        session.setTransactionHandlerFactory(
          new TransactionHandlerFactory() {
            public TransactionHandler createTransactionHandler() {
              return new ContainerManagedTxnHandlerImpl();
            public JTATransactionHandler createJTATransactionHandler() {
              return new ContainerManagedTxnHandlerImpl();

    Hi Steve, It4s me again;
    About the question I made, I tried with a single assembly-descriptor tag and a single container-transaction tag in the deployment descriptor of the session bean and these were the results.
    java.lang.NullPointerException
         void com.evermind.server.rmi.RMIConnection.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(java.lang.Throwable)
         java.lang.Object com.evermind.server.rmi.RMIConnection.invokeMethod(com.evermind.server.rmi.RMIContext, long, long, java.lang.reflect.Method, java.lang.Object[])
         java.lang.Object com.evermind.server.rmi.RemoteInvocationHandler.invoke(java.lang.Object, java.lang.reflect.Method, java.lang.Object[])
         java.lang.Object com.evermind.server.rmi.RecoverableRemoteInvocationHandler.invoke(java.lang.Object, java.lang.reflect.Method, java.lang.Object[])
         java.lang.Object com.evermind.server.ejb.StatelessSessionRemoteInvocationHandler.invoke(java.lang.Object, java.lang.reflect.Method, java.lang.Object[])
         void __Proxy1.modificaEnvoltura(java.lang.Integer, java.lang.Integer, java.lang.Integer, java.lang.Integer, java.lang.Integer, java.lang.Integer, java.lang.String)
         void SamplemdeController.envolturaControlEJBClient.main(java.lang.String[])
    Then I tried with multiple assembly-descriptor tags each with a single container-transaction tag and the results were:
    java.lang.NullPointerException
         void com.evermind.server.rmi.RMIConnection.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(java.lang.Throwable)
         java.lang.Object com.evermind.server.rmi.RMIConnection.invokeMethod(com.evermind.server.rmi.RMIContext, long, long, java.lang.reflect.Method, java.lang.Object[])
         java.lang.Object com.evermind.server.rmi.RemoteInvocationHandler.invoke(java.lang.Object, java.lang.reflect.Method, java.lang.Object[])
         java.lang.Object com.evermind.server.rmi.RecoverableRemoteInvocationHandler.invoke(java.lang.Object, java.lang.reflect.Method, java.lang.Object[])
         java.lang.Object com.evermind.server.ejb.StatelessSessionRemoteInvocationHandler.invoke(java.lang.Object, java.lang.reflect.Method, java.lang.Object[])
         void __Proxy1.modificaEnvoltura(java.lang.Integer, java.lang.Integer, java.lang.Integer, java.lang.Integer, java.lang.Integer, java.lang.Integer, java.lang.String)
         void SamplemdeController.envolturaControlEJBClient.main(java.lang.String[])
    Finally I tried with a single assembly-descriptor and multiple container tags and the results were:
    java.lang.NullPointerException
         void com.evermind.server.rmi.RMIConnection.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(java.lang.Throwable)
         java.lang.Object com.evermind.server.rmi.RMIConnection.invokeMethod(com.evermind.server.rmi.RMIContext, long, long, java.lang.reflect.Method, java.lang.Object[])
         java.lang.Object com.evermind.server.rmi.RemoteInvocationHandler.invoke(java.lang.Object, java.lang.reflect.Method, java.lang.Object[])
         java.lang.Object com.evermind.server.rmi.RecoverableRemoteInvocationHandler.invoke(java.lang.Object, java.lang.reflect.Method, java.lang.Object[])
         java.lang.Object com.evermind.server.ejb.StatelessSessionRemoteInvocationHandler.invoke(java.lang.Object, java.lang.reflect.Method, java.lang.Object[])
         void __Proxy1.modificaEnvoltura(java.lang.Integer, java.lang.Integer, java.lang.Integer, java.lang.Integer, java.lang.Integer, java.lang.Integer, java.lang.String)
         void SamplemdeController.envolturaControlEJBClient.main(java.lang.String[])
    How can I make my Stateless Session bean work out?

Maybe you are looking for