Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 402999
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T17:10:35+00:00 2026-05-12T17:10:35+00:00

i have an spring web application (on glassfish server) that use JDBC connection pool.

  • 0

i have an spring web application (on glassfish server) that use JDBC connection pool. It defined in XML file like this:

<resources>
    <jdbc-connection-pool allow-non-component-callers="true" associate-with-thread="true"
                          connection-creation-retry-attempts="2" connection-creation-retry-interval-in-seconds="10" connection-leak-reclaim="false"
                          connection-leak-timeout-in-seconds="0" connection-validation-method="table" datasource-classname="oracle.jdbc.pool.OracleConnectionPoolDataSource"
                          fail-all-connections="false" idle-timeout-in-seconds="2147483638" is-connection-validation-required="true"
                          is-isolation-level-guaranteed="false" lazy-connection-association="true" lazy-connection-enlistment="true"
                          match-connections="false" max-connection-usage-count="0" max-pool-size="60" max-wait-time-in-millis="60000"
                          name="company.jdbc.sc.nonxa.pool" non-transactional-connections="false" pool-resize-quantity="2"
                          res-type="javax.sql.ConnectionPoolDataSource" statement-timeout-in-seconds="300" steady-pool-size="16"
                          transaction-isolation-level="read-committed" validate-atmost-once-period-in-seconds="1" validation-table-name="SC_VALIDATE"
                          wrap-jdbc-objects="false">
        <property name="DataSourceName" value="OracleNonXADataSource"/>
        <property name="ImplicitCachingEnabled" value="false"/>
        <property name="NetworkProtocol" value="tcp"/>
        <property name="Password" value="password"/>
        <property name="LoginTimeout" value="0"/>
        <property name="URL" value="jdbc:oracle:thin:@oradbdev.company.ru:1521:COMPANY"/>
        <property name="NativeXA" value="false"/>
        <property name="User" value="prog10"/>
        <property name="ExplicitCachingEnabled" value="false"/>
        <property name="PortNumber" value="0"/>
        <property name="MaxStatements" value="0"/>
    </jdbc-connection-pool>
    <jdbc-resource enabled="true" jndi-name="company.jdbc.sc.nonxa.db" object-type="user" pool-name="company.jdbc.sc.nonxa.pool"/>
</resources>

And now i need to start application inside embedded Jetty server for integration test.
I’m trying to add connection pool in jetty.xml file like this:

<New id="DS" class="org.mortbay.jetty.plus.naming.Resource">
    <Arg>
        <Ref id="wac"/>
    </Arg>
    <Arg>jdbc/DS</Arg>
    <Arg>
        <New class="oracle.jdbc.pool.OracleConnectionPoolDataSource">
            <Set name="DataSourceName">OracleNonXADataSource</Set>
            <Set name="ImplicitCachingEnabled">false</Set>
            <Set name="NetworkProtocol">tcp</Set>
            <Set name="Password">password</Set>
            <Set name="LoginTimeout">0</Set>
            <Set name="URL">jdbc:oracle:thin:@oradbdev.company.ru:1521:COMPANY</Set>
            <Set name="NativeXA">false</Set>
            <Set name="User">prog10</Set>
            <Set name="ExplicitCachingEnabled">false</Set>
            <Set name="PortNumber">0</Set>
            <Set name="MaxStatements">0</Set>
        </New>
    </Arg>
</New>

It register connection pool, but i also nee to register jdbc-resource with given name.

How i can to do that?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T17:10:36+00:00Added an answer on May 12, 2026 at 5:10 pm

    With Jetty, you set the JNDI name of the connection pool in the configuration (here, jdbc/DS). So why would you need to register a “jdbc-resource”? This seems to be a specific step to GlassFish.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a Spring Web MVC application that I'd like to serve a large,
I have a java web application that use spring security for log in users,
I have a web application using JPA and JTA with Spring. I would like
i have a JSF web application. I use Beans as Spring Beans (not JSF
I have a spring web application (currently packaged as a war file) which I
I have a spring web application that is required to work as following the
So I have a spring mvc web application that I built in IntelliJ 9,
I have a spring application that has configured log4j (via xml) and that runs
I have a spring web application with jsp pages that calls different web services
I have a Spring Web MVC application where i need to use an external

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.