All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.macronova.kafka.connect.jms.common.JmsDialect Maven / Gradle / Ivy

The newest version!
/*
 * Copyright 2018 Macronova.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package io.macronova.kafka.connect.jms.common;

import java.util.Map;
import javax.jms.ConnectionFactory;

/**
 * JmsDialect controls behavior specific to given JMS server.
 */
public interface JmsDialect {
	/**
	 * Instantiate JMS connection factory.
	 *
	 * @param config Connector configuration. Only connectivity-related parameters available. User may register
	 *               custom properties whit {@code jms.dialect.} prefix.
	 * @return JMS connection factory.
	 * @throws Exception Indicates error.
	 */
	ConnectionFactory createConnectionFactory(Map config) throws Exception;

	/**
	 * @param e Encountered exception.
	 * @return {@code true} if connector should re-establish connectivity upon given error, {@code false} otherwise.
	 */
	boolean reconnectOnError(Exception e);
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy