Examples of deleteQuery()


Examples of org.apache.airavata.persistance.registry.jpa.utils.QueryGenerator.deleteQuery()

                break;
            case HOST_DESCRIPTOR:
                generator = new QueryGenerator(HOST_DESCRIPTOR);
                generator.setParameter(HostDescriptorConstants.HOST_DESC_ID, name);
                generator.setParameter(HostDescriptorConstants.GATEWAY_NAME, gatewayName);
                q = generator.deleteQuery(em);
                q.executeUpdate();
                break;
            case SERVICE_DESCRIPTOR:
                generator = new QueryGenerator(SERVICE_DESCRIPTOR);
                generator.setParameter(ServiceDescriptorConstants.SERVICE_DESC_ID, name);
View Full Code Here

Examples of org.apache.airavata.persistance.registry.jpa.utils.QueryGenerator.deleteQuery()

                break;
            case SERVICE_DESCRIPTOR:
                generator = new QueryGenerator(SERVICE_DESCRIPTOR);
                generator.setParameter(ServiceDescriptorConstants.SERVICE_DESC_ID, name);
                generator.setParameter(ServiceDescriptorConstants.GATEWAY_NAME, gatewayName);
                q = generator.deleteQuery(em);
                q.executeUpdate();
                break;
            case EXPERIMENT:
                generator = new QueryGenerator(EXPERIMENT);
                generator.setParameter(ExperimentConstants.EXPERIMENT_ID, name);
View Full Code Here

Examples of org.apache.airavata.persistance.registry.jpa.utils.QueryGenerator.deleteQuery()

                break;
            case EXPERIMENT:
                generator = new QueryGenerator(EXPERIMENT);
                generator.setParameter(ExperimentConstants.EXPERIMENT_ID, name);
                generator.setParameter(ExperimentConstants.GATEWAY_NAME, gatewayName);
                q = generator.deleteQuery(em);
                q.executeUpdate();
                break;
            case APPLICATION_DESCRIPTOR:
                generator = new QueryGenerator(APPLICATION_DESCRIPTOR);
                generator.setParameter(ApplicationDescriptorConstants.APPLICATION_DESC_ID, name);
View Full Code Here

Examples of org.apache.airavata.persistance.registry.jpa.utils.QueryGenerator.deleteQuery()

                break;
            case APPLICATION_DESCRIPTOR:
                generator = new QueryGenerator(APPLICATION_DESCRIPTOR);
                generator.setParameter(ApplicationDescriptorConstants.APPLICATION_DESC_ID, name);
                generator.setParameter(ApplicationDescriptorConstants.GATEWAY_NAME, gatewayName);
                q = generator.deleteQuery(em);
                q.executeUpdate();
                break;
            default:
                logger.error("Unsupported resource type for gateway resource.", new IllegalArgumentException());
                break;
View Full Code Here

Examples of org.apache.airavata.persistance.registry.jpa.utils.QueryGenerator.deleteQuery()

        switch (type){
            case NODE_DATA:
                generator = new QueryGenerator(NODE_DATA);
                generator.setParameter(NodeDataConstants.WORKFLOW_INSTANCE_ID, workflowInstanceID);
                generator.setParameter(NodeDataConstants.NODE_ID, name);
                q = generator.deleteQuery(em);
                q.executeUpdate();
                break;
            case GRAM_DATA:
                generator = new QueryGenerator(GRAM_DATA);
                generator.setParameter(GramDataConstants.WORKFLOW_INSTANCE_ID, workflowInstanceID);
View Full Code Here

Examples of org.apache.airavata.persistance.registry.jpa.utils.QueryGenerator.deleteQuery()

                break;
            case GRAM_DATA:
                generator = new QueryGenerator(GRAM_DATA);
                generator.setParameter(GramDataConstants.WORKFLOW_INSTANCE_ID, workflowInstanceID);
                generator.setParameter(GramDataConstants.NODE_ID, name);
                q = generator.deleteQuery(em);
                q.executeUpdate();
                break;
            default:
                logger.error("Unsupported resource type for workflow data resource.", new IllegalArgumentException());
                break;
View Full Code Here

Examples of org.apache.airavata.persistance.registry.jpa.utils.QueryGenerator.deleteQuery()

        QueryGenerator generator;
        switch (type){
            case EXPERIMENT_DATA:
                generator = new QueryGenerator(EXPERIMENT_DATA);
                generator.setParameter(ExperimentDataConstants.EXPERIMENT_ID, name);
                q = generator.deleteQuery(em);
                q.executeUpdate();
                break;
        }
        em.getTransaction().commit();
        em.close();
View Full Code Here

Examples of org.apache.airavata.persistance.registry.jpa.utils.QueryGenerator.deleteQuery()

        try {
            EntityManager em = getEntityManager();
            em.getTransaction().begin();
            QueryGenerator generator = new QueryGenerator(AbstractResource.GATEWAY);
            generator.setParameter(AbstractResource.GatewayConstants.GATEWAY_NAME, gatewayName);
            Query q = generator.deleteQuery(em);
            q.executeUpdate();
            em.getTransaction().commit();
            em.close();
            return true;
        } catch (Exception e) {
View Full Code Here

Examples of org.apache.airavata.persistance.registry.jpa.utils.QueryGenerator.deleteQuery()

            em.getTransaction().begin();
            QueryGenerator generator = new QueryGenerator(AbstractResource.GATEWAY_WORKER);
            generator.setParameter(AbstractResource.GatewayWorkerConstants.GATEWAY_NAME,
                    gatewayResource.getGatewayName());
            generator.setParameter(AbstractResource.UserConstants.USERNAME, userResource.getUserName());
            Query q = generator.deleteQuery(em);
            q.executeUpdate();
            em.getTransaction().commit();
            em.close();
            return true;
        } catch (Exception e) {
View Full Code Here

Examples of org.apache.airavata.persistance.registry.jpa.utils.QueryGenerator.deleteQuery()

        queryGenerator.setParameter(AbstractResource.ConfigurationConstants.CONFIG_KEY, configkey);
        queryGenerator.setParameter(AbstractResource.ConfigurationConstants.CONFIG_VAL, configValue);
        if(isConfigurationExists(configkey, configValue)){
            EntityManager em = getEntityManager();
            em.getTransaction().begin();
            Query q = queryGenerator.deleteQuery(em);
            q.executeUpdate();
            em.getTransaction().commit();
            em.close();
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.