@ -60,11 +60,6 @@ public class ProcedureTask extends AbstractTask {
* /
* /
private ProcessService processService ;
private ProcessService processService ;
/ * *
* base datasource
* /
private BaseDataSource baseDataSource ;
/ * *
/ * *
* constructor
* constructor
* @param taskProps task props
* @param taskProps task props
@ -117,7 +112,7 @@ public class ProcedureTask extends AbstractTask {
// load class
// load class
DataSourceFactory . loadClass ( dataSource . getType ( ) ) ;
DataSourceFactory . loadClass ( dataSource . getType ( ) ) ;
// get datasource
// get datasource
baseDataSource = DataSourceFactory . getDatasource ( dataSource . getType ( ) ,
BaseDataSource baseDataSource = DataSourceFactory . getDatasource ( dataSource . getType ( ) ,
dataSource . getConnectionParams ( ) ) ;
dataSource . getConnectionParams ( ) ) ;
// get jdbc connection
// get jdbc connection
@ -163,7 +158,7 @@ public class ProcedureTask extends AbstractTask {
stmt . setQueryTimeout ( taskProps . getTaskTimeout ( ) ) ;
stmt . setQueryTimeout ( taskProps . getTaskTimeout ( ) ) ;
}
}
Map < Integer , Property > outParameterMap = new HashMap < > ( ) ;
Map < Integer , Property > outParameterMap = new HashMap < > ( ) ;
if ( userDefParamsList ! = null & & userDefParamsList . size ( ) > 0 ) {
if ( CollectionUtils . isNotEmpty ( userDefParamsList ) ) {
int index = 1 ;
int index = 1 ;
for ( Property property : userDefParamsList ) {
for ( Property property : userDefParamsList ) {
logger . info ( "localParams : prop : {} , dirct : {} , type : {} , value : {}"
logger . info ( "localParams : prop : {} , dirct : {} , type : {} , value : {}"
@ -237,31 +232,31 @@ public class ProcedureTask extends AbstractTask {
private void getOutputParameter ( CallableStatement stmt , int index , String prop , DataType dataType ) throws SQLException {
private void getOutputParameter ( CallableStatement stmt , int index , String prop , DataType dataType ) throws SQLException {
switch ( dataType ) {
switch ( dataType ) {
case VARCHAR :
case VARCHAR :
logger . info ( "out prameter key : {} , value : {}" , prop , stmt . getString ( index ) ) ;
logger . info ( "out prameter varchar key : {} , value : {}" , prop , stmt . getString ( index ) ) ;
break ;
break ;
case INTEGER :
case INTEGER :
logger . info ( "out prameter key : {} , value : {}" , prop , stmt . getInt ( index ) ) ;
logger . info ( "out prameter integer key : {} , value : {}" , prop , stmt . getInt ( index ) ) ;
break ;
break ;
case LONG :
case LONG :
logger . info ( "out prameter key : {} , value : {}" , prop , stmt . getLong ( index ) ) ;
logger . info ( "out prameter long key : {} , value : {}" , prop , stmt . getLong ( index ) ) ;
break ;
break ;
case FLOAT :
case FLOAT :
logger . info ( "out prameter key : {} , value : {}" , prop , stmt . getFloat ( index ) ) ;
logger . info ( "out prameter float key : {} , value : {}" , prop , stmt . getFloat ( index ) ) ;
break ;
break ;
case DOUBLE :
case DOUBLE :
logger . info ( "out prameter key : {} , value : {}" , prop , stmt . getDouble ( index ) ) ;
logger . info ( "out prameter double key : {} , value : {}" , prop , stmt . getDouble ( index ) ) ;
break ;
break ;
case DATE :
case DATE :
logger . info ( "out prameter key : {} , value : {}" , prop , stmt . getDate ( index ) ) ;
logger . info ( "out prameter date key : {} , value : {}" , prop , stmt . getDate ( index ) ) ;
break ;
break ;
case TIME :
case TIME :
logger . info ( "out prameter key : {} , value : {}" , prop , stmt . getTime ( index ) ) ;
logger . info ( "out prameter time key : {} , value : {}" , prop , stmt . getTime ( index ) ) ;
break ;
break ;
case TIMESTAMP :
case TIMESTAMP :
logger . info ( "out prameter key : {} , value : {}" , prop , stmt . getTimestamp ( index ) ) ;
logger . info ( "out prameter timestamp key : {} , value : {}" , prop , stmt . getTimestamp ( index ) ) ;
break ;
break ;
case BOOLEAN :
case BOOLEAN :
logger . info ( "out prameter key : {} , value : {}" , prop , stmt . getBoolean ( index ) ) ;
logger . info ( "out prameter boolean key : {} , value : {}" , prop , stmt . getBoolean ( index ) ) ;
break ;
break ;
default :
default :
break ;
break ;