Project

General

Profile

« Previous | Next » 

Revision 2456bd7d

Added by Andreas Kohlbecker over 4 years ago

fix #8652 cleaning code related to system property cdm.server.dev.port and better error reporting

View differences:

eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/source/CdmServerInfo.java
478 478
                    logger.info("Will connect local development cdm instance: at port " + devPort);
479 479
                    return devCii.getCdmRemoteSource(devInstance, devPort);
480 480
                }
481
            } catch (Exception e) {
481
            } catch (CDMServerException e) {
482
                logger.error("Can not connect to local development cdm instance at port " + devPort + ". "
483
                        + "Make sure the cdm instance is running and that the Spring profile \"remoting\" is "
484
                        + "activated (-Dspring.profiles.active=remoting)", e);
485
                //TODO show message dialog only instead of throwing the exception to show the error
486
                // dialog is not necessary in this situation
482 487
            }
483 488
            logger.error("local development cdm instance at port " + devPort + " is not accessible");
484 489
        }
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/dialog/selection/ExtReferenceSelectionDialog.java
91 91
            super(shell, //conversation,
92 92
                    title, multi, ExtReferenceSelectionDialog.class.getCanonicalName());
93 93
            this.currentReference = reference;
94

  
95 94
//            controller = CdmStore.getCurrentApplicationConfiguration();
96
//            String currentValue = System.getProperty("cdm.server.dev.port");
97
            System.setProperty("cdm.server.dev.port", "8080");
98 95
            remoteSource = CdmServerInfo.getDevServerRemoteSource();
99 96
            remoteSourceRef = ReferenceFactory.newDatabase();
100 97
            remoteSourceRef.setTitle(remoteSource.getName());
101
         System.setProperty("cdm.server.dev.port", "80");
102 98
        }
103 99

  
104 100

  

Also available in: Unified diff