Use naming datasource in WebStart application

Hello!
I created a simple WebStart application with ADF Swing components.(JDeveloper version is 11.1.1.3)
I deployed this application on Weblogic server (version is 10.3.3).
But my application works fine, when I use JDBC connection in configuration of my application module.
When I change type to JDBC DataSource, I get an error: (oracle.jbo.DMLException) JBO-27200: Failure JNDI. Can't execute search of datasource in context hrGlobal
Where, "hrGlobal" is name of DataSource which is situated on WLS. (This DataSource I created using WLS Console).
Maybe, there is any help or source code or documentation about this problem, but i could not find such information.
So, if anyone had met with this problem and can share solution with me, it would be great.
Thank you for time and answers.
Regards, Stanislav.

Hi. Thank you for link. But my problem that this naming DataSource works in ADF Faces application and gives an error in ADF Swing WebStart application. Names in this 2 applications(ADF Faces and ADF Swing) match and i don't use property jbo.server.internal_connection.

Similar Messages

  • Is it appropriate to use File.createTempFile() in webstart applications?

    Hello everyone.
    I'm currently involved in developing a web start application for my company; and I am a bit puzzled as to the way temporary storage should be managed in the client's machine. To begin with, the application is a web start "trusted" application, since we're signing it.
    Specifically, the application needs to perform XSLT transformations with user-generated data. This obviously needs some place to read a source XML document and a source XML stylesheet.
    Loading the latter from my application jars as a URL isn't much of a problem. However, my confusion is regarding the location where the XML document generated by the user should be temporarily stored, since only the output of the transform is relevant.
    So the first option I got is to use the muffin storage system provided by web start. The concern I have with this is that, while it does provide a place for applications to store data, the mechanics needed to maintain muffin data do not seem (this is just a personal opinion) friendly enough for storing temporary data (an XML file in my case).
    Now, I find that a better alternative for doing this would be to use File.createTempFile() in order to request a temporary storage location to dump the XML data to transform.
    Now, bearing this in mind; is it ok for this trusted application to use the facility provided by the File class? Or is there any better way I could do this?
    Thanks for your time and help!

    jzazueta wrote:
    Well, basically the intent is that the result of the transform will be used to derive a report from another application. Now, the nature of the transform's output file is about 3 to 4 MB when generated.
    I believe that is the primary purpose of saving transformed output.Fair enough but then why do you need to create the intermediate temporary file. Can't you just process the transformed data sequentially as it is produced.
    >
    In fact, while looking further into this subject, I found some code from the JDIC project mailing list where the example seems to indicate that some level of File functionality is allowed while running under Webstart.I use files under Webstart but I do sign the jars.
    >
    [http://markmail.org/message/vhjdnwqwjdyvwliv?q=createTempFile+webstart]
    So probably the idea may not be too crazy at all :PI never said it was crazy - I just queried the need for the intermediate file. You don't give any details of what you are doing with the transformed xml so I still question the need for the intermediate file.

  • Can a single datasource be used by more than one Application running on the

    Can a single datasource be used by more than one Application running on the system?

    What, in this context, do you mean by "datasource"?

  • Using 2 relational datasources in one application

    Hi
    I was wondering if it is possible to use two PersistenceManagerFactories in
    one application server pointing to two different RDBMSs, such as one Oracle
    and one DB2 database, but using the same JDO Classes. In this case I would
    need to have two separate mappings, and I guess you would have to specify
    somehow which mapping file to generate from the mappingtool and which one to
    use in each PersistenceManager, but I have not found how to do it.
    Could someone please point me in the right direction?
    Cheers
    Sven Erik

    Sven-
    This is certainly possible, but we do not provide any built-in way to
    automatically use different metadata files on a per-database basis,
    except when using the "db" MappingFactory (which stored the mappings in
    the database; in your case, each database will store its own version of
    the mappings).
    Another option is to make your own implementation of the fairly simple
    MappingFactory interface to perform some differentiation of the
    metadata. E.g., you might have it look for "mymetadata-oracle.xml" and
    "mymetadata-db2.xml" depending on the database, and then pass-through
    the calls to the default MetadataMappingFactory.
    In article <bugg5g$mnk$[email protected]>, Sven Erik Knop wrote:
    Hi
    I was wondering if it is possible to use two PersistenceManagerFactories in
    one application server pointing to two different RDBMSs, such as one Oracle
    and one DB2 database, but using the same JDO Classes. In this case I would
    need to have two separate mappings, and I guess you would have to specify
    somehow which mapping file to generate from the mappingtool and which one to
    use in each PersistenceManager, but I have not found how to do it.
    Could someone please point me in the right direction?
    Cheers
    Sven Erik--
    Marc Prud'hommeaux [email protected]
    SolarMetric Inc. http://www.solarmetric.com

  • How to use jndi datasource on Weblogic instead of adding a DB data source

    Hi All,
    version: 11.1.1.4
    I am trying to figure out how in my ADF applications I can use an existing jndi datasource out on our weblogic servers instead of having to bury the Database db source in my adf applications. Like SOA I would like to reference the DB directly during design so I can pull in entities and build view objects, but when I deploy I want it to reference the jndi datasource out on the weblogic server.
    Is this possible? If so I am not sure how to configure it like I would a DB adapter in SOA.
    As always appreciate the info.
    Thanks,
    S

    If you use ADF in the model layer (application modules) you can configure them to use JNDI Datasources. Just right click on the application module and select 'Configurations...'. In the next dialog you see all the configurations currently available (one named xxxxxlocal and one named xxxxxshared at least). Select the local and hit the edit button. This open the DB connect dialog where you can change the connection from JDBC URL to JDBC Datasource (JNDI). Save your work and when you now start the app it will use the JNDI name.
    Timo

  • Using data source in adf application.

    Hi ,
    JDev version : 11.1.1.6.0
    I am planning to use data source in the application  , but there is an issue facing while running with data source.
    Exception in thread "main" javax.naming.NoInitialContextException: Cannot instantiate class: weblogic.jndi.WLInitialContextFactory [Root exception is java.lang.ClassNotFoundException: weblogic.jndi.WLInitialContextFactory]
        at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:657)
        at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:288)
        at javax.naming.InitialContext.init(InitialContext.java:223)
        at javax.naming.InitialContext.<init>(InitialContext.java:197)
        at com.cisco.complianceutil.WizardDataSourceUtil.main(WizardDataSourceUtil.java:42)
    Caused by: java.lang.ClassNotFoundException: weblogic.jndi.WLInitialContextFactory
        at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
    So I used "Weblogic.jar" once and "wlfullclient.jar" . By using one of these jars issue fixed but because of it while loading the application it is throwing the below error .
    <Sep 10, 2013 2:42:05 PM IST> <Warning> <Deployer> <BEA-149078> <Stack trace for message 149004
    weblogic.application.ModuleException: [HTTP:101216]Servlet: "weblogic.wsee.jaxws.client.async.AsyncTransportProvider" failed to preload on startup in Web application: "ComplianceWizard".
    javax.xml.ws.WebServiceException: javax.xml.ws.WebServiceException: java.lang.InstantiationException: weblogic.wsee.jaxws.client.async.AsyncTransportProvider
        at weblogic.wsee.jaxws.WLSInstanceResolver.getSingleton(WLSInstanceResolver.java:36)
        at weblogic.wsee.jaxws.WLSInstanceResolver.start(WLSInstanceResolver.java:55)
        at weblogic.wsee.jaxws.WLSInstanceResolver$WLSInvoker.start(WLSInstanceResolver.java:82)
        at com.sun.xml.ws.server.InvokerTube.setEndpoint(InvokerTube.java:85)
        at weblogic.wsee.jaxws.EndpointAwareLateInitTube.postCreateEndpoint(EndpointAwareLateInitTube.java:48)
        at weblogic.wsee.jaxws.JAXWSServlet.registerEndpoint(JAXWSServlet.java:150)
        at weblogic.wsee.jaxws.JAXWSServlet.init(JAXWSServlet.java:64)
    For this I observed that solution is removing the wlfullcient.jar or weblogic.jar from the libraries. But If I do not use any one of them then data source does not work. Please guide me with your suggestions.

    This is configured in your database access layer - if it is using ADF BC then in the Application Module go to the configuration tab and edit the local configuration to see the information about which DB you are accessing.

  • Export and Import using Named Pipes

    Hai,
    I need an clarification in export, import and compress of dumps using named pipes.I am using Oracle 9i RAC 9.2.0.4 in AIX 5.3. Every month i have to move list of tables from one database to another database after taking export dumps. The list of activities done by me at present are given below.
    1. Taking export and gziping the dump file at the same time using named pipes.
    2. Doing uncompress and import in the second database using named pipes.
    We are doing compress for space constraints. Now my doubt is whether using named pipes, we can do both operation of import and compress of dump file at the same time. i.e, at the time of export itself , using named pipes, i need both import in the another database and compress the zip file. Is it possible?

    mknod exp.out p
    exp dbadmin/admindb file=exp.out owner=scott log=export.log statistics=none &
    imp dbadmin/admindb file=exp.out fromuser=scott touser=foobar log=import.log
    rm exp.out
    cat import.log
    Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    Export file created by EXPORT:V10.02.01 via conventional path
    import done in US7ASCII character set and UTF8 NCHAR character set
    import server uses AL32UTF8 character set (possible charset conversion)
    . importing SCOTT's objects into FOOBAR
    . . importing table                        "BONUS"          0 rows imported
    . . importing table                         "DEPT"          4 rows imported
    . . importing table                          "EMP"         14 rows imported
    . . importing table                     "SALGRADE"          5 rows imported
    About to enable constraints...
    Import terminated successfully without warnings.Edited by: sb92075 on Jan 1, 2010 1:42 PM

  • NOT Using Named Parameters in a Native Query

    Hi!
    like it is written in the Toplink JPA Extensions reference Toplink supports using named parameters in native queries.
    See example from http://www.oracle.com/technology/products/ias/toplink/jpa/resources/toplink-jpa-extensions.html:
    Example 1-11 Specifying a Named Parameter With #
    Query queryEmployees = entityManager.createNativeQuery(
    "SELECT OBJECT(emp) FROM Employee emp WHERE emp.firstName = #firstname"
    queryEmployeeByFirstName.setParameter("firstName", "Joan");
    Collection employees = queryEmployees.getResultList();
    But I want to use "#" in the SQL statement so I want to disable this parameter binding somehow and let the query just execute the SELECT statement I deliver.
    I have tried to add the property
    <property name="toplink.jdbc.bind-parameters" value="false"/>
    into the persistence.xml and I have also tried to add the query hint
    query.setHint(TopLinkQueryHints.BIND_PARAMETERS, HintValues.FALSE);
    but none of them prevents the # to be uses as a paramter. this causes the exception:
    Exception [TOPLINK-6132] (Oracle TopLink Essentials - 9.1 (Build b22)): oracle.toplink.essentials.exceptions.QueryException
    Exception Description: Query argument ######' not found in list of parameters provided during query execution.
    Query: ReadAllQuery(de.merck.compas.material.SimilarLocalMaterialListItemBV)
    The SQL Statement is
    SELECT * FROM TABLE (
    CAST ( RCGC.PHA_P_COMPASMDM.LookupSimilarMats
    ( 'COC003','10021500150000000997','30','30','040','standard','','001001','001001','123456','##########','X','X','X','X','U' )
    AS RCGC.PHA_COMPAS_SIMILAR_MATS ) )
    I am using the latest Toplink essentials build together with an Oracle 9.2i DB in a Java SE web application.
    Can anyone give me a little hint what to do?
    Thanks and best regards,
    Alex

    I hope this is what you need:
    [TopLink Fine]: 2007.01.19 02:56:48.278--ServerSession(17712783)--Connection(723185)--Thread(Thread[http-8080-Processor2
    3,5,main])--SELECT APPL_CGP_MATLOC, CHANGE_REQ_MATLOC, CD_PHA_MAT_LOC, LCOMP, LOC_MAT_NAME, APPL_GDM_MATLOC, LOC_MAT_NAM
    E_SHORT, APPL_PDW_MATLOC, PHA_MAT_LOC_LCOMMENT, APPL_TP_MATLOC, DIVISION, APPL_WRS_MATLOC, ARTICLE_ID_MDA, LU_PHA_MAT_LO
    C, LOC_MAT_NAME_OLD, LDT_PHA_MAT_LOC, PHA_MAT_LOC_STATUS, CU_PHA_MAT_LOC, MAT_LOC_ID, RCOMP, MAT_ID FROM RCGC.PHA_V_COMP
    AS_MAT_MATLOC WHERE ((MAT_LOC_ID = '123456') AND (RCOMP = '001001'))
    [TopLink Fine]: 2007.01.19 02:56:48.398--ServerSession(17712783)--Connection(32404901)--Thread(Thread[http-8080-Processo
    r23,5,main])--SELECT MAT_ID, DESCRIPTION, PHA_MATERIAL_LCOMMENT, PACKSIZE, LU_PHA_MATERIAL, PACKSIZE_UNIT, LDT_PHA_MATER
    IAL, CONTAINER_NAME, CU_PHA_MATERIAL, PURPOSE, CD_PHA_MATERIAL, CONTENT, CONTAINER_ID, AI_FACTOR, PHA_MATERIAL_STATUS, C
    MG_SPEC_APP, PROD_LEVEL, PACKAGE_SIZE, PRODUCT_ID FROM RCGC.PHA_V_COMPAS_MATERIAL WHERE (MAT_ID = '10021500150000000997'
    [TopLink Fine]: 2007.01.19 02:56:48.468--ServerSession(17712783)--Connection(723185)--Thread(Thread[http-8080-Processor2
    3,5,main])--SELECT PRODUCT_ID, PROD_GRP_ID, APPL_FORM_NAME, PRODUCT_NAME, GALENIC_FORM_NAME, APPL_FORM_ID, PHA_PRODUCT_S
    TATUS, PHA_PRODUCT_LCOMMENT, GALENIC_FORM_ID, LU_PHA_PRODUCT, INN, LDT_PHA_PRODUCT FROM RCGC.PHA_V_COMPAS_PRODUCT WHERE
    (PRODUCT_ID = 'COC003')
    [TopLink Fine]: 2007.01.19 02:56:48.568--ServerSession(17712783)--Connection(32404901)--Thread(Thread[http-8080-Processo
    r23,5,main])--SELECT APPL_CGP_MATLOC, CHANGE_REQ_MATLOC, CD_PHA_MAT_LOC, LCOMP, LOC_MAT_NAME, APPL_GDM_MATLOC, LOC_MAT_N
    AME_SHORT, APPL_PDW_MATLOC, PHA_MAT_LOC_LCOMMENT, APPL_TP_MATLOC, DIVISION, APPL_WRS_MATLOC, ARTICLE_ID_MDA, LU_PHA_MAT_
    LOC, LOC_MAT_NAME_OLD, LDT_PHA_MAT_LOC, PHA_MAT_LOC_STATUS, CU_PHA_MAT_LOC, MAT_LOC_ID, RCOMP, MAT_ID FROM RCGC.PHA_V_CO
    MPAS_MAT_MATLOC WHERE (MAT_ID = '10021500150000000997')
    [TopLink Warning]: 2007.01.19 02:56:48.638--UnitOfWork(4469532)--Thread(Thread[http-8080-Processor23,5,main])--Exception
    [TOPLINK-6132] (Oracle TopLink Essentials - 9.1 (Build b22)): oracle.toplink.essentials.exceptions.QueryException
    Exception Description: Query argument ######' not found in list of parameters provided during query execution.
    Query: ReadAllQuery(de.merck.compas.material.SimilarLocalMaterialListItemBV)
    Local Exception Stack:
    Exception [TOPLINK-6132] (Oracle TopLink Essentials - 9.1 (Build b22)): oracle.toplink.essentials.exceptions.QueryExcept
    ion
    Exception Description: Query argument ######' not found in list of parameters provided during query execution.
    Query: ReadAllQuery(de.merck.compas.material.SimilarLocalMaterialListItemBV)
    at oracle.toplink.essentials.exceptions.QueryException.namedArgumentNotFoundInQueryParameters(QueryException.jav
    a:206)
    at oracle.toplink.essentials.internal.databaseaccess.DatasourceCall.getValueForInParameter(DatasourceCall.java:6
    86)
    at oracle.toplink.essentials.internal.databaseaccess.DatasourceCall.getValueForInOutParameter(DatasourceCall.jav
    a:704)
    at oracle.toplink.essentials.internal.databaseaccess.DatasourceCall.translateQueryString(DatasourceCall.java:630
    at oracle.toplink.essentials.internal.databaseaccess.DatabaseCall.translate(DatabaseCall.java:850)
    at oracle.toplink.essentials.internal.queryframework.DatasourceCallQueryMechanism.executeCall(DatasourceCallQuer
    yMechanism.java:212)
    at oracle.toplink.essentials.internal.queryframework.DatasourceCallQueryMechanism.executeCall(DatasourceCallQuer
    yMechanism.java:199)
    at oracle.toplink.essentials.internal.queryframework.DatasourceCallQueryMechanism.executeSelectCall(DatasourceCa
    llQueryMechanism.java:270)
    at oracle.toplink.essentials.internal.queryframework.DatasourceCallQueryMechanism.selectAllRows(DatasourceCallQu
    eryMechanism.java:600)
    at oracle.toplink.essentials.queryframework.ReadAllQuery.executeObjectLevelReadQuery(ReadAllQuery.java:302)
    at oracle.toplink.essentials.queryframework.ObjectLevelReadQuery.executeDatabaseQuery(ObjectLevelReadQuery.java:
    709)
    at oracle.toplink.essentials.queryframework.DatabaseQuery.execute(DatabaseQuery.java:609)
    at oracle.toplink.essentials.queryframework.ObjectLevelReadQuery.execute(ObjectLevelReadQuery.java:677)
    at oracle.toplink.essentials.queryframework.ObjectLevelReadQuery.executeInUnitOfWork(ObjectLevelReadQuery.java:7
    31)
    at oracle.toplink.essentials.internal.sessions.UnitOfWorkImpl.internalExecuteQuery(UnitOfWorkImpl.java:2218)
    at oracle.toplink.essentials.internal.sessions.AbstractSession.executeQuery(AbstractSession.java:937)
    at oracle.toplink.essentials.internal.sessions.AbstractSession.executeQuery(AbstractSession.java:909)
    at oracle.toplink.essentials.internal.ejb.cmp3.base.EJBQueryImpl.executeReadQuery(EJBQueryImpl.java:346)
    at oracle.toplink.essentials.internal.ejb.cmp3.base.EJBQueryImpl.getResultList(EJBQueryImpl.java:447)
    at de.merck.compas.material.SimilarLocalMaterialListItemBC.selectList(SimilarLocalMaterialListItemBC.java:40)
    at de.merck.compas.material.SimilarLocalMaterialListItemBC.selectSimilar(SimilarLocalMaterialListItemBC.java:53)
    at de.merck.compas.material.MaterialMaintainFS.init(MaterialMaintainFS.java:158)
    at de.merck.compas.material.MaterialListSV.startMaterialMaintain(MaterialListSV.java:186)
    at de.merck.compas.material.MaterialListSV.processPage(MaterialListSV.java:97)
    at de.merck.jsfw.servletFramework.AbstractServlet.processPage(AbstractServlet.java:141)
    at de.merck.jsfw.servletFramework.ControllerServlet.processLastPage(ControllerServlet.java:240)
    at de.merck.jsfw.servletFramework.ControllerServlet.processRequest(ControllerServlet.java:206)
    at de.merck.jsfw.servletFramework.ControllerServlet.doGet(ControllerServlet.java:181)
    at de.merck.jsfw.servletFramework.ControllerServlet.doPost(ControllerServlet.java:191)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at de.merck.comp.ntml.NTLMFilter.negotiate(NTLMFilter.java:384)
    at de.merck.comp.ntml.NTLMFilter.doFilter(NTLMFilter.java:165)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:432)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
    at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java
    :664)
    at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
    at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
    at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
    at java.lang.Thread.run(Thread.java:595)
    The Toplink manifest file with version number:
    Manifest-Version: 1.0
    Ant-Version: Apache Ant 1.6.5
    Created-By: 1.5.0_09-b03 (Sun Microsystems Inc.)
    Specification-Title: Java Persistence API
    Specification-Vendor: Sun Microsystems, Inc., Oracle Corp.
    Specification-Version: 1.0
    Implementation-Title: TopLink Essentials
    Implementation-Vendor: Sun Microsystems, Inc., Oracle Corp.
    Implementation-Version: 9.1 build: b22
    Thanks again for your help!

  • Using EJBs in Web Dynpro Applications

    I have recently started to develop Web applications using the Web Dynpro framework. Coming from a pure J2EE world, I must admit that Web Dynpro has a few innovative features that I find interesting for user interface development. The use of component & view contexts, for example, is not unlike the ActionForms that one may find in a Struts application, but pushed a bit further. No complaints here.
    What I do have some problems with is the whole CommandBean paradigm that is put forth by SAP (refer to the document <a href="https://www.sdn.sap.comhttp://www.sdn.sap.comhttp://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webdynpro/using%20ejbs%20in%20web%20dynpro%20applications.pdf">Using EJBs in Web Dynpro Applications</a>).
    I do understand the usefulness of defining a model that will be used to generate and eventually bind to Context data structures. That's fine. What I do object to is the use of a so-called CommandBean to play that role. Again, coming from a J2EE world, I am familiar with the BusinessDelegate pattern - which would typically be used by a client application to invoke business logic on the server side. I would propose that a better, cleaner way of integrating EJBs with the Web Dynpro framework would be to use a BusinessDelegate for invoking business logic, and importing a separate and distinct ModelBean (instead of a CommandBean) to be used for defining and binding to Context data.
    I have built one Web Dynpro application thus far. Instead of using a CommandBean, I created a ModelBean that extends my business object DTO (Data Transfer Object) (which is quite appropriate for that role, given that it implements all the get & set methods that are required for the business data that I need to model). My Web Dynpro application also makes use of an independant BusinessDelegate that is packaged with my EJB DC - this is a standard best practice on J2EE projects. I have been asked by the people working with me to modify this architecture to bring it more in line with the SAP way of doing things. I am open-minded and willing to learn and accept new ways of thinking and doing things. However, I fail to understand the usefulness of merging structure and behaviour by resorting to CommandBeans:
    - <b>It violates the MVC paradigm</b> by having one object (the CommandBean) serve as both model AND controller as far as the Web Dynpro application is concerned. The CommandBean is obviously a model - since it is literally imported as such into the Web Dynpro application. It is ALSO a controller from the Web Dynpro's application perspective, since all calls to the back-end go thru the CommandBean via one or more of its execute_xxx methods. In contrast, the use of a business delegate by the Web Dynpro application clearly separates the model (the CommandBean... or rather, a more suitably named ModelBean) from the controller (BusinessDelegate).
    - <b>Doesn't carry its own weight</b>. In other words, I haven't yet been provided with any valid justification for going thru the extra effort of coding the CommandBean's execute methods. It's been proposed to me that it somehow serves as an abstraction layer between the Web Dynpro application and the business logic. I would argue that it is the BusinessDelegate's role to abstract away the back-end logic from clients. If one does have a BusinessDelegate available, I would argue there's no need to code execute methods in a separate CommandBean. To prove my point, I would simply point out that all of the CommandBean examples that I have seen so far, either in How-To documents, or in production code, all follow the same pattern....
    CommandBean.execute_doSomething() calls BusinessDelegate.doSomething()
    Not a heck of an "abstraction" layer... I would in fact argue that it is worse than useless. If some major change occurs in the business logic that requires changing the doSomething() operation, we expect of course to modify the BusinessDelegate. The Web Dynpro client will also presumably need to be modified - that's to be expected, and unavoidable. But then, we'll also need to go about and change the CommandBean's execute_doSomething() method - again, extra work for no apparent benefit. Adding and removing business methods has the same implication. All this for an layer that simply adds the prefix execute_ in front of all business method calls... Is this "abstraction layer" worth the cost of creating and maintaining it ??
    - <b>Unnecessarily complicates error handling</b>. I have been told that for technical reasons, it is recommended that all exceptions thrown by the CommandBean be of type WDException or WDRuntimException. But what if the client application needs to react differently to different failure scenarios ? When I create a business object, I might wish to provide the user with an error messages if connection is lost to the backend, and with a different error message if an object already exists in the database with the same attributes. In order to do that, I will have to catch the WDException, extract the cause, and continue processing from there... possible, yes, but clearly less standard and more labor intensive than the classical try/catch mechanism.
    To say nothing about the fact that SAP's own API documentation clearly states that applications using Web Dynpro can reference and catch WDExceptions, but THEY MUST NOT THROW OR EXTEND IT !
    - <b>Produces unnecessary DCs</b>. Page 6 of the aforementioned document presents an architectural view of a Web Dynpro project that uses a CommandBean. Why an extra DC for the CommandBean ?? I created my ModelBean class right inside the Web Dynpro project (in the Package view). That, to me, is where this class should reside, because it is created for no other reason that to be used by this particular Web Dynpro application. What is the benefit of placing it in its own independant DC ?
    - <b>Not a typical application of the Command pattern</b>. The well-documented command pattern (Design Patterns - Gang of Four) has been devised mainly to enable encapsulation of request as objects, thereby making it possible to:
    - specify, queue and execute requests at different times
    - decouple execution of a command from its invoker
    - support undo operations
    - support logging changes so that they can be reapplied in case of system crash making it possible to assemble commands into composite commands (macros), thereby structuring a system around high-level operations built on primitive operations.
    None of this applies to the way the SAP CommandBeans are being used. Not that much of an issue to people new to J2EE and/or OO development... but quite confusing for those already familiar with the classic Command pattern.
    At this point, I fail to understand the advantage of merging structure (model) and behaviour (execute methods) through the use of a unique CommandBean object. Am I missing something ?

    Hi Romeo,
    You would be disappointed, this reply ain't anywhere nearby to what you are talking about...
    I wanted to mail you, but you have not mentioned your email in your profile.
    I am really impressed by your flair for writing. It would be far better had you written a blog on this topic. Believe me, it would really be better. There is a much wider audience waiting out there to read your views rather than on the forums. This is what I believe. To top it, you would be rewarded for writing something like this from SDN. On the blogs too, people can comment and all, difference being there you would be rewarded by SDN, here people who reply to you would be rewarded by you. Doesn't make  much a difference.
    Anyways the ball is still in your court
    As far as I am concerned, it has still not been much time since I have started working on Web Dynpro. So can't really comment on the issue...
    Bye
    Ankur

  • Error Connecting to Database using Weblogic Datasource

    Hi,
    I am trying to connect to oracle database from my program using weblogic DataSource. I am using JDK1.3.1.08 , weblogic 7.
    I am using the following code to get Connection object.
    contextFactory ="weblogic.jndi.WLInitialContextFactory";
    providerURL="t3://192.168.0.29:7001";
    dataSource ="temp_ds";
    if(contextFactory!=null)
    properties.put(Context.INITIAL_CONTEXT_FACTORY,contextFactory);
    if(providerURL !=null)
    properties.put(Context.PROVIDER_URL, providerURL);
    initCtx = new InitialContext(properties);
    DataSource ds= (javax.sql.DataSource) initCtx.lookup(dataSource);
    Connection con = ds.getConnection();
    con.setAutoCommit(false);
    I am getting the following error while running the program. Can any body help?
    javax.naming.CommunicationException. Root exception is weblogic.socket.Unrecove
    rableConnectException: [JDK 1.3 or higher required]
    at java.lang.Throwable.fillInStackTrace(Native Method)
    at java.lang.Throwable.fillInStackTrace(Compiled Code)
    at java.lang.Throwable.<init>(Compiled Code)
    at java.lang.Exception.<init>(Compiled Code)
    at java.io.IOException.<init>(IOException.java:47)
    at java.net.SocketException.<init>(SocketException.java:36)
    at java.net.ConnectException.<init>(ConnectException.java:34)
    at weblogic.socket.UnrecoverableConnectException.<init>(UnrecoverableCon
    nectException.java:19)
    at weblogic.rjvm.RJVMManager.checkVersion(RJVMManager.java:451)
    at weblogic.rjvm.RJVMManager.findOrCreateRemoteInternal(RJVMManager.java
    :201)
    at weblogic.rjvm.RJVMManager.findOrCreate(RJVMManager.java:191)
    at weblogic.rjvm.RJVMFinder.findOrCreateRemoteServer(RJVMFinder.java:203)
    at weblogic.rjvm.RJVMFinder.findOrCreate(RJVMFinder.java:169)
    at weblogic.rjvm.ServerURL.findOrCreateRJVM(ServerURL.java:262)
    at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compi
    led Code)
    at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(WLIni
    tialContextFactoryDelegate.java:221)
    at weblogic.jndi.WLInitialContextFactory.getInitialContext(WLInitialCont
    extFactory.java:149)
    at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:671)
    at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:242)
    at javax.naming.InitialContext.init(InitialContext.java:218)
    at javax.naming.InitialContext.<init>(InitialContext.java:194)
    at WeblogicTest.getConnection(WeblogicTest.java:40)
    at WeblogicTest.<init>(WeblogicTest.java:23)
    at WeblogicTest.main(WeblogicTest.java:18)
    at WeblogicTest.printTableData(Compiled Code)
    at WeblogicTest.<init>(WeblogicTest.java:24)
    at WeblogicTest.main(WeblogicTest.java:18)
    Regards
    Kumar

    I am not sure if this is the reason, but going thru the stack trace ...
    javax.naming.CommunicationException. Root exception is weblogic.socket.Unrecove
    rableConnectException: [JDK 1.3 or higher required]Make sure you have JDK 1.3 or higher installed.
    Cheers
    Sekar

  • Error when using named LOV

    This is for Apex 4.0.2.
    I wonder if anybody else has come across this issue: after creating a named LOV in Shared Components and using the LOV on an item, I get this error:
    ORA-20001: Error fetching column value: ORA-20001: Query must begin with SELECT or WITHIt doesn't really matter which item type I choose:
    Display as text (based on LOV)
    Select list (named LOV)
    Popup LOV (named LOV)
    When using popup LOV there is some additional error information:
    Error in init lov: ORA-06561: given statement is not supported by package DBMS_SQL
    p_lov:wwv_flow_security.g_security_group_id:1278218559423697
    wwv_flow_security.g_curr_flow_security_group_id:1278218559423697
    Unable to initialize query.
    etc.However, if I copy-paste the LOV code in the LOV definition on item level (so, not as a named LOV) it works!
    The LOV is simply:
    select rv_meaning d
          ,rv_low_value r
    from   cg_ref_codes
    where  rv_domain = 'F_RC_STATUS'Any ideas?
    Ino
    Forgot to add: I have a lot of named LOV's without problems. It's just when using cg_ref_codes that this occurs (Oracle Designer users will recognize this table :-) )
    But even when using cg_ref_codes, it doesn't happen every time. Some LOV's based on cg_ref_codes do work.
    Edited by: InoL on May 10, 2011 10:33 AM

    I am one step further: I think the problem is that my named LOV was a "Copy and subscribe" from an LOV in my master application. I have deleted and recreated the LOV in the master several times, but that did not help.
    Now, I have created the named LOV in the application itself (not as a copy of the master LOV) and it works. It looks like the copy function in Apex Builder may be the problem.

  • How to make ADF use OC4J datasource

    Hi Gurus,
    I deployed an ADF application on OC4J, and I want my application to use the datasource given by the OC4J, how do I let my application know during design time.

    Refer
    http://www.oracle.com/technology/products/jdev/howtos/10g/usingdatasources/using_datasources.html

  • Connecting to sqlserver using named pipe

    I would like to connect to mssql (running on same PC as SQL Developer) using named pipes.
    The host is listed in the Windows Service Manager as \\SX3102971\SIMSLOCAL
    I have gone to the 'Oracle' tab, selected 'Advanced' and in the 'Custom JDBC URL'
    entered
    jdbc:jtds:sqlserver:\\SX3102971\SIMSLOCAL;namedPipe=true;user=<username>;password=<password>
    where <username> and <password> are the true values.
    I receive a message
    Staus : Failure -Invalid connection information specified. Verify the URL format for the specified driver.
    Can anyone advise on what may be wrong?
    Also, can SQLDeveloper handle blank passwords?
    The database is installed as part of a third party application, which sets the default dba logon with no password. SQL Developer states that a password is required. For the example above I have created my own log on.

    Hi,
    I managed to solve the problem. So don't worry about it.
    For others who are looking for the solution...
    - I have referred to the http://www.qint.de/joria/doc/jdbc/jtds.html.
    - I have changed the URL element in IDEConnections.xml file located under where SQLDEVELOPER software is installed.
    - The URL must look like the following ...
    <URL>jdbc:jtds:sqlserver://\\.\;namedPipe=true;instance=<name of the database - without the server name>;</URL>
    Hope this helps.
    Regards
    Raja
    Message was edited by:
    rajaram_r

  • Dont want to download webstart application onto desktop

    Hi all,
    I dont want my webstart application to be downloaded on desktop or you can say i dont want shortcut of this application on my machine.
    I want to restrict opening of this application from shortcut. I want it can only be opened using explorer.
    Thanks in advance

    Hi,
    Thanks for your reply, i didnt understood your last line "Either way a user could create a shortcut on their desktop to the JNLP file (even if it is on the web). "
    This is my JNLP. Tell me what else i have to do to stop creating shortcut on desktop. I dont want to shortcut creation automatically.
    or if shortcut appears then i dont want application to run from that shortcut.
    <?xml version="1.0" encoding="UTF-8"?>
    <jnlp spec="1.0+"
    codebase="http://10.112.133.205/test"
    href=""
    >
    <information>
    <title>abc</title>
    <vendor>xyz</vendor>
    <homepage href="http://10.112.133.205/test" />
    <description>test</description>
    <icon href="images/logo.gif"/>
    <shortcut online="false">
    <desktop/>
    <menu/>
    </shortcut>
    </information>
    <security>
    <all-permissions/>
    </security>
    <resources>
    <j2se version="1.4+" />
    <jar href="test.jar"/>
    </resources>
    <application-desc
    main-class="SysConfig" name="SysConfig" >
    </application-desc>
    </jnlp>

  • JDev 9.0.3.3 Commit issue when using Transaction DataSource

    Hi,
    Env: JDev 9.0.3.3/WL 6.0 sp1/Oracle 8i
    We have successfully deployed our application in 3-tier(remote mode) in JDev 9.0.3.2. using JClient, EO/VO, EJB Session Facade (BMT).
    Now we are planning to use JDev 9.0.3.3
    In JDev 9033 with the same code base we have issues after Commit.
    We are using ejb.txn.type=global (default) and Weblogic Transactional DataSource. It gives following error after Committing and when we navigate to some other row:
    =====================================================
    [690] BaseSQLBuilder Executing DML ... (Update)
    [691] Executing DML...
    [692] UPDATE CISDBA.DCX_X_SAVED_SEARCH SavedSearch SET DCX_MODEL_YEAR=?,DCX_USAGE_VEHICLE_FAMILY=?,DCX_END_ITEMS=?,DCX_RECORD_STATUS=? WHERE DCX_ID=?
    [693] cStmt = conn.prepareCall(" UPDATE CISDBA.DCX_X_SAVED_SEARCH SavedSearch SET DCX_MODEL_YEAR=?,DCX_USAGE_VEHICLE_FAMILY=?,DCX_END_ITEMS=?,DCX_RECORD_STATUS=? WHERE DCX_ID=?"); // JBO-JDBC-INTERACT
    [694] cStmt.setObject(1, "2004"); /*DcxModelYear*/ // JBO-JDBC-INTERACT
    [695] cStmt.setObject(2, "LX"); /*DcxUsageVehicleFamily*/ // JBO-JDBC-INTERACT
    [696] cStmt.setObject(3, "All"); /*DcxEndItems*/ // JBO-JDBC-INTERACT
    [697] cStmt.setObject(4, "All"); /*DcxRecordStatus*/ // JBO-JDBC-INTERACT
    [698] // ERROR: Unknown data type java.lang.Long // JBO-JDBC-INTERACT
    [699] cStmt.setObject(5, "206"); /*DcxId*/ // JBO-JDBC-INTERACT
    [700] cStmt.execute(); // JBO-JDBC-INTERACT
    [701] cStmt.close(); // JBO-JDBC-INTERACT
    BaseCostInvestCost VO before postChanges...
    this.getWhereClause(): null
    isDirty() before executeQuery...
    this.getWhereClause(): null
    isDirty() after executeQuery...
    BaseCostInvestCost VO before postChanges...
    this.getWhereClause(): null
    isDirty() before executeQuery...
    this.getWhereClause(): null
    isDirty() after executeQuery...
    [702] BaseSQLBuilder: releaseSavepoint 'BO_SP' ignored
    [703] BaseSQLBuilder: setSavepoint 'BO_SP' ignored
    BaseCostInvestCost VO before postChanges...
    this.getWhereClause(): null
    isDirty() before executeQuery...
    this.getWhereClause(): null
    isDirty() after executeQuery...
    BaseCostInvestCost VO before postChanges...
    this.getWhereClause(): null
    isDirty() before executeQuery...
    this.getWhereClause(): null
    isDirty() after executeQuery...
    [704] BaseSQLBuilder: releaseSavepoint 'BO_SP' ignored
    [705] EJBTxnHandler: Commited txn
    [706] BaseCostInvestCostView2 notify COMMIT ...
    [707] BaseCostInvestCostView1 notify COMMIT ...
    [708] StdCostView1 notify COMMIT ...
    [709] AltCostView1 notify COMMIT ...
    [710] PaperCarView1 notify COMMIT ...
    [711] InvestCostItemView1 notify COMMIT ...
    [712] SavedSearchView1 notify COMMIT ...
    [713] AltCostView1_BaseInvestToAltViewLink_AltCostView notify COMMIT ...
    [714] InvestCostItemView1_BaseInvestToInvestItemViewLink_InvestCostItemView notify COMMIT ...
    [715] PaperCarView_BaseCostTrackedVehicleViewLink_PaperCarView notify COMMIT ...
    [716] VehicleProgramLOV1 notify COMMIT ...
    [717] SubDeptLOV1 notify COMMIT ...
    [718] Transaction timeout set to 28800 secs
    [719] Column count: 14
    [720] ViewObject : Reusing defined prepared Statement
    [721] QueryCollection.executeQuery failed...
    [722] java.sql.SQLException: The transaction is no longer active (status = Committed). No further JDBC access is allowed within this transaction.
         void weblogic.jdbcbase.jts.Connection.checkIfRolledBack()
              Connection.java:468
         void weblogic.jdbcbase.jts.Statement.setMaxRows(int)
              Statement.java:179
         void weblogic.jdbc.rmi.internal.StatementImpl.setMaxRows(int)
              StatementImpl.java:82
         void weblogic.jdbc.rmi.SerialStatement.setMaxRows(int)
              SerialStatement.java:132
         void oracle.jbo.server.QueryCollection.executeQuery(java.lang.Object[], int)
              QueryCollection.java:534
         void
    ===================================================

    Hi Carsten,
    I tried to reproduce your problem, but couldn't. Let me explain what steps I executed and perhaps you can advise where I've not matched your steps.
    --Using build jdeveloper 9.0.3.3.1203, I built a new bc4j project containing a dept-emp default bc4j project (deptEntity, empEntity, deptView, empView, deptempFKAssoc, deptempFKViewLink, ApplicationModule).
    --In dos shell, I went to the directory \jdevdir\jdev\bin and ran setvars -go to set the correct jdk version
    --In the dos shell, in the directory \jdevdir\j2ee\home I executed the following command to install oc4j:
    java -jar oc4j.jar (defaults pswd to welcome for admin)
    --I remoted the appmodule to EJB Session Bean (BMT) and created a new deployment profile using the 9ias configuration for the application module.
    --I deployed the bc4j objects to oc4j
    --I created a new project
    --In this project I created a new jclient master-detail form using the above project's application module for the data model
    --I saved all and compiled the jclient project
    --I ran the jclient form and inserted a master record
    --I committed the transaction successfully
    --I browsed records, then edited a record
    --I committed the transaction successfully, then browsed.
    Is there something I've missed? Did you migrate your project and not start by creating a new project? Is there something special about the database schema you are using?
    Thanks,
    Amy

