簡體   English   中英

錯誤部署 Spring 使用 Heroku CLI 引導

[英]Error Deployment Spring Boot with Heroku CLI

我想用它的 CLI 在 heroku 中部署我的 Spring 引導應用程序,但是當我運行命令git push heroku master ,74596 日志:

Enumerating objects: 79, done.
Counting objects: 100% (79/79), done.
Delta compression using up to 4 threads
Compressing objects: 100% (53/53), done.
Writing objects: 100% (60/60), 467.49 KiB | 3.57 MiB/s, done.
Total 60 (delta 28), reused 0 (delta 0)
remote: Compressing source files... done.
remote: Building source:
remote:
remote: -----> Java app detected
remote: -----> Installing JDK 12... done
remote: -----> Executing Maven
remote:        $ ./mvnw -DskipTests clean dependency:list install
remote:        [INFO] Scanning for projects...
remote:        [INFO]
remote:        [INFO] --------------------< mx.unitec:Inventario-Backend >--------------------
remote:        [INFO] Building InventarioBackend 0.0.1-SNAPSHOT
remote:        [INFO] --------------------------------[ jar ]---------------------------------
remote:        [INFO]
remote:        [INFO] --- maven-clean-plugin:3.1.0:clean (default-clean) @ Inventario-Backend ---
remote:        [INFO]
remote:        [INFO] --- maven-dependency-plugin:3.1.2:list (default-cli) @ Inventario-Backend ---
remote:        [INFO]
remote:        [INFO] --- maven-resources-plugin:3.1.0:resources (default-resources) @ Inventario-Backend ---
remote:        [INFO] Using 'UTF-8' encoding to copy filtered resources.
remote:        [INFO] Copying 1 resource
remote:        [INFO] Copying 1 resource
remote:        [INFO]
remote:        [INFO] --- maven-compiler-plugin:3.8.1:compile (default-compile) @ Inventario-Backend ---
remote:        [INFO] Changes detected - recompiling the module!
remote:        [INFO] Compiling 78 source files to /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/target/classes
remote:        [INFO] -------------------------------------------------------------
remote:        [ERROR] COMPILATION ERROR :
remote:        [INFO] -------------------------------------------------------------
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/WarehouseService.java:[9,21] cannot find symbol
remote:          symbol:   class InventoryInput
remote:          location: package unitec.models
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/WarehouseService.java:[19,26] cannot find symbol
remote:          symbol:   class InventoryInput
remote:          location: interface unitec.services.WarehouseService
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/WarehouseServiceImpl.java:[18,21] cannot find symbol
remote:          symbol:   class InventoryInput
remote:          location: package unitec.models
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/WarehouseServiceImpl.java:[59,33] cannot find symbol
remote:          symbol:   class InventoryInput
remote:          location: class unitec.services.WarehouseServiceImpl
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/EmailService.java:[8,21] cannot find symbol
remote:          symbol:   class InventoryInput
remote:          location: package unitec.models
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/EmailService.java:[12,31] cannot find symbol
remote:          symbol:   class InventoryInput
remote:          location: interface unitec.services.EmailService
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/MovementServiceImpl.java:[12,21] cannot find symbol
remote:          symbol:   class InventoryInput
remote:          location: package unitec.models
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/EmailServiceImpl.java:[17,21] cannot find symbol
remote:          symbol:   class InventoryInput
remote:          location: package unitec.models
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/EmailServiceImpl.java:[22,20] cannot find symbol
remote:          symbol:   class EmailsConstants
remote:          location: package unitec.utils
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/EmailServiceImpl.java:[43,38] cannot find symbol
remote:          symbol:   class InventoryInput
remote:          location: class unitec.services.EmailServiceImpl
remote:        [INFO] 10 errors
remote:        [INFO] -------------------------------------------------------------
remote:        [INFO] ------------------------------------------------------------------------
remote:        [INFO] BUILD FAILURE
remote:        [INFO] ------------------------------------------------------------------------
remote:        [INFO] Total time:  9.261 s
remote:        [INFO] Finished at: 2020-05-09T20:51:17Z
remote:        [INFO] ------------------------------------------------------------------------
remote:        [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.1:compile (default-compile) on project Inventario-Backend: Compilation failure: Compilation failure:
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/WarehouseService.java:[9,21] cannot find symbol
remote:        [ERROR]   symbol:   class InventoryInput
remote:        [ERROR]   location: package unitec.models
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/WarehouseService.java:[19,26] cannot find symbol
remote:        [ERROR]   symbol:   class InventoryInput
remote:        [ERROR]   location: interface unitec.services.WarehouseService
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/WarehouseServiceImpl.java:[18,21] cannot find symbol
remote:        [ERROR]   symbol:   class InventoryInput
remote:        [ERROR]   location: package unitec.models
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/WarehouseServiceImpl.java:[59,33] cannot find symbol
remote:        [ERROR]   symbol:   class InventoryInput
remote:        [ERROR]   location: class unitec.services.WarehouseServiceImpl
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/EmailService.java:[8,21] cannot find symbol
remote:        [ERROR]   symbol:   class InventoryInput
remote:        [ERROR]   location: package unitec.models
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/EmailService.java:[12,31] cannot find symbol
remote:        [ERROR]   symbol:   class InventoryInput
remote:        [ERROR]   location: interface unitec.services.EmailService
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/MovementServiceImpl.java:[12,21] cannot find symbol
remote:        [ERROR]   symbol:   class InventoryInput
remote:        [ERROR]   location: package unitec.models
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/EmailServiceImpl.java:[17,21] cannot find symbol
remote:        [ERROR]   symbol:   class InventoryInput
remote:        [ERROR]   location: package unitec.models
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/EmailServiceImpl.java:[22,20] cannot find symbol
remote:        [ERROR]   symbol:   class EmailsConstants
remote:        [ERROR]   location: package unitec.utils
remote:        [ERROR] /tmp/build_65b0ee3f73bcece7280cd5c846ba8f12/src/main/java/unitec/services/EmailServiceImpl.java:[43,38] cannot find symbol
remote:        [ERROR]   symbol:   class InventoryInput
remote:        [ERROR]   location: class unitec.services.EmailServiceImpl
remote:        [ERROR] -> [Help 1]
remote:        [ERROR]
remote:        [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
remote:        [ERROR] Re-run Maven using the -X switch to enable full debug logging.
remote:        [ERROR]
remote:        [ERROR] For more information about the errors and possible solutions, please read the following articles:
remote:        [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
remote:
remote:  !     ERROR: Failed to build app with Maven
remote:        We're sorry this build is failing! If you can't find the issue in application code,
remote:        please submit a ticket so we can help: https://help.heroku.com/
remote:
remote:  !     Push rejected, failed to compile Java app.
remote:
remote:  !     Push failed
remote: Verifying deploy...
remote:
remote: !       Push rejected to aqueous-dusk-36233.
remote:
To https://git.heroku.com/aqueous-dusk-36233.git
 ! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'https://git.heroku.com/aqueous-dusk-36233.git'

我不明白為什么在編譯過程中沒有加載包含提到的類的包......所以,應用程序在本地環境中完美運行。

我已經嘗試指定導致錯誤日志的包,但沒有工作......

我什么都試過了。 但是沒有任何效果..; I tried changing the default compiler Maven plugin with Apache Plugin or Heroku Maven Plugin, added configuration for Spring Boot Maven Plugin, specify the base packages, specify the ComponentScan. 指定自動配置...

所以,我說我:“如果添加,編譯並再次迭代推送?” 工作。 刪除我項目的所有包並一個一個添加包..,第一個模型,第二個存儲庫,第三個服務。 ETC...

我想哭! 這行得通!

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM