Приложение Spring Boot (файл WAR) не может быть запущено на сервере Apache Tomcat - PullRequest
0 голосов
/ 05 марта 2019

Когда я пытаюсь запустить приложение из Tomcat Web Application Manager, оно показывает эту ошибку ...

FAIL - Application at context path [/surveyreporting] could not be started
FAIL - Encountered exception [org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/surveyreporting]]]

И когда я создаю военный файл с помощью Mavin, это то, что происходит ....

[INFO] Scanning for projects...
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building springboottest 1.0
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- lombok-maven-plugin:1.16.8.0:delombok (default) @ surveyreporting ---
[WARNING] Skipping Delombok; no source to process.
[INFO] 
[INFO] --- maven-resources-plugin:3.0.1:resources (default-resources) @ surveyreporting ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 1 resource
[INFO] Copying 1393 resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.7.0:compile (default-compile) @ surveyreporting ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 143 source files to /var/www/html/new/surveyreporting/target/classes
[WARNING] /var/www/html/new/surveyreporting/src/main/java/com/piccibhai/Controller/HomeController.java:[18,47] com.sun.org.apache.xerces.internal.util.URI is internal proprietary API and may be removed in a future release
[WARNING] /var/www/html/new/surveyreporting/src/main/java/com/piccibhai/Controller/HomeController.java:[18,47] com.sun.org.apache.xerces.internal.util.URI is internal proprietary API and may be removed in a future release
[WARNING] /var/www/html/new/surveyreporting/src/main/java/com/piccibhai/Controller/HomeController.java:[18,47] com.sun.org.apache.xerces.internal.util.URI is internal proprietary API and may be removed in a future release
[WARNING] /var/www/html/new/surveyreporting/src/main/java/com/piccibhai/Controller/HomeController.java:[18,47] com.sun.org.apache.xerces.internal.util.URI is internal proprietary API and may be removed in a future release
[WARNING] /var/www/html/new/surveyreporting/src/main/java/com/piccibhai/Controller/HomeController.java:[348,9] com.sun.org.apache.xerces.internal.util.URI is internal proprietary API and may be removed in a future release
[WARNING] /var/www/html/new/surveyreporting/src/main/java/com/piccibhai/Controller/HomeController.java:[350,23] com.sun.org.apache.xerces.internal.util.URI is internal proprietary API and may be removed in a future release
[WARNING] /var/www/html/new/surveyreporting/src/main/java/com/piccibhai/Controller/HomeController.java:[351,18] com.sun.org.apache.xerces.internal.util.URI is internal proprietary API and may be removed in a future release
[INFO] /var/www/html/new/surveyreporting/src/main/java/com/piccibhai/Controller/Data/Download/PPRDownloadRequest.java: Some input files use unchecked or unsafe operations.
[INFO] /var/www/html/new/surveyreporting/src/main/java/com/piccibhai/Controller/Data/Download/PPRDownloadRequest.java: Recompile with -Xlint:unchecked for details.
[INFO] 
[INFO] --- maven-resources-plugin:3.0.1:testResources (default-testResources) @ surveyreporting ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /var/www/html/new/surveyreporting/src/test/resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.7.0:testCompile (default-testCompile) @ surveyreporting ---
[INFO] Nothing to compile - all classes are up to date
[INFO] 
[INFO] --- maven-surefire-plugin:2.21.0:test (default-test) @ surveyreporting ---
[INFO] No tests to run.
[INFO] 
[INFO] --- maven-war-plugin:3.1.0:war (default-war) @ surveyreporting ---
[INFO] Packaging webapp
[INFO] Assembling webapp [surveyreporting] in [/var/www/html/new/surveyreporting/target/surveyreporting-1.0]
[INFO] Processing war project
[INFO] Webapp assembled in [2378 msecs]
[INFO] Building war: /var/www/html/new/surveyreporting/target/surveyreporting-1.0.war
[INFO] 
[INFO] --- spring-boot-maven-plugin:2.0.3.RELEASE:repackage (default) @ surveyreporting ---
[INFO] 
[INFO] --- maven-install-plugin:2.5.2:install (default-install) @ surveyreporting ---
[INFO] Installing /var/www/html/new/surveyreporting/target/surveyreporting-1.0.war to /home/tapumandal/.m2/repository/com/piccibhai/surveyreporting/1.0/surveyreporting-1.0.war
[INFO] Installing /var/www/html/new/surveyreporting/pom.xml to /home/tapumandal/.m2/repository/com/piccibhai/surveyreporting/1.0/surveyreporting-1.0.pom
[INFO] 
[INFO] --- maven-deploy-plugin:2.8.2:deploy (default-deploy) @ surveyreporting ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 40.825 s
[INFO] Finished at: 2019-03-05T14:27:44+06:00
[INFO] Final Memory: 51M/757M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.8.2:deploy (default-deploy) on project surveyreporting: Failed to deploy artifacts/metadata: Cannot access scp://localhost/surveyreporting with type default using the available connector factories: BasicRepositoryConnectorFactory: Cannot access scp://localhost/surveyreporting using the registered transporter factories: WagonTransporterFactory: java.util.NoSuchElementException
[ERROR] role: org.apache.maven.wagon.Wagon
[ERROR] roleHint: scp
[ERROR] -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

Process finished with exit code 1

Кстати, приложение работает на моем компьютере (локально) нормально.

Информация о сервере Версия Tomcat: Apache Tomcat / 8.5.34 Версия JVM: 1.8.0_191-b12

Мой компьютер (локальный) Java-версия "1.8.0_181"

1 Ответ

0 голосов
/ 05 марта 2019

информация об ошибке

[ОШИБКА] Не удалось выполнить цель org.apache.maven.plugins: maven-deploy-plugin: 2.8.2: deploy (default-deploy) при опросе проекта, отчет:Не удалось развернуть артефакты / метаданные: Невозможно получить доступ к scp: // localhost / surveyreporting с типом по умолчанию с использованием доступных фабрик соединителей: BasicRepositoryConnectorFactory: Невозможно получить доступ к scp: // localhost / surveyreporting с использованием зарегистрированных фабрик транспортеров: WagonTransporterFactory:java.util.NoSuchElementException

, поэтому вам нужно обновить URL-адрес scp

Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...