code: protected static void configureDataSource(final Context _compCtx,
                                                final String _classDSFactory,
                                                final Map<String, String> _propConnection)
          throws StartupException
      {
          final Reference ref = new Reference(DataSource.class.getName(), _classDSFactory, null);
          for (final Entry<String, String> entry : _propConnection.entrySet()) {
              ref.add(new StringRefAddr(entry.getKey(), entry.getValue()));
          }
          try {
              Util.bind(_compCtx, "env/" + INamingBinds.RESOURCE_DATASOURCE, ref);
              Util.bind(_compCtx, "test", ref);
          } catch (final NamingException e) {
              throw new StartupException("could not bind JDBC pooling class '" + _classDSFactory + "'", e);
              // CHECKSTYLE:OFF
          } catch (final Exception e) {
              // CHECKSTYLE:ON
              throw new StartupException("coud not get object instance of factory '" + _classDSFactory + "'", e);
          }
      }
docs: The class defined with parameter <code>_classDSFactory</code> initialized and bind to
  {@link #RESOURCE_DATASOURCE}. The initialized class must implement interface {@link DataSource}. As JDBC
  connection properties the map <code>_propConneciton</code> is used.
  
  @param _compCtx Java root naming context
  @param _classDSFactory class name of the SQL data source factory
  @param _propConnection map of properties for the JDBC connection
  @throws StartupException on error