Codota Logo
AbstractCursorItemReader.cleanupOnClose
Code IndexAdd Codota to your IDE (free)

How to use
cleanupOnClose
method
in
org.springframework.batch.item.database.AbstractCursorItemReader

Best Java code snippets using org.springframework.batch.item.database.AbstractCursorItemReader.cleanupOnClose (Showing top 2 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
BufferedReader b =
  • Codota IconInputStream in;new BufferedReader(new InputStreamReader(in))
  • Codota IconReader in;new BufferedReader(in)
  • Codota IconFile file;new BufferedReader(new FileReader(file))
  • Smart code suggestions by Codota
}
origin: spring-projects/spring-batch

/**
 * Close the cursor and database connection. Make call to cleanupOnClose so sub classes can cleanup
 * any resources they have allocated.
 */
@Override
protected void doClose() throws Exception {
  initialized = false;
  JdbcUtils.closeResultSet(this.rs);
  rs = null;
  cleanupOnClose();
  if(this.con != null) {
    this.con.setAutoCommit(this.initialConnectionAutoCommit);
  }
  if (useSharedExtendedConnection && dataSource instanceof ExtendedConnectionDataSourceProxy) {
    ((ExtendedConnectionDataSourceProxy)dataSource).stopCloseSuppression(this.con);
    if (!TransactionSynchronizationManager.isActualTransactionActive()) {
      DataSourceUtils.releaseConnection(con, dataSource);
    }
  }
  else {
    JdbcUtils.closeConnection(this.con);
  }
}
origin: apache/servicemix-bundles

/**
 * Close the cursor and database connection. Make call to cleanupOnClose so sub classes can cleanup
 * any resources they have allocated.
 */
@Override
protected void doClose() throws Exception {
  initialized = false;
  JdbcUtils.closeResultSet(this.rs);
  rs = null;
  cleanupOnClose();
  if(this.con != null) {
    this.con.setAutoCommit(this.initialConnectionAutoCommit);
  }
  if (useSharedExtendedConnection && dataSource instanceof ExtendedConnectionDataSourceProxy) {
    ((ExtendedConnectionDataSourceProxy)dataSource).stopCloseSuppression(this.con);
    if (!TransactionSynchronizationManager.isActualTransactionActive()) {
      DataSourceUtils.releaseConnection(con, dataSource);
    }
  }
  else {
    JdbcUtils.closeConnection(this.con);
  }
}
org.springframework.batch.item.databaseAbstractCursorItemReadercleanupOnClose

Popular methods of AbstractCursorItemReader

  • afterPropertiesSet
  • close
  • getCurrentItemCount
  • getDataSource
    Public getter for the data source.
  • getExceptionTranslator
    Creates a default SQLErrorCodeSQLExceptionTranslator for the specified DataSource if none is set.
  • getSql
  • initializeConnection
  • moveCursorToRow
    Moves the cursor in the ResultSet to the position specified by the row parameter by traversing the R
  • openCursor
  • readCursor
    Read the cursor and map to the type of object this reader should return. This method must be overrid
  • verifyCursorPosition
    Check the result set is in sync with the currentRow attribute. This is important to ensure that the
  • verifyCursorPosition

Popular in Java

  • Parsing JSON documents to java classes using gson
  • scheduleAtFixedRate (Timer)
  • addToBackStack (FragmentTransaction)
  • startActivity (Activity)
  • Properties (java.util)
    The Properties class represents a persistent set of properties. The Properties can be saved to a st
  • ThreadPoolExecutor (java.util.concurrent)
    An ExecutorService that executes each submitted task using one of possibly several pooled threads, n
  • Annotation (javassist.bytecode.annotation)
    The annotation structure.An instance of this class is returned bygetAnnotations() in AnnotationsAttr
  • ServletException (javax.servlet)
    Defines a general exception a servlet can throw when it encounters difficulty.
  • JTable (javax.swing)
  • Runner (org.openjdk.jmh.runner)
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now