Package org.apache.airavata.registry.api

Examples of org.apache.airavata.registry.api.AiravataUser


    private GFac getGfac()throws TException{
        try {
            return new BetterGfacImpl(registry, null,
                                AiravataRegistryFactory.getRegistry(new Gateway(getGatewayName()),
                                        new AiravataUser(getAiravataUserName())),zk,publisher);
        } catch (RegException e) {
            throw new TException("Error initializing gfac instance",e);
        } catch (AiravataConfigurationException e) {
            throw new TException("Error initializing gfac instance",e);
        }
View Full Code Here


//            e.printStackTrace();
//        }
        try {
          username=ServerSettings.getSystemUser();
            registry = AiravataRegistryFactory.getRegistry(new Gateway(ServerSettings.getSystemUserGateway()),
                    new AiravataUser(username));
        } catch (AiravataConfigurationException e) {
            log.error("Error initializing AiravataRegistry2");
        } catch (RegAccessorNotFoundException e) {
            log.error("Error initializing AiravataRegistry2");
        } catch (RegAccessorInstantiateException e) {
View Full Code Here

    private GFac getGfac()throws TException{
        try {
            return new GFacImpl(registry, null,
                                AiravataRegistryFactory.getRegistry(new Gateway(getGatewayName()),
                                        new AiravataUser(getAiravataUserName())));
        } catch (RegException e) {
            throw new TException("Error initializing gfac instance",e);
        } catch (AiravataConfigurationException e) {
            throw new TException("Error initializing gfac instance",e);
        }
View Full Code Here

    private static final Logger logger = LoggerFactory.getLogger(AiravataServerHandler.class);

  AiravataRegistry2 registry;
  private AiravataRegistry2 getRegistry() throws RegException, AiravataConfigurationException{
     if (registry==null){
       registry = AiravataRegistryFactory.getRegistry(new Gateway("default"), new AiravataUser("admin"));
     }
    return registry;
  }
View Full Code Here

        try {
            /* Initializing the OrchestratorConfiguration object */
          orchestratorConfiguration = OrchestratorUtils.loadOrchestratorConfiguration();
            setGatewayProperties();
            /* initializing the Orchestratorcontext object */
            airavataRegistry = AiravataRegistryFactory.getRegistry(new Gateway(getGatewayName()), new AiravataUser(getAiravataUserName()));
            // todo move this code to gfac service mode Jobsubmitter,
            // todo this is ugly, SHOULD fix these isEmbedded mode code from Orchestrator
            if (!orchestratorConfiguration.isEmbeddedMode()) {
                Map<String, Integer> gfacNodeList = airavataRegistry.getGFACNodeList();
                if (gfacNodeList.size() == 0) {
View Full Code Here

  public static AiravataRegistry2 getRegistry(URI registryURI,
      String gateway, String username, PasswordCallback callback)
      throws RegException, AiravataConfigurationException {
    return AiravataRegistryFactory.getRegistry(registryURI, new Gateway(
        gateway), new AiravataUser(username), callback);
  }
View Full Code Here

  private AiravataExperiment createAiravataExperimentObj(
      ExperimentResource resource) {
    AiravataExperiment e = new AiravataExperiment();
    e.setExperimentId(resource.getExpID());
    e.setUser(new AiravataUser(resource.getWorker().getUser()));
    e.setSubmittedDate(new Date(resource.getSubmittedDate().getTime()));
    e.setGateway(new Gateway(resource.getGateway().getGatewayName()));
    e.setProject(new WorkspaceProject(getProjName(resource.getProject().getName()), this));
    return e;
  }
View Full Code Here

    }
    List<AiravataUser> result=new ArrayList<AiravataUser>();
       List<Resource> users = jpa.getGateway().get(ResourceType.USER);
       for (Resource resource : users) {
        UserResource userRes = (UserResource) resource;
        AiravataUser user = new AiravataUser(userRes.getUserName());
      result.add(user);
    }
       return result;
  }
View Full Code Here

        AiravataRegistry2 airavataRegistry = RegPoolUtils.acquireRegistry(context);
        try {
            AiravataExperiment experiment = new AiravataExperiment();
            experiment.setExperimentId(experimentID);
            Gateway gateway = airavataRegistry.getGateway();
            AiravataUser airavataUser = airavataRegistry.getAiravataUser();
            experiment.setGateway(gateway);
            experiment.setUser(airavataUser);
            DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
            Date formattedDate = dateFormat.parse(submittedDate);
            experiment.setSubmittedDate(formattedDate);
View Full Code Here

    @Path(ResourcePathConstants.BasicRegistryConstants.GET_USER)
    @Produces({MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML})
    public Response getAiravataUser() {
        AiravataRegistry2 airavataRegistry = RegPoolUtils.acquireRegistry(context);
        try {
            AiravataUser airavataUser = airavataRegistry.getAiravataUser();
            if (airavataUser != null) {
                Response.ResponseBuilder builder = Response.status(Response.Status.OK);
                builder.entity(airavataUser);
                return builder.build();
            } else {
View Full Code Here

TOP

Related Classes of org.apache.airavata.registry.api.AiravataUser

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.