Package org.apache.oozie.service

Examples of org.apache.oozie.service.JMSTopicService


    @Override
    protected JsonBean getJMSConnectionInfo(HttpServletRequest request, HttpServletResponse response)
            throws XServletException, IOException {
        Configuration conf = Services.get().getConf();
        JMSTopicService jmsTopicService = Services.get().get(JMSTopicService.class);
        String connectionProperties = conf.get(JMSJobEventListener.JMS_CONNECTION_PROPERTIES);
        if (connectionProperties == null) {
            throw new XServletException(HttpServletResponse.SC_BAD_REQUEST, ErrorCode.E1601,
                    "JMS connection property is not defined");
        }
        JMSConnectionInfoBean jmsBean = new JMSConnectionInfoBean();
        JMSConnectionInfo jmsInfo = new JMSConnectionInfo(connectionProperties);
        Properties jmsInfoProps = jmsInfo.getJNDIProperties();
        jmsInfoProps.remove("java.naming.security.principal");
        jmsBean.setJNDIProperties(jmsInfoProps);
        if (jmsTopicService != null) {
            jmsBean.setTopicPrefix(jmsTopicService.getTopicPrefix());
            jmsBean.setTopicPatternProperties(jmsTopicService.getTopicPatternProperties());
        }
        else {
            throw new XServletException(
                    HttpServletResponse.SC_BAD_REQUEST,
                    ErrorCode.E1601,
View Full Code Here


     * @param jobId job Id.
     * @return String the topic name
     * @throws DagEngineException thrown if the jms info could not be obtained.
     */
    public String getJMSTopicName(String jobId) throws DagEngineException {
        JMSTopicService jmsTopicService = Services.get().get(JMSTopicService.class);
        if (jmsTopicService != null) {
            try {
                return jmsTopicService.getTopic(jobId);
            }
            catch (JPAExecutorException e) {
               throw new DagEngineException(ErrorCode.E1602, e);
            }
        }
View Full Code Here

     * @param jobId job Id.
     * @return String the topic name
     * @throws DagEngineException thrown if the jms info could not be obtained.
     */
    public String getJMSTopicName(String jobId) throws DagEngineException {
        JMSTopicService jmsTopicService = Services.get().get(JMSTopicService.class);
        if (jmsTopicService != null) {
            try {
                return jmsTopicService.getTopic(jobId);
            }
            catch (JPAExecutorException e) {
               throw new DagEngineException(ErrorCode.E1602, e);
            }
        }
View Full Code Here

    @Override
    protected JsonBean getJMSConnectionInfo(HttpServletRequest request, HttpServletResponse response)
            throws XServletException, IOException {
        Configuration conf = Services.get().getConf();
        JMSTopicService jmsTopicService = Services.get().get(JMSTopicService.class);
        String connectionProperties = conf.get(JMSJobEventListener.JMS_CONNECTION_PROPERTIES);
        if (connectionProperties == null) {
            throw new XServletException(HttpServletResponse.SC_BAD_REQUEST, ErrorCode.E1601,
                    "JMS connection property is not defined");
        }
        JMSConnectionInfoBean jmsBean = new JMSConnectionInfoBean();
        JMSConnectionInfo jmsInfo = new JMSConnectionInfo(connectionProperties);
        Properties jmsInfoProps = jmsInfo.getJNDIProperties();
        jmsInfoProps.remove("java.naming.security.principal");
        jmsBean.setJNDIProperties(jmsInfoProps);
        if (jmsTopicService != null) {
            jmsBean.setTopicPrefix(jmsTopicService.getTopicPrefix());
            jmsBean.setTopicPatternProperties(jmsTopicService.getTopicPatternProperties());
        }
        else {
            throw new XServletException(
                    HttpServletResponse.SC_BAD_REQUEST,
                    ErrorCode.E1601,
View Full Code Here

TOP

Related Classes of org.apache.oozie.service.JMSTopicService

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.