Package org.apache.airavata.persistance.registry.jpa.model

Examples of org.apache.airavata.persistance.registry.jpa.model.Configuration_PK


        Lock lock = ResourceUtils.getLock();
        lock.lock();
        try {
            EntityManager em = ResourceUtils.getEntityManager();
            //whether existing
            Configuration existing = em.find(Configuration.class, new Configuration_PK(configKey, configVal, categoryID));
            em.close();

            em = ResourceUtils.getEntityManager();
            em.getTransaction().begin();
            Configuration configuration = new Configuration();
View Full Code Here


        Lock lock = ResourceUtils.getLock();
        lock.lock();
        try {
            EntityManager em = ResourceUtils.getEntityManager();
            //whether existing
            Configuration existing = em.find(Configuration.class, new Configuration_PK(configKey, configVal));
            em.close();

            em = ResourceUtils.getEntityManager();
            em.getTransaction().begin();
            Configuration configuration = new Configuration();
View Full Code Here

    public synchronized void save() throws RegistryException {
        EntityManager em = null;
        try {
            em = ResourceUtils.getEntityManager();
            //whether existing
            Configuration existing = em.find(Configuration.class, new Configuration_PK(configKey, configVal, categoryID));
            em.close();
            em = ResourceUtils.getEntityManager();
            em.getTransaction().begin();
            Configuration configuration = new Configuration();
            configuration.setConfig_key(configKey);
View Full Code Here

    public static boolean isConfigurationExists(String configKey, String configVal){
        try{
            //Currently categoryID is hardcoded value
            EntityManager em = ResourceUtils.getEntityManager();
            Configuration existing = em.find(Configuration.class, new Configuration_PK(configKey, configVal, AbstractResource.ConfigurationConstants.CATEGORY_ID_DEFAULT_VALUE));
            em.close();
            return existing!= null;
        } catch (Exception e){
            logger.error(e.getMessage(), e);
            throw new EntityNotFoundException();
View Full Code Here

TOP

Related Classes of org.apache.airavata.persistance.registry.jpa.model.Configuration_PK

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.