code: public Connection getConnection() {
          try {
              Connection conn = threadLocal.get();
  
              if(conn == null){
                  conn = xaDataSource.getXAConnection().getConnection();
                  threadLocal.set(conn);
                  logger.info("Get Connection from DataSource.");
              }
  
              return conn;
  
          } catch(SQLException ex){
              throw new SQLRuntimeException(ex);
          }
      }
docs: {@inheritDoc}