IBM webMethods Hybrid Integration

IBM webMethods Hybrid Integration

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.



#Automation


#Applicationintegration
#webMethods
#Integration
 View Only
  • 1.  Error Handling using Database Connector

    Posted 03/27/09 05:07 PM

    Hello:

    I’m using a database connector to handle a set of database operations (inserts, updates, etc) in database tables.

    The operations are handled through code, I need to catch SQL errors and handle them in code.

    The question is: what are the best practices for handling this kind of errors while using the database connector ? I see that you have a getErrorHandler, setErrorHandler methods in RowSetTableContentProvider that uses an IErrorHandler;
    on the other hand you have DbClientErrorHandler class that contains a set of methods to handle this kind of errors.

    How you use these methods together ?

    Thanks
    Edgardo


    #MWS-CAF-Task-Engine
    #webMethods-BPMS
    #webMethods


  • 2.  RE: Error Handling using Database Connector

    Posted 04/06/09 07:14 PM

    If you are using RowSetTableContentProvider to run your sql. Then you can add a DbClientErrorHandler bean to your page bean and set binding of RowSetTableContentProvider.errorHandler to point to this error handler bean. Then any error occurred inside provider methods will be delegated to the handler (you can also provider implementation of you own handler via interface).

    You can take a look at the /samples/caf/wm_coreproviderstest. Look for view/ErrorHandling folder.

    Samples source code is available for download from http://www.ajax-softwareag.com


    #webMethods-BPMS
    #webMethods
    #MWS-CAF-Task-Engine


  • 3.  RE: Error Handling using Database Connector

    Posted 04/10/09 09:46 PM

    Thanks Alex:

    I used the approach to create a class inside the page bean inheriting DbClientErrorHandler. Then use the handleError method to do the error handling.

    It worked nicely
    Edgardo


    #webMethods
    #MWS-CAF-Task-Engine
    #webMethods-BPMS