public ClusteringControllerImpl() {
    executor = new LongTaskExecutor(true, "Clusterer", 10);
    errorHandler =
        new LongTaskErrorHandler() {

          public void fatalError(Throwable t) {
            Logger.getLogger("").log(Level.SEVERE, "", t.getCause() != null ? t.getCause() : t);
          }
        };
    executor.setDefaultErrorHandler(errorHandler);
  }
  @Override
  public void action() {
    final WebSiteExporter wsExporter = new WebSiteExporter();
    settings.load(wsExporter);

    WebSiteSettingsPanel wsPanelSettings = new WebSiteSettingsPanel();
    wsPanelSettings.setup(wsExporter);

    ValidationPanel validationPanel = WebSiteSettingsPanel.createValidationPanel(wsPanelSettings);

    final DialogDescriptor dialogDescriptor =
        new DialogDescriptor(
            validationPanel, getMessage("WebSiteExporterUI.dialogdescriptor.description"));

    validationPanel.addChangeListener(
        new ChangeListener() {

          @Override
          public void stateChanged(ChangeEvent e) {
            dialogDescriptor.setValid(!((ValidationPanel) e.getSource()).isProblem());
          }
        });
    Object result = DialogDisplayer.getDefault().notify(dialogDescriptor);
    if (result == NotifyDescriptor.OK_OPTION) {
      wsPanelSettings.unsetup(true);
      settings.save(wsExporter);
      filePath = wsExporter.getPath().getAbsolutePath();
      if (wsPanelSettings.getSelectedWorkspaces().length > 0) {
        wsExporter.setSelectedWorkspaces(wsPanelSettings.getSelectedWorkspaces());

        LongTaskExecutor executor = new LongTaskExecutor(true, "WebSiteExporter");
        executor.setLongTaskListener(longTaskListener);
        executor.setDefaultErrorHandler(errorHandler);
        executor.execute(
            wsExporter,
            new Runnable() {

              @Override
              public void run() {

                cancelled = !wsExporter.execute();
              }
            });
      } else {
        JOptionPane.showMessageDialog(
            validationPanel,
            getMessage("WebSiteExporterUI.Errormsg.WSSelected.Description"),
            getMessage("WebSiteExporterUI.Errormsg.WSSelected.Title"),
            JOptionPane.ERROR_MESSAGE);
      }
    } else {
      wsPanelSettings.unsetup(false);
    }
  }