Package org.cloudfoundry.ide.eclipse.server.core.internal.client

Examples of org.cloudfoundry.ide.eclipse.server.core.internal.client.CloudFoundryServerBehaviour$StopApplicationOperation


      runAsynchWithWizardProgress(new ICoreRunnable() {

        @Override
        public void run(IProgressMonitor monitor) throws CoreException {

          CloudFoundryServerBehaviour behaviour = server.getBehaviour();

          List<CloudDomain> domains = behaviour.getDomainsForSpace(monitor);

          final List<CloudRoute> allRoutes = new ArrayList<CloudRoute>();

          if (domains != null) {
            for (CloudDomain domain : domains) {

              List<CloudRoute> routes = behaviour.getRoutes(domain.getName(), monitor);
              if (routes != null) {
                allRoutes.addAll(routes);

                // Note that fetching routes per domain may be a
                // long running process.
View Full Code Here


    }
    this.consoleDescriptor = descriptor;

    if (loggregatorToken == null) {

      CloudFoundryServerBehaviour behaviour = consoleDescriptor.getCloudServer().getBehaviour();

      // This token represents the loggregator connection.
      loggregatorToken = behaviour.addApplicationLogListener(consoleDescriptor.getCloudApplicationModule()
          .getDeployedApplicationName(), new ApplicationLogConsoleListener());

    }
  }
View Full Code Here

          connect = space.getOrgName().equals(originalSpace.getOrgName())
              && space.getSpaceName().equals(originalSpace.getSpaceName());
        }

        if (connect) {
          CloudFoundryServerBehaviour behaviour = cf.getBehaviour();
          if (behaviour != null) {
            try {
              behaviour.connect(monitor);
            }
            catch (CoreException e) {
              CloudFoundryServerUiPlugin.getDefault().getLog().log(e.getStatus());
            }
          }
View Full Code Here

      // When the page is visible, populate the page
      runAsynchWithWizardProgress(new ICoreRunnable() {
        @Override
        public void run(IProgressMonitor monitor) throws CoreException {
          if (server != null){
            CloudFoundryServerBehaviour behaviour = server.getBehaviour();
            if (behaviour != null){
              monitor.beginTask(Messages.MANAGE_SERVICES_TO_APPLICATIONS_GET_APPLICATION_NAMES,
                  IProgressMonitor.UNKNOWN);
              final List<CloudApplication> allApps = behaviour.getApplications(monitor);   
                       
              monitor.done();
              Display.getDefault().syncExec(new Runnable() {
                public void run() {
                  serviceToApplicationsBindingPart.setInput(allApps);
View Full Code Here

      try {
        CloudUiUtil.runForked(new ICoreRunnable() {
          @Override
          public void run(IProgressMonitor monitor) throws CoreException {
            monitor.setTaskName(Messages.MANAGE_SERVICES_TO_APPLICATIONS_FINISH);
            CloudFoundryServerBehaviour behaviour = server.getBehaviour();
            if (serviceToApplicationsBindingPart != null && server != null && behaviour != null){
              List<ApplicationToService> applicationsToProcess =
                  serviceToApplicationsBindingPart.getApplicationToService();
             
              CloudService cloudService = null;
                           
              try {
                // Find the Cloud Service that was selected
                List<CloudService> cloudServiceList = behaviour.getServices(null);
                int lenCloudService = cloudServiceList.size();
               
                String serviceName = servicesHandler.toString();
               
                for (int j=0;j<lenCloudService;j++){
View Full Code Here

      return;
    }

    if (console instanceof ApplicationLogConsole) {
      ApplicationLogConsole logConsole = (ApplicationLogConsole) console;
      CloudFoundryServerBehaviour behaviour = server.getBehaviour();
      List<ApplicationLog> logs;
      try {
        logs = behaviour.getRecentApplicationLogs(appModule.getDeployedApplicationName(), monitor);
        if (!logs.isEmpty()) {
          logConsole.writeApplicationLogs(logs);
        }
        else {
View Full Code Here

      // Clean up all projects from workspace
      StsTestUtil.cleanUpProjects();

      // Perform clean up on existing published apps and services
      if (server != null) {
        CloudFoundryServerBehaviour serverBehavior = getBehaviour();
        // Delete all applications
        serverBehavior.deleteAllApplications(null);

        // Delete all services
        deleteAllServices();

        // Clear all domains and routes to avoid host taken errors
View Full Code Here

        }
      }
    }

    public void deleteService(CloudService serviceToDelete) throws CoreException {
      CloudFoundryServerBehaviour serverBehavior = getBehaviour();

      String serviceName = serviceToDelete.getName();
      List<String> services = new ArrayList<String>();
      services.add(serviceName);

      serverBehavior.getDeleteServicesOperation(services).run(new NullProgressMonitor());
    }
View Full Code Here

        // FIXNS: Commented out because of STS-3159
        // webContainer.stop();
      }

      if (server != null) {
        CloudFoundryServerBehaviour cloudFoundryServer = (CloudFoundryServerBehaviour) server.loadAdapter(
            CloudFoundryServerBehaviour.class, null);
        if (projectCreated) {
          try {
            cloudFoundryServer.deleteAllApplications(null);
          }
          catch (CoreException e) {
            e.printStackTrace();
          }
        }
        try {
          cloudFoundryServer.disconnect(null);
        }
        catch (CoreException e) {
          e.printStackTrace();
        }
      }
View Full Code Here

TOP

Related Classes of org.cloudfoundry.ide.eclipse.server.core.internal.client.CloudFoundryServerBehaviour$StopApplicationOperation

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.