Using WLST to set up credential mapping on JDBC Data Source

I am wanting to write a script (WLST) to set up a large initial set of credential mappings on a JDBC data source.
I can create the datasource and do all the basic set ups, but I can't figure out how to do the credential mappings.
I tried the "record" option from the Admin console, but it created a script that says that credential mappings are not recorded.
This is the mapping function that you get to from the "Security" tab on the DataSource page, and then the "Credential Mappings" tab. This allows you to map a "WLS user" to a "remote user" - which in my case is an Oracle OLS user.
I am using Weblogic 10.3
Can anyone point me to a set of commands which can perform this function?
Thanks!

I wonder if there isn't a publicly visible MBean for the credential mapping. That would explain why the recorded script doesn't have the mbean method invocations.

Similar Messages

  • Using DAO using a JDBC data source with struts

    Hello,
    I have created a number of Data Access Objects and Transfer Objects to use in a non EJB, struts web application I am developing. I had tested these with a kind of a Service Locator custom class to provide access to a JDBC connection. My custom class is a bit clunky and not very configurable. I would like to use a data source using the struts config XML file e.g.
        <data-sources>
            <!-- configuration for commons BasicDataSource -->
            <data-source type="org.apache.commons.dbcp.BasicDataSource">
                <set-property
                  property="description"
                  value="My MySQL Database Connection" />
                <set-property
                  property="driverClassName"
                  value="com.mysql.jdbc.Driver" />
                <set-property
                  property="url"
                  value="jdbc:mysql://localhost/databaseName" />
                <set-property
                  property="username"
                  value="myUsername" />
                <set-property
                  property="password"
                  value="xxxxxxxxx" />
                <set-property
                  property="maxActive"
                  value="10" />
                <set-property
                  property="maxWait"
                  value="5000" />
                <set-property
                  property="defaultAutoCommit"
                  value="false" />
                <set-property
                  property="defaultReadOnly"
                  value="false" />
             </data-source>
        </data-sources>This is great, and precisely the kind of thing I would like to use. However, this datasource is only available AFAIK through a HttpServletRequest instance like in the example I found below...
        public ActionForward execute(ActionMapping mapping, ActionForm form, HttpServletRequest request,
                                     HttpServletResponse response)     throws Exception
            javax.sql.DataSource dataSource = null;
            java.sql.Connection myConnection = null;
            try {
             dataSource = getDataSource(request);
             myConnection = dataSource.getConnection();
             // do what you wish with myConnection
            } catch (SQLException sqle) {
               getServlet().log("Connection.process", sqle);
            } finally {
               //enclose this in a finally block to make
               //sure the connection is closed
               try {
                  if(myConnection != null)
                      myConnection.close();
               } catch (SQLException e) {
                  getServlet().log("Connection.close", e);
            return (mapping.findForward("success"));
        }That would be great if I wanted to use the database connection anywhere near a struts Action (wrong tier!). I want access like that to to a data source in my DAOs. Is it possible for me to use the data-sources aproach to access the DB from my DAOs or will I need to use something like JNDI to do this in a similar way but separate from struts. If so I have a big gap in my knowledge as far as JNDI goes which I need to fill and that will be my next question
    I'm relatively new to using patterns inn Java and any help or pointers would be great.
    Thanks :)

    Create a JAAS Authentication Entry in the Server configuration.
    This should then appear in the drop-down when specifying your DataSource.

  • How to set JDBC Data Sources in Oracle MapViewer for Oracle database 12c Release 1 (12.1.0.1)

    How to set JDBC Data Sources in Oracle MapViewer for Oracle database 12c Release 1 (12.1.0.1)?
    The following is my configuration in the conf\mapViewerConfig.xml:
    <map_data_source name="mvdemo12"
    jdbc_host="127.0.0.1"
    jdbc_sid="orcl12c1"
    jdbc_port="1522"
    jdbc_user="mvdemo"
    jdbc_password="7OVl2rJ+hOYxG5T3vKJQb+hW4NPgy9EN"
    jdbc_mode="thin"
    number_of_mappers="3"
    allow_jdbc_theme_based_foi="true"
    editable="true"/>
    <!--  ****  -->
    But it does not work.
    After use "sqlplus mvdemo/[email protected]:1522/pdborcl", it connected to the Oracle database 12c.
    Does anyone know it?
    Thanks,

    For 11.1.1.7.1 use the syntax for jdbc_sid, i.e.
    //mypdb1.foo.com as described in the README,
    - MapViewer native (non-container) data sources can now use database service name in place of SID. To supply a db service name, you will use the same jdbc_sid attribute, but specify the service name with double slashes in front, such as follows:
      <map_data_source name="myds"
        jdbc_host="foo.com"
        jdbc_sid="//mypdb1.foo.com"
        jdbc_port="1522"
      />
    For 11.1.1.7.0 use a container_ds instead.
    i.e. instead of using
    <map_data_source name="my_12c_test"
                       jdbc_host="mydbinstance"
                       jdbc_sid="pdborcl12c"
                       jdbc_port="1522"
                       jdbc_user="mytestuser"
                       jdbc_password="m2E7T48U3LfRjKwR0YFETQcjNb4gCMLG8/X0KWjO00Q="
                       jdbc_mode="thin"
                       number_of_mappers="6"
                       allow_jdbc_theme_based_foi="false"
                       editable="false"
       />
    use
      <map_data_source name="my_12c_test"
                       container_ds="jdbc/db12c"
                       number_of_mappers="6"
                       allow_jdbc_theme_based_foi="false"
                       editable="false"
       />
    In my case the Glassfish 3.1.2.2 JDBC connection pool definition was
    Property
    url  jdbc:oracle:thin:@mydbinstance:1522/pdborcl12c.rest_of.service.name
    Uncheck the Wrap JDBC Objects option in Advanced panel, i.e. the Edit JDBC Connection Pool Advanced properties page.
    Add a JDBC resource for that newly created pool
    Use that in mapviewerconfig.xml as above

  • Setting up csv files as a data source for Hyperion intelligence explorer on Windows 7

    Hi. wondering anyone can point me to a resource or supply me with step son how to Set up csv files as a data source for Hyperion intelligence explorer on Windows 7?
    I used to be able to do it in WXP, but it seems thing shave really changed with W7..... Absolutely desperate... All and any help welcome.....

    Hi
    Can you please try setting up full persmission in the security properties for everyone on the wsconfig folder C:\ColdFusion10\config\wsconfig  and restart ColdFusion Server.
    Swaraj

  • Using JDBC Data Sources with ADFBC, NoInitialContextException

    Using JDBC Data Sources with ADF Business Components, NoInitialContextException
    I follow the instruction in the link below to create an ADF Swing application using datasource. I am using JDeveloper version 10.1.3.
    http://www.oracle.com/technology/products/jdev/howtos/10g/usingdatasources/using_datasources.html
    The ADF generated code looks like this:
    JUMetaObjectManager.setErrorHandler(new JUErrorHandlerDlg());
    JUMetaObjectManager mgr = JUMetaObjectManager.getJUMom();
    mgr.setJClientDefFactory(null);
    BindingContext ctx = new BindingContext();
    ctx.put(DataControlFactory.APP_PARAM_ENV_INFO, new JUEnvInfoProvider());
    ctx.setLocaleContext(new DefLocaleContext(null));
    HashMap map = new HashMap(4);
    map.put(DataControlFactory.APP_PARAMS_BINDING_CONTEXT, ctx);
    mgr.loadCpx("datasource.view.DataBindings.cpx" , map);
    final FormMain frame = new FormMain();
    frame.setBindingContext(ctx);
    I got this error when executing the last line: frame.setBindingContext(ctx);
    (oracle.jbo.common.ampool.ApplicationPoolException) JBO-30003: The application pool (datasource.datamodel.AppModuleDS) failed to checkout an application module due to the following exception:
    ----- LEVEL 1: DETAIL 0 -----
    (oracle.jbo.JboException) JBO-29000: Unexpected exception caught: oracle.jbo.DMLException, msg=JBO-27200: JNDI failure. Unable to lookup Data Source at context jdbc/xe_hrDS
    ----- LEVEL 2: DETAIL 0 -----
    (oracle.jbo.DMLException) JBO-27200: JNDI failure. Unable to lookup Data Source at context jdbc/xe_hrDS
    ----- LEVEL 3: DETAIL 0 -----
    (javax.naming.NoInitialContextException) Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial
    If I configure the application module connection type as JDBC URL, everything works.
    If the connection type is JDBC Datasource, I got the above error.
    Can someone show me how to adjust the generated code by ADF to use datasource?

    ADF BC has a bug. With Data Source in Application Module, application module does not connect. Use JDBC Connection URL.
    Also refer
    ADF BC: JDBC URL vs JDBC DataSource

  • Setting up JDBC Data Source for JCA Database Adapter  in WLS - only SID?

    Following the documentation for setting up a connection for use with the JCA Database Adapter (http://otnbeta.oracle.com/fmw11g/582tj30eapvb/integration.1111/e10231/life_cycle.htm), section 2.4.1, Step 8 simply says "Enter the connection properties in the Connection Properties page, and then click Next"
    In the "Create a New JDBC Data Source" screen of the WLS Administration Console there is the entry field vaguely labeled as "Database Name:" Of course I entered the Oracle RDBMS service name (which we should ALWAYS be using), only to be informed upon clicking next, that WLS was expecting the SID.
    Two things:
    1. At least through this maintenance console, it appears that BEA did not understand the whole concept or value of Oracle RDBMS logical service names versus the SID (I have seen this in several products that Oracle has acquired). Best practice would be to use the Oracle RDBMS service name, which doesn't appear to be an option in this console.
    2. The OFM documentation should be more helpful in explaining.

    Compare to the analogous setup in OAS 10.1.3.4/EM... far better clarity in the maintenance console and option of either SID or service name.

  • WLS 10.3.4: How to use OS authentication for JDBC Data Source

    Hello all,
    As a preface, I've tried searching the forum/Google for "OS authentication" and reading the WLS JDBC doc to no avail - if it's documented somewhere, a RTFM link would be much appreciated.
    I'm trying to set up a JDBC data source on WLS that leverages the OS Authentication capability of the Oracle database. If it would help, I can go into the reasoning behind why I want to do this, but basically, it's to simplify the config/deployment of a COTS application. What I have in the database is an "identified externally" user that corresponds to the OS user that is running the WebLogic Server. Normally, in tools such as SQL*Plus, I would use "/@db" as the username/password (in other words, no username and no password specified), and I would be logged in as the "idenfitied externally" user. I want to configure the same thing for a WebLogic Data Source, but if I leave the username/password blank, testing the connection in the WLS console gives me "invalid username/password, login denied" I've also tried using "/" as the username, as was documented in a quite old WLS faq, but that gives me the same result.
    Is there some magic switch I need to flip?
    Thanks,
    John

    Hi John, there's no way to do that with connection pools, which is how WLS datasources get their
    connections, or middleware in general. WebLogic would have no way of knowing which if any of the
    pooled connections was appropriate for the current 'user', which is not the application user, but
    instead is the OS identity of the person who started the WebLogic server! If you start up your
    WebLogic server, and people start pointing their browsers to it, doing various stuff, the OS knows
    you started WebLogic, and maybe with the help of OCI, Oracle's JDBC might know it was you who
    started WebLogic's OS process, but what does the OS know about any user that may be running
    a browser or application elsewhere (even if on this same machine), when that browser or application
    connects to your WebLogic server process?
    HTH,
    Joe

  • BW1 transaction for mapping newfield to data source in CRM

    Hi,
    This will be BW gurus working in the CRM Opportunity area.
      Based on my current understanding I have copied the 0CRM_OPPT_H into ZCRM_OPPT_H and wanted to see whether I can map more partner function to map to the data source.
    Currently, the following fields are offered by the SAP Delivered data source 0crm_oppt_h in CRM.
    PARTNET FUNC    DATA source field     BDOC Mapping bwa1
    IN CRM          0crm_oppt_h
    Contact person   contact_person    PARTNER-PARTNER_NO
    <NOT used>       EXECUTING_CC      PARTNER-PARTNER_NO
    configured PF    COMPETITOR        PARTNER-PARTNER_NO
    Emp responsible  PERSON_RESP       PARTNER-PARTNER_NO
    Sales Prospect   PROSPECT          PARTNER-PARTNER_NO
    SALES_EMPLOYEE   Employee          PARTNER-PARTNER_NO
    Currently we have configured 4 more partner functions for our opportunity transaction, which are not available in the 0CRM_OPPT_H data source. However we shall need these fields to send to BW.
    How can we extend the mapping in BWA1 after extending/appending the extraction structure (CRMT_BW_OPPT_H) of the data source? Shall we continue to map these addition fields in the data source to PARTNER-PARTNER_NO as mentioned above? What puzzles us that this is header info and the PARTNER_NO is able to bring info for different partner func.. How this is being possible?
    If we also map the same for the additional partner fields will we be  able to aviod the BADI/User exit and the code associated that populated these fields?
    What is the BKM? How the BWA1 can be used for Extending for more partrner( functions?)
    Thanks
    AGN

    Hi Aswin,
      while this is really helpful to enable me to dig into further, the basic question is not yet answered.
    Currently the data source 0CRM_OPPT_H are able to extract the following partner data
    contact person
    prospect
    channel pertner
    empoyee responsible
    However only one( contact person  00000017)  is mentioned in our  CRM system in the SPRO steps that you have shown.. My first question is how then the data source is able to get the other partner function....
    2> Secondly even if I mention all the partner functions in that transaction( as you have mentioned) how do the data source really know where to populate which partner function data.. since the bdoc mapping is Partner-partne_no...
    For example if I maintain the following in SPRO
    00000017  contact person
    00000026  emplyee responsible
    How do the data source gets rightly populated ( contact person value in the contact_person field and vice versa).. when the BDOC Mapping for both these two fields are simply partner-partner_no?
    Appreciate a detail explanation from you on this.
    Thanks
    AGN

  • Need Help on using CAS Incremental Crawl with JDBC data source

    Hi,
    As part of one of the e-commerce implementations, we are implementing a delta pipeline which reads the data from the database views. We plan to crawl the data with the help of CAS JDBC data source. In order to optimize the data reads, we want to use the CAS capabilities of incremental crawl. We rely on CAS to be able to identify the updates available in the subsequent incremental crawl and only read the updated data for any given crawl unless we force a full crawl.
         We have tried implementing the above setup using JDBC data source. CAS reads from the database and stores it in the record store. The Full crawl works fine however; we observed some unexpected behavior during the incremental crawl run. Even when there is no change in the database, crawl metrics show that certain number of records have been updated in the record store and the number of updates differ in every subsequent run.
    Any pointers what can be the issue ? Does CAS has the incremental crawl capability using JDBC data source ?
    Regards,
    Nitin Malhotra

    Hi Ravi,
    Generic Extraction is used to extract data from COPA tables. And delta method used to extract delta records (records created after initilization) is timestamp.
    What is this timestamp?
    Assume that, you have posted 10 records one after the other to the COPA tables. And we do initilization to move all these 10 records to BW system. Later another 5 records are added to COPA tables. How do you think the system identifies these new 5 records (delta records).?
    It identifies based on a timestamp field (eg : Document created on ,a 16 digit decimal field).
    Assume that, in our previous initilzation, say  "document created on" field for the last (or the latest) record is 14/11/2006, 18.00 hrs. and  timestamp is set to the 14/11/2006, 18.00hrs.  then when you do delta update, the system treats all the records with "document created on" field is greater than 14/11/2006, 18.00 hrs as delta records. This is how new 5 records are extracted to bw system and timestamp is again set to the new value besed in field in the records.(say 14/11/2006, 20.00hrs)
    Assume that, you have two records with "document created on" field as 14/11/2006, 17.55hrs and 14/11/2006, 17.57hrs. and they were updated to the COPA table after 14/11/2006,20.00hrs (at this time last delta load is done)  due to some reason. How can you bring these two records? For this, purpose we can reset the timestamp at KEB5. In this eg, we can reset as 14/11/2006, 17.50 hrs) and do the delta again. So, the system picks all the records which are posted after 14/11/2006,17.50hrs again.  But remember that, doing this, you sending some of the records again (duplicate records). So, make sure that you sending ODS object. otherwise you end up with inconsistant data due to duplicate records.
    Hope this helps!!
    Vj

  • HI,How can i set delta option for costumised Generic data source

    Hi Sir/Madam,
          How can i set delta option for costumised Generic data source.
    Regards,
    Vishali.R
    Please search the forum before posting a thread
    Edited by: Pravender on Aug 15, 2011 1:26 PM

    Hi,
    Go to RSO2 transaction and click on change then on the tool bar click on Generic Delta button. In the next popup you can set your delta.
    Regards,
    Durgesh.

  • Using report parameter in data set filter expression with an SSAS data source

    I have an SSRS report with an SSAS data source.
    Report parameters:
    Param1 - text, single select
    Param2 - text, multi-select
    Dataset:
    In Query Designer, I want to include Param1 as a filter expression so I can have "Dimension1 Begins with @Param2". I'm not sure the exact syntax to make param2 work in this.
    The point is to filter my data set on param1. If A is selected for param1, I want the data set to have the filter saying "Dimension1 begins with A"
    Anyone know how to use a report parameter in the dataset filter expression for an ssas data source?

    hi,
    try this maybe the dates you are comparing are not in the same format.
    I test data template in EBS but not with dates.
    to_date(date,'dd/mm/YY') between to_date(:p_from_date ,'dd/mm/YY') and to_date(:p_to_date ,'dd/mm/YY')
    if dont works try to put values insted of your parameter like :
    to_date(date,'dd/mm/YY') between to_date(:p_from_date ,'10/01/07') and to_date(:p_to_date ,'01/12/07') ... put dates where u can have some values in report...
    if dont work then try to print the values of the 2 parameters and the date of the select somwhere in ur report to see what you have in it..
    hope it helps..
    Regards Joe.

  • Setting pl/sql procedure as the data source in a Report Query

    Is there a way to set PL/SQL as the data source in a Report Query? we want to
    able to use the ReportQuery function and query results returned by a PL/SQL procedure.
    thanks

    Not exactly sure what you want to do, but on a ReportQuery you can set either a StoredProcedureCall, or an SQLCall.
    query.setCall(new StoredProcedureCall(...));
    query.setCall(new SQLCall("begin; my_proc(); end"));
    Now, a stored procedure in Oracle cannot return a result, so using a ReportQuery which requires a result may not make sense.
    You could instead use a DataModifyQuery.
    If you return results through output parameters (you must use a StoredProcedureCall for this) you could use a DataReadQuery or a ReadAllQuery/ReportQuery if you wish to build objects from the data.
    James : http://www.eclipselink.org

  • Setting up a database as a data source. Is it a requirement?

    Am I required to set up my MS Access 2000 database (abcxyy.mdb) as a data source under Control Panel \ Administrative Tools \ Data Sources in Windows 2000 before I can connect to it using Java or can I set the path to it in my source code? If I can do it via the source code could someone give me an example of doing it that way? Thank you in advance for your help.

    OK, I've given you the dukes. Thanks for the link.
    If I'd known I was asking about making a "DSN less connection" I would've done a search for it.:)
    Can you tell me what DBQ is in the following?:
    String url = "jdbc:odbc:DRIVER={Microsoft Access Driver (*.mdb)};DBQ=c:\\full\\path\\to\\database.mdb";

  • How to set the POV in WebAnalysis when data source is HFM?

    Hi Every one..
    Could any one tell how to set pov in web analysis when data base is HFM. And hoe to make the report Dynamicall (Current Pov Member like in FR). for this if use Essbase Ican get it it easiliy by using Subtitutional variable but is ti possible fo rHFM.
    Thnaks in advance
    Rao

    yeas agree with sanakar,
    this field which shankar is talking about must be entry date (if u delta timestamp is date, u will also have to mention this table field name in definition of delta), this means that this field will catch last change to the record, so that it will be delta enabled based on the latest change date. This is very important becuase if u use date like posting date to the delta then back dated posting will not captured in to the delta, as delta for this back date is already been done.
    Hope u understand this.

  • How to set the delta for existing generic data source

    Hi BW Guru's
    I have a problem,actually i have a exsting generic data source"ZFRBHRCHY". Master data Object ZFRBHRCHY  is getting laoded from all some R/3 Clusters on a Daily Basis. It is full load and takes 4 to 5 Hours, but number of added records(2000) are very less,while total records are more(40Lks).For avoiding this larger load time every day,i want to implement delta extraction for this.
    How to implement this,(i want steps for this) .
    Thanks in advance,
    Regards
    reddy

    yeas agree with sanakar,
    this field which shankar is talking about must be entry date (if u delta timestamp is date, u will also have to mention this table field name in definition of delta), this means that this field will catch last change to the record, so that it will be delta enabled based on the latest change date. This is very important becuase if u use date like posting date to the delta then back dated posting will not captured in to the delta, as delta for this back date is already been done.
    Hope u understand this.

Maybe you are looking for

  • How do i create this function?

    How do i create a function like this "attached" so that when a customer decides he likes a different color, he can just click the link with the dot or symbol next to the color name.

  • Strange issue with Multi-Table LTS and report filters (10g)

    Hi, I am having some troubles with the following scenario: I have a large flattened table that is being used as both Fact and Dimension in the BMM layer. I also have another table that contains some supplementary measures needed by some reports. Logi

  • LM4 Previous Export Folders Grayed Out

    When Exporting images in LM4 (4.0), the previous list of export folders is grayed out  and none can be selected.  You have to choose the destination folder via the Choose button.  On the next Export the previously selected folder appears in the list

  • Apple ID has been disabled for security reasons.  I reset password and it still says this.

    Has anyone got advice on apple tv connection.  Apple account disabled for security reasons.  It said to reset account but all I was able to do was reset password which I did.

  • 10g: Database Diagram "Unable to Locate Elements For ..."

    Hello, In experimenting with JDeveloper 10g Diagram feature (IDE version 9.0.5.13.88), I experienced a rather vexing problem. I wondered if anyone could shed some light onto the issue for me and perhaps even help get it corrected. I started off by Up