Class DirectQuerySender
java.lang.Object
org.frankframework.jdbc.JdbcFacade
org.frankframework.jdbc.AbstractJdbcSender<Connection>
org.frankframework.jdbc.AbstractJdbcQuerySender<Connection>
org.frankframework.jdbc.DirectQuerySender
- All Implemented Interfaces:
FrankElement, HasApplicationContext, HasName, HasPhysicalDestination, IBlockEnabledSender<Connection>, IConfigurable, IScopeProvider, ISender, ISenderWithParameters, IWithParameters, IXAEnabled, NameAware, ConfigurableLifecycle, org.springframework.beans.factory.Aware, org.springframework.context.ApplicationContextAware, org.springframework.context.Lifecycle, org.springframework.context.Phased, org.springframework.context.SmartLifecycle
- Direct Known Subclasses:
JdbcIteratingPipeBase.MixedQuerySender, XmlQuerySender
QuerySender that interprets the input message as a query, possibly with attributes.
Messages are expected to contain sql-text.
- Since:
- 4.1
- Author:
- Gerrit van Brakel
- Parameters
- All parameters present are applied to the query to be executed.
-
Nested Class Summary
Nested classes/interfaces inherited from class AbstractJdbcQuerySender
AbstractJdbcQuerySender.QueryType -
Field Summary
Fields inherited from class AbstractJdbcQuerySender
UNP_END, UNP_STARTFields inherited from class AbstractJdbcSender
connection, paramListFields inherited from class JdbcFacade
logFields inherited from interface org.springframework.context.SmartLifecycle
DEFAULT_PHASE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcloseBlock(Connection connection, PipeLineSession session) close the resource that is opened byIBlockEnabledSender.openBlock(PipeLineSession).protected voidcloseConnectionForSendMessage(Connection connection, PipeLineSession session) voidConfigure this component.voidconfigure(boolean ignoreSQLInjectionWarning) voidprotected StringObtain a query to be executed.openBlock(PipeLineSession session) open a resource that can be used multiple times whenIBlockEnabledSender.sendMessage(Object, Message, PipeLineSession)is called.protected QueryExecutionContextprepareStatementSet(Connection connection, Message message) sendMessage(Connection connection, Message message, PipeLineSession session) Methods inherited from class AbstractJdbcQuerySender
adjustQueryAndParameterListForNamedParameters, buildDb2XMLWriter, closeStatementSet, convertQuery, executeOtherQuery, executeOtherQuery, executePackageQuery, executeSelectQuery, executeStatementSet, executeUpdateBlobQuery, executeUpdateClobQuery, fillParamArray, getBatchSize, getCallWithRowIdReturned, getConnectionForSendMessage, getQueryExecutionContext, getResult, getReturnedColumns, getStatement, getUpdateStatementResult, prepareQuery, prepareQueryWithColumnsReturned, prepareQueryWithResultSet, setAvoidLocking, setBlobBase64Direction, setBlobCharset, setBlobColumn, setBlobsCompressed, setBlobSessionKey, setBlobSmartGet, setClobColumn, setClobSessionKey, setColumnsReturned, setIncludeFieldDefinition, setLockRows, setLockWait, setMaxRows, setNullValue, setOutputFormat, setPackageContent, setPrettyPrint, setQueryType, setResultQuery, setRowIdSessionKey, setScalar, setScalarExtended, setSqlDialect, setStartRow, setStreamCharset, setSynchronous, setTrimSpaces, setUseNamedParams, startMethods inherited from class AbstractJdbcSender
addParameter, getConnection, getParameterList, sendMessage, setTimeout, stop, toStringMethods inherited from class JdbcFacade
getConnectionWithTimeout, getDatasource, getDatasourceName, getDbmsSupport, getLogPrefix, getPassword, getPhysicalDestinationName, isConnectionsArePooled, isRunning, isTransacted, setAuthAlias, setConnectionsArePooled, setDatasourceName, setDbmsSupportFactory, setName, setPassword, setTransacted, setUsernameMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.springframework.context.ApplicationContextAware
setApplicationContextMethods inherited from interface ConfigurableLifecycle
getPhase, isAutoStartup, isConfiguredMethods inherited from interface FrankElement
addConfigWarningMethods inherited from interface HasApplicationContext
getApplicationContext, getConfigurationClassLoaderMethods inherited from interface ISender
isSynchronous, sendMessageOrThrowMethods inherited from interface ISenderWithParameters
consumesSessionVariableMethods inherited from interface org.springframework.context.SmartLifecycle
isPauseable, stop
-
Constructor Details
-
DirectQuerySender
public DirectQuerySender()
-
-
Method Details
-
configure
Description copied from interface:IConfigurableConfigure this component.configure()is called once at startup of the framework in the configure method of the owner of thisIConfigurable. Purpose of this method is to check whether the static configuration of the object is correct. As much as possible class-instantiating should take place in theconfigure(), to improve performance.In the case of a container, this will propagate the configure signal to all components that apply.
- Specified by:
configurein interfaceIConfigurable- Overrides:
configurein classAbstractJdbcQuerySender<Connection>- Throws:
ConfigurationException- in case it was not able to configure the component.
-
configure
- Throws:
ConfigurationException
-
configure
- Throws:
ConfigurationException
-
getQuery
Description copied from class:AbstractJdbcQuerySenderObtain a query to be executed. Method-stub to be overridden in descender-classes.- Specified by:
getQueryin classAbstractJdbcQuerySender<Connection>- Throws:
SenderException
-
openBlock
Description copied from interface:IBlockEnabledSenderopen a resource that can be used multiple times whenIBlockEnabledSender.sendMessage(Object, Message, PipeLineSession)is called.- Throws:
SenderExceptionTimeoutException
-
closeBlock
Description copied from interface:IBlockEnabledSenderclose the resource that is opened byIBlockEnabledSender.openBlock(PipeLineSession). It is important that this method is always called after processing with the blockHandle ends. It should effectively be called in a finally clause of a try around the openBlock.- Throws:
SenderException
-
closeConnectionForSendMessage
- Overrides:
closeConnectionForSendMessagein classAbstractJdbcQuerySender<Connection>
-
sendMessage
public SenderResult sendMessage(Connection connection, Message message, PipeLineSession session) throws SenderException, TimeoutException - Throws:
SenderExceptionTimeoutException
-
prepareStatementSet
protected QueryExecutionContext prepareStatementSet(Connection connection, Message message) throws SenderException - Throws:
SenderException
-