Maybe you are looking for

  • Mac and Bluetooth

    Hi. None of my bluetooth equipments works with my Mac Book Pro. This really a problem. My Macbook does even not find my iPhone 4s. It does not fiind my iPad an not my daugthers iPad. Both iPads does not find my Logitech's Keyboard folio. My older Pow

  • Use of Condition update while creating Condition Records

    Hi Experts, I have to maintain MRP for a product which will be applicable for only 1 particular order. after which system should pick up old MRP. By using CONDITION UPDATE feature , i have tried to do it , but once maintained , its always picking new

  • Can mdsys.sdo_relate return FALSE?

    I have the following query: SELECT MIN (dtczas) dtczas FROM sd_car_location WHERE dyza_id = 2 AND dtczas > '24-JUN-2002 11:06:48' AND mdsys.sdo_relate( geom, MDSYS.SDO_GEOMETRY( 2003, NULL, NULL, MDSYS.SDO_ELEM_INFO_ARRAY(1, 1003, 3), MDSYS.SDO_ORDIN

  • My nef files from my D7100 won't import, whats wrong with lightroom 5.  This just started happening

    Why won't my NEF files  from my Nikon D7100 import to lightroom 5.  I have the latest updates!

  • COLOUR DISPLAY ISSUES

    Using photo shop, when I place an image into a document it comes up in grey rather than colour. Also if I try to fill new layer it appears grey although it displays the correct pantone. Can anyone advise me how to fix this please? Thank you