How to configure datasource in JBOSS?

Hi All,
I want to configure datasource in JBOSS for oracle database? The constraints are
1) The password should be in the encrypted format in the configuration file because I dont want to reveal my password to anyone.
How can we acheive this.
Can I do the encryption at the time of build(If yes how?)
For any help Thanks in advance.
Rajani Kanth

Hi Rajani
I was browsing the web looking for a way to solve the same problem.
Have you every found a way to do this?
I'm faced with the same problem: I must encrypt the user name and
password.
Did you find out whether JBoss has a way to accomplish this.
Many thanks in advance.
Serge
[email protected]

Similar Messages

  • How to configure and use jboss cache

    Hi,
    I need to use Jboss Cache in our application,
    But i don't know anything about Jboss Cache...
    can u tell me requirements and configuration for this?
    and i am using jboss application server 3.2.3..
    and apache-ant-1.7.1, jdk1.6.0_06, jbosscache 2.2.0
    can u tell me how to configure and use jboss cache?
    Thanks & Regards
    Thilkumar

    Go to the JBoss web site and read up on the documentation there.
    And if you still have any questions you'll probably get better answers at the JBoss forums than in these forums.
    - Roy

  • How to configure Hibernate in JBoss

    Hi,
    I'm using JBoss to run my application.
    we are migrating complete application from JDBC to Hibernate,
    Can any one explain how should i configure Hibernate in JBoss server
    Cheers

    Go through this tutorial: http://www.hibernate.org/hib_docs/v3/reference/en/html/tutorial.html
    It explains how to setup hibernate.

  • How to configure datasources in tomcat 4.1.12 to obtain OracleResultSets

    Hi!
    Since my application running under both OracleAS and Tomcat 4.1.12 should obtain connection pooling i tried to configure the application servers. Our application makes use of OracleResultSet. I configured OracleAS by editing the data-sources.xml file which works very well:
    <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:@testdb:1525:ORA5"
    inactivity-timeout="30"
    />
    The code for jndi lookup is here. It works fine when i cast ResultSet to OracleResultSet using OracleAS:
    initCtx = new InitialContext();
    envCtx = (Context) initCtx.lookup("java:comp/env");
    dataSource = (DataSource) envCtx.lookup("jdbc/OracleDS");
    con = dataSource.getConnection();
    ResultSet rs = con.executeQuery("..");
    OracleResultSet orars = (OracleResultSet)rs;
    Then i configured tomcat 4.1.12 server.xml file:
    <Resource name="jdbc/OracleDS" auth="Container" type="javax.sql.DataSource"/>
    <ResourceParams name="jdbc/OracleDS">
    <parameter><name>username</name><value>scott</value></parameter>
    <parameter><name>password</name><value>tiger</value></parameter>
    <parameter><name>driverClassName</name><value>oracle.jdbc.driver.OracleDriver</value></parameter>
    <parameter><name>url</name><value>jdbc:oracle:thin:@testdb:1525:ORA5</value></parameter>
    </ResourceParams>
    The same source for jndi lookup brings up a ClassCastException at line
    OracleResultSet orars = (OracleResultSet)rs;
    Therefore i tried to add a new parameter in tomcats server.xml:
    <parameter><name>factory</name><value>com.evermind.sql.DriverManagerDataSource</value></parameter>
    Now following exceptions occurs:
    javax.naming.NamingException: Could not create resource factory instance, com.evermind.sql.DriverManagerDataSource
    java.lang.Object org.apache.naming.factory.ResourceFactory.getObjectInstance(java.lang.Object, javax.naming.Name, javax.naming.Context, java.util.Hashtable)
    I have oc4j.jar and classes12.jar in tomcats home directory under config/lib.
    How should i configure tomcat to be able to use connection pooling and OracleResultSets?
    Thanks in advance!
    thomas

    ?

  • [SOLVED] - How to configure datasources in TP4

    Hello,
    I see there is no longer a Tools >> Embedded OC4J Server Preferences menu option in TP4.
    I have searched here and looked through the help to no avail...
    How/Where do we configure our Datasources under TP4?
    Thanks,
    Ripley
    Message was edited by:
    Ripley
    Message was edited by:
    Ripley

    I'm not sure this is exactly what you're looking for, but try Tools -> Java EE Runtime Preferences, then select the Embedded OC4J radio button option, followed by the Embedded OC4J Server Preferences button, and within the dialog that pops up their is a Data Sources node.
    Hope this helps.
    CM.

  • Please help : How to configure a datasource in 9iAS

    Hello all,
    I am new at 9iAS . Can anyone tell me how we configure datasource with JNDI name in 9iAS.
    any help will be appriciated.
    Thanks a lot
    Madhukar
    null

    Do you mean from flash in a web page or do you mean
    converting the swf file format (maybe with a decompiler or
    whatever).
    If you're meaning to do it from flash in a web page:
    You can't save a movieclip from flash to svg. You could
    perhaps record drawingAPI commands and create the appropriate svg
    output in an internal xml object which you then send to the server.
    But I don't know of any pre-built classes to do that (disclaimer:
    because I don't know of any doesn't mean they don't exist).
    Going from svg to flash is doing it the other way around.
    Converting the svg paths back to actionscript drawing commands. I
    think I've seen some examples of this online somewhere.

  • How to include new driver and configure datasource in NW 7.0

    Hi,
    I have deployed my application in the app server and now i need to add the ms sql drivers to the application server and configure datasource to it.
    Can any one help me to configure the datsource in Nw 7.0 and also how to add the driver files tp app server..?
    thanks in advance
    jayakumar

    Hi,
    Follow these links:
    How To Install and Configure External Drivers for the JDBC & JMS
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/f04ce027-934d-2a10-5a8f-fa0b1ed4d88f
    http://saphelp.border-states.com/EN/b3/cc633c3a892251e10000000a114084/content.htm
    http://www.sapag.co.in/JDBC%20Adapter-Type2JDBCDriver%20Deployment.html
    Regards,
    Nithiyanandam
    Reward points

  • How to configure automatic reloading the class in jboss-3.2.1_tomcat-4.1.24

    HI,
    In tomcat, web context is specified in Server .xml file with
    <!-- Tomcat Examples Context -->
    <Context path="/examples" docBase="examples" debug="0"
    reloadable="true" crossContext="true" />.
    this will deploy my examples webapplication in Tomcat server. And the property reloadable="ture" makes my life easiear. When even I change a .class, the class is automatically loaded in to memory with out restarting the server. Let me know the how to configure the same in Jboss-3.2.1_tomact-4.1.24 (auto-reload context) . Requesting for immediate solution

    I am running into the same problem. The only solution I know is to touch the application.xml which will reload the .ear file, which is not efficient in my case.
    Please let me also know if you have come across something else useful.
    Thanks,
    Mangal
    [email protected]

  • How to configure bc4j.xcfg ConnectionDefinition to JBoss 3.2.3?

    Hi,
    we have the following scenario here: a JClient for BC4J goes via Web Start
    and tries to communicate back to the AppModule deployed in JBoss 3.2.3 as
    Session Bean (BMT).
    We are using JDev 9.0.4.
    How can we configure the element <ConnectionDefinition> in common\bc4j.xcfg
    file in order to lookup the AppModule at JBoss?
    We were able to set up this scenario working in OC4J, but we are in trouble
    with JBoss.
    How can we change the following connection so it points to a JBoss app server?
    <ConnectionDefinition name="MyConnection">
    <ENTRY name="URL" value="ormi://myserver/"/>
    <ENTRY name="ConnectionName" value="MyConnection"/>
    <ENTRY name="user" value="admin"/>
    <ENTRY name="ConnectionType" value="OC4J"/>
    <ENTRY name="password">
    <![CDATA[{904}05E438994FF93]]>
    </ENTRY>
    <ENTRY name="JNDI_INITIAL_CONTEXT_FACTORY" value="com.evermind.server.rmi.RMIInitialContextFactory"/>
    <ENTRY name="DeployPassword" value="true"/>
    <ENTRY name="TARGET_NODE" value="http-web-site"/>
    <ENTRY name="DeployPassword" value="true"/>
    </ConnectionDefinition>
    Maybe it should look like this?
    <ConnectionDefinition name="MyConnection">
    <ENTRY name="URL" value="jnp://myserver:1099"/>
    <ENTRY name="ConnectionName" value="MyConnection"/>
    <ENTRY name="ConnectionType" value="JBoss"/>
    <ENTRY name="JNDI_INITIAL_CONTEXT_FACTORY" value="org.jnp.interfaces.NamingContextFactory"/>
    <ENTRY name="JNDI_URL_PKG_PREFIXES" value="org.jboss.naming:org.jnp.interfaces"/>
    </ConnectionDefinition>
    Hope somebody can help us.
    Eduardo.

    Frank,
    the reason we didn't deployed BC4J as a Web application is we weren't given options. Our contractor wanted a 3-tier application with rich client (JClient/Swing), an load-balanced application server and a legacy database at back end.
    The problem with the article "How Do I Deploy BC4J Applications to JBoss?" is that it doesn't mention how to configure common\bc4j.xcfg in order to connect with JBoss app server.
    The connection with the data source is ok.
    But how come the client would be able to lookup Remote Home interfaces through JNDI without knowing the protocol, host, port number and initial context properties specific to JBoss?
    Thanks,
    Eduardo.

  • How to configure JBoss for Oracle BPEL Process Manager

    an any body tell me , how to configure JBoss4.0.5 for Oracle BPEL Process Manager?

    http://download.oracle.com/docs/cd/E10291_01/doc.1013/e10538/toc.htm

  • How toremove messages from JMS Queue?how to configure queue in spring?

    Hi
    I have Confiured a JMS configaration in spring applicationConfiguaration.xml file
    <bean id="connectionFactory" class="org.apache.activemq.ActiveMQConnectionFactory">
              <property name="brokerURL" value="tcp://localhost:61616"/>
              <property name="useAsyncSend" value="true"/>
         </bean>
         <bean id="queue" class="org.apache.activemq.command.ActiveMQQueue">
         <constructor-arg value="foo"/>
    </bean>
         <bean id="broker" class="org.apache.activemq.xbean.BrokerFactoryBean">
              <property name="config" value="classpath:activemq.xml" />
              <property name="start" value="true" />
         <!--          <property name="messageListener" ref="auditInterface"/> -->
         </bean>
         <bean id="auditInterface"
              class="org.springframework.jms.remoting.JmsInvokerProxyFactoryBean">
    <property name="serviceInterface" value="com.infiniti.gpn.auditing.AuditInterface"/>
    <property name="connectionFactory" ref="connectionFactory"/>
    <property name="queue" ref="queue"/>
    </bean>
         <bean id="listenerContainer" class="org.springframework.jms.listener.SimpleMessageListenerContainer">
    <property name="connectionFactory" ref="connectionFactory"/>
    <property name="destination" ref="queue"/>
    <property name="messageListener" ref="auditMessageListener"/>
         </bean>
    Sender is sedning messages continusly messages that messages r storing in queue , these r acupying more memory in RAM , due to that jboss is restarting for each request, is there any way to clean up messages in Queue ? if it is there then how will configure that queue in apllicationConfiguaration.xml file?
    Thanks in advance
    Nara

    I suggest posting your question on the [Spring Remoting and JMX forum|http://forum.springframework.org/forumdisplay.php?f=30].

  • How to remove messages from JMS Queue?how to configure queue in spring?

    Hi
    I have Confiured a JMS configaration in spring applicationConfiguaration.xml file
    <bean id="connectionFactory" class="org.apache.activemq.ActiveMQConnectionFactory">
    <property name="brokerURL" value="tcp://localhost:61616"/>
    <property name="useAsyncSend" value="true"/>
    </bean>
    <bean id="queue" class="org.apache.activemq.command.ActiveMQQueue">
    <constructor-arg value="foo"/>
    </bean>
    <bean id="broker" class="org.apache.activemq.xbean.BrokerFactoryBean">
    <property name="config" value="classpath:activemq.xml" />
    <property name="start" value="true" />
    <!-- <property name="messageListener" ref="auditInterface"/> -->
    </bean>
    <bean id="auditInterface"
    class="org.springframework.jms.remoting.JmsInvokerProxyFactoryBean">
    <property name="serviceInterface" value="com.infiniti.gpn.auditing.AuditInterface"/>
    <property name="connectionFactory" ref="connectionFactory"/>
    <property name="queue" ref="queue"/>
    </bean>
    <bean id="listenerContainer" class="org.springframework.jms.listener.SimpleMessageListenerContainer">
    <property name="connectionFactory" ref="connectionFactory"/>
    <property name="destination" ref="queue"/>
    <property name="messageListener" ref="auditMessageListener"/>
    </bean>
    Sender is sedning messages continusly messages that messages r storing in queue , these r acupying more memory in RAM , due to that jboss is restarting for each request, is there any way to clean up messages in Queue ? if it is there then how will configure that queue in apllicationConfiguaration.xml file?
    Thanks in advance
    Nara

    Hi,
    Even i have a similar kind of requirement where in, i want to clear the JMS Queue Message programmatically, on certain condition.
    i am using Spring JMS. The JMS Queue has a listener. In the listener we want to clear the Queue contents based upon the condition.
    If anybody has any idea about this, please reply back.
    Thanks in Advance.
    Manjunath.

  • How to configure the smtp server..

    i had an error when running the java mail program..
    this is my program
    import javax.mail.*;
    import javax.mail.internet.*;
    import javax.activation.*;
    import java.io.*;
    import java.util.Properties;
    public class MailClient
    public void sendMail(String mailServer, String from, String to,
    String subject, String messageBody,
    String[] attachments) throws
    MessagingException, AddressException
    // Setup mail server
    Properties props = System.getProperties();
    props.put("mail.smtp.host", mailServer);
    // Get a mail session
    Session session = Session.getDefaultInstance(props, null);
    // Define a new mail message
    Message message = new MimeMessage(session);
    message.setFrom(new InternetAddress(from));
    message.addRecipient(Message.RecipientType.TO, new InternetAddress(to));
    message.setSubject(subject);
    // Create a message part to represent the body text
    BodyPart messageBodyPart = new MimeBodyPart();
    messageBodyPart.setText(messageBody);
    //use a MimeMultipart as we need to handle the file attachments
    Multipart multipart = new MimeMultipart();
    //add the message body to the mime message
    multipart.addBodyPart(messageBodyPart);
    // add any file attachments to the message
    // addAtachments(attachments, multipart);
    // Put all message parts in the message
    message.setContent(multipart);
    // Send the message
    Transport.send(message);
    protected void addAtachments(String[] attachments, Multipart multipart)
    throws MessagingException, AddressException
    for(int i = 0; i<= attachments.length -1; i++)
    String filename = attachments;
    MimeBodyPart attachmentBodyPart = new MimeBodyPart();
    //use a JAF FileDataSource as it does MIME type detection
    DataSource source = new FileDataSource(filename);
    attachmentBodyPart.setDataHandler(new DataHandler(source));
    //assume that the filename you want to send is the same as the
    //actual file name - could alter this to remove the file path
    attachmentBodyPart.setFileName(filename);
    //add the attachment
    multipart.addBodyPart(attachmentBodyPart);
    public static void main(String[] args)
    try
    MailClient client = new MailClient();
    String server="smtp.canvasindia.com";
    String from="[email protected]";
    String to = "[email protected]";
    String subject="Test";
    String message="Testing";
    String[] filenames ={"c:/A.java"};
    client.sendMail(server,from,to,subject,message,filenames);
    catch(Exception e)
    e.printStackTrace(System.out);
    the error is .................
    javax.mail.SendFailedException: Invalid Addresses;
    nested exception is:
    com.sun.mail.smtp.SMTPAddressFailedException: 553 Attack detected from p
    ool 59.144.8.116. <http://unblock.secureserver.net/?ip=59.144.8.*>
    at com.sun.mail.smtp.SMTPTransport.rcptTo(SMTPTransport.java:1196)
    at com.sun.mail.smtp.SMTPTransport.sendMessage(SMTPTransport.java:584)
    at javax.mail.Transport.send0(Transport.java:169)
    at javax.mail.Transport.send(Transport.java:98)
    at MailClient.sendMail(MailClient.java:47)
    at MailClient.main(MailClient.java:84)
    Caused by: com.sun.mail.smtp.SMTPAddressFailedException: 553 Attack detected fro
    m pool 59.144.8.116. <http://unblock.secureserver.net/?ip=59.144.8.*>
    at com.sun.mail.smtp.SMTPTransport.rcptTo(SMTPTransport.java:1047)
    ... 5 more
    how to configure the smtp server in my machine..
    please guide me...

    This uses gmail account, and gmail smtp
    * MailSender.java
    * Created on 14 November 2006, 17:07
    * This class is used to send mails to other users
    package jmailer;
    * @author Abubakar Gurnah
    import javax.mail.*;
    import javax.mail.internet.*;
    import java.util.*;
    public class MailSender{
        private String d_email,d_password;
         * This example is for gmail, you can use any smtp server
         * @param d_email --> your gmail account e.g. [email protected]
         * @param d_password  --> your gmail password
         * @param d_host --> smtp.gmail.com
         * @param d_port --> 465
         * @param m_to --> [email protected]
         * @param m_subject --> Subject of the message
         * @param m_text --> The main message body
        public String send(String d_email,String d_password,String d_host,String d_port,
                String m_from,String m_to,String m_subject,String m_text ) {
            this.d_email=d_email;
            this.d_password=d_password;
            Properties props = new Properties();
            props.put("mail.smtp.user", d_email);
            props.put("mail.smtp.host", d_host);
            props.put("mail.smtp.port", d_port);
            props.put("mail.smtp.starttls.enable","true");
            props.put("mail.smtp.auth", "true");
            //props.put("mail.smtp.debug", "true");
            props.put("mail.smtp.socketFactory.port", d_port);
            props.put("mail.smtp.socketFactory.class", "javax.net.ssl.SSLSocketFactory");
            props.put("mail.smtp.socketFactory.fallback", "false");
            SecurityManager security = System.getSecurityManager();
            try {
                Authenticator auth = new SMTPAuthenticator();
                Session session = Session.getInstance(props, auth);
                //session.setDebug(true);
                MimeMessage msg = new MimeMessage(session);
                msg.setText(m_text);
                msg.setSubject(m_subject);
                msg.setFrom(new InternetAddress(m_from));
                msg.addRecipient(Message.RecipientType.TO, new InternetAddress(m_to));
                Transport.send(msg);
                return "Successful";
            } catch (Exception mex) {
                mex.printStackTrace();
            return "Fail";
        //public static void main(String[] args) {
        //    MailSender blah = new MailSender();
        private class SMTPAuthenticator extends javax.mail.Authenticator {
            public PasswordAuthentication getPasswordAuthentication() {
                return new PasswordAuthentication(d_email, d_password);
    }

  • How to change datasource name based on the partition in configplan

    Hi
    Can any one please give me some solutions regarding how to change datasource name based on the partition in
    configplan.
    can't we do this in configuration plan?

    If you want to change template based on parameter. you have to use below syntax
    v_layout boolean
    V_LAYOUT:= FND_SUBMIT.add_layout(template_appl_name => 'SQLAP' -- application short name
    ,template_code => 'HUBAPAPN' -- template name
    ,template_language => 'en'
    ,template_territory => '00'
    ,output_format => 'PDF');
    Above can be used in plsql stored procedure before submitting Concurrent Program (Bi Publisher report) or may be you can try to add this code in Oracle reports after report or before report trigger
    Thanks
    Kamalakar

  • PLEASE : How to configure a QueueConnectionFactory

    I need to know how to configure a QueueConnectionFactory in jms.xml. I tried :
         <queue name="Queue proc" location="jms/movProcQueue">
              <description>A dummy queue</description>
         </queue>     
         <queue-connection-factory name="Queue Conn Factory" location="jms/movProcQueueConnectionFactory">
              <description>A dummy topic</description>
         </queue-connection-factory>
    but when i try to get it :
    QueueConnectionFactory conFactory =(QueueConnectionFactory) ctx.lookup("java:comp/env/jms/movProcQueueConnectionFactory");
    I get the following message:
    javax.naming.NameNotFoundException: jms/movProcQueueConnectionFactory not found in Application Client
    java.lang.Object com.evermind.naming.MapContext.lookup(java.lang.String) MapContext.java:49
    Please, I really need to know...

    Hi Marcelo,
    Obviously I can't speak for any one else on this forum -- but I'm not
    a mind reader. The lookup string you use depends on whether your queue
    client is also deployed to the OC4J container or not -- which you fail
    to mention (in fact you don't mention anything about your environment,
    this always helps -- me, at least :-)it's in the same machine (client and OC4J)
    Also, the type of InitialContext object you create also depends on your client type and how you deploy it.it'd the com.evermind.server.ApplicationClientInitialContextFactory
    So perhaps it would help you obtain an answer if you supplied the following:
    1. Platform (SUN, intel, etc.)Intel
    2. Operating system (UNIX, WinNT, linux, etc.)WinNT
    3. OC4J version (1.0.2.2.1?)R2
    4. Your JMS provider (OC4J, Swift, etc.)OC4J
    5. Your deployment descriptors (XML files).I really need to reference the QueueConnectionFactory and the QUeue itself int he application-client.xml file?
    mine:
    <?xml version="1.0"?>
    <!DOCTYPE application-client PUBLIC "-//Sun Microsystems, Inc.//DTD J2EE Application Client 1.2//EN" "http://java.sun.com/j2ee/dtds/application-client_1_2.dtd">
    <application-client>
         <resource-ref>
              <res-ref-name>jdbc/OracleDS</res-ref-name>
              <res-type>javax.sql.DataSource</res-type>
              <res-auth>Container</res-auth>
         </resource-ref>
         <resource-ref>
              <res-ref-name>jms/QueueConnectionFactory</res-ref-name>
              <res-type>jms.javax.jms.QueueConnectionFactory</res-type>
              <res-auth>Container</res-auth>
              <resource-env-ref-type>jms.javax.jms.Queue</resource-env-ref-type>     
         </resource-ref>     
         <resource-env-ref>
              <resource-env-ref-name>jms/Queue</resource-env-ref-name>
              <resource-env-ref-type>jms.javax.jms.Queue</resource-env-ref-type>
         </resource-env-ref>
    </application-client>
    6. Code showing how you are creating your "Context" object.InitialContext ctx=new InitialContext();
    // Lookup a JMS connection factory
    QueueConnectionFactory conFactory =(QueueConnectionFactory) ctx.lookup("java:comp/env/jms/QueueConnectionFactory");
    // Create a JMS connection
    QueueConnection connection = conFactory.createQueueConnection();
    // Create a JMS session object
    QueueSession session = connection.createQueueSession(true,0);
    // Lookup a JMS queue
    Queue queue= (Queue) ctx.lookup("java:comp/env/jms/Queue");
    // Create a JMS sender
    QueueSender sender = session.createSender(queue);
    Enumeration enum=vetor.elements();
    ObjectMessage message=null;
    while(enum.hasMoreElements())
    Movimento mov=(Movimento) enum.nextElement();
    message=session.createObjectMessage(mov);
    sender.send(message);
    //enviar mensagem de fim de processamento
    connection.close();
    Cheers,
    Avi.

Maybe you are looking for

  • No suggestion has worked for me to fix iTunes 10.2.1.1 upgrade!

    I upgraded my iTunes when prompted 2 days ago and thought nothing more of it until yesterday when I tried to launch iTunes in order to add more songs. (I am using Windows 7 btw). Whenever I clicked on the icon to open it nothing happened and before a

  • Streaming videos from Cloudfront in Captivate 6

    Hi, I'm really hoping someone out there can explain this to me in as simple a way as possible. I have a large project with 10 video files at various points throughout the course.  I've run some tests with the videos set to progressively download, but

  • Problem with Caller ID

    My caller ID is no longer working. All calls come up "Unknown". Any help with this would be appreciated.

  • Mixing down with MIDI

    How do I bounce mixes using MIDI instruments (Logic's internal Quicktime Synth) so that the audio from the MIDI instrument is included in the bounce? Help greatly appreciated! Jonathan

  • Open Configurator embedded in iStore directly from a weblink

    We have a requirement to embed the iStore product link in company website. The product is a configurable product, so within iStore, when we click on the product link, it opens up the Configurator model. So, when the user clicks on the weblink, the us