6.3.RC1 - application components - assembleDbScripts failed - ArtifactNotFoundException

Hi,

i stumbled upon the following “problem”:
When creating a application component with the following steps:

  1. create a studio project
  2. change the Modules prefix
  3. create the App component descriptor
    (and not starting the app-component at all).

Then go to the app that should use the component and add the dependency to it. Then try to start the application. The following error occurs:


[21:06:26.233] Restarting the application server
:app-core:assembleDbScripts FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app-core:assembleDbScripts'.
> Could not find test-dep-core-db.zip (com.company.testdep:test-dep-core:0.1-SNAPSHOT).
  Searched in the following locations:
      file:/Users/mario/.m2/repository/com/company/testdep/test-dep-core/0.1-SNAPSHOT/test-dep-core-0.1-SNAPSHOT-db.zip
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 0.837 secs
[21:06:27.127] Task 'deploy, start' failed
org.gradle.internal.resolve.ArtifactNotFoundException: Could not find test-dep-core-db.zip (com.company.testdep:test-dep-core:0.1-SNAPSHOT). Searched in the following locations:     file:/Users/mario/.m2/repository/com/company/testdep/test-dep-core/0.1-SNAPSHOT/test-dep-core-0.1-SNAPSHOT-db.zip

It seems that only when the application server in the application component is started once, then the error disappears because it creates the db srcipts on startup - right?

I think it’s not a big problem but as the error is not directly aligned to the cause of it, i just wanted to write it down so the google crawler can come and present it to the world. But perhaps you might want to additionally change it, so i just report it here.

Bye,
Mario

Hi Mario,
You are right, database scripts are assembled when the “deploy” task is executed, hence they are not included to the installed artifcats if you never deploy the app component. We will fix it, thank you for reporting the issue.

My previous assumption was wrong. In fact, database scripts artifact is assembled correctly on “install”. The problem appears when you have a component without DB scripts at all - but Studio still generates app-component.xml declaring an exposed artifact for DB scripts. So we’ll fix Studio.

Hi Konstantin,

thanks for the info.

Bye,
Mario

Hi

The problem is fixed in the Studio version 6.3.0.