generator-jhipster: DEBUG [ restartedMain] Validator : ERROR [ModelSpecification.spec] At least one type of specification is required

Overview of the issue

when start up get several debug error log

2021-02-04 08:47:51.637 DEBUG 10814 — [ restartedMain] Validator : ERROR [ModelSpecification.spec] At least one type of specification is required

Motivation for or Use Case
Reproduce the error
Related issues
Suggest a Fix
JHipster Version(s)

latest 7.0.0 Beta.1

JHipster configuration
Entity configuration(s) entityName.json files generated in the .jhipster directory
Browsers and Operating System
  • Checking this box is mandatory (this is just to show you read everything)

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 17 (8 by maintainers)

Commits related to this issue

Most upvoted comments

@atomfrede : I already saw these warnings. It’s easy to reproduce, just use jhipster --defaults and start the application

Here the configuration:

JHipster Version(s)
jhipster@0.0.1-SNAPSHOT /home/pgrimaud/tmp/08-default
└── generator-jhipster@7.0.0-beta.1 

JHipster configuration, a .yo-rc.json file generated in the root folder
.yo-rc.json file
{
  "generator-jhipster": {
    "baseName": "jhipster",
    "buildTool": "maven",
    "databaseType": "sql",
    "devDatabaseType": "h2Disk",
    "cacheProvider": "ehcache",
    "enableHibernateCache": true,
    "enableSwaggerCodegen": false,
    "enableTranslation": true,
    "jhiPrefix": "jhi",
    "languages": ["en", "fr"],
    "messageBroker": false,
    "prodDatabaseType": "postgresql",
    "searchEngine": false,
    "skipClient": false,
    "testFrameworks": [],
    "websocket": false,
    "skipServer": false,
    "packageFolder": "com/mycompany/myapp",
    "packageName": "com.mycompany.myapp",
    "clientPackageManager": "npm",
    "dtoSuffix": "DTO",
    "entitySuffix": "",
    "reactive": false,
    "applicationType": "monolith",
    "skipUserManagement": false,
    "skipCheckLengthOfIdentifier": false,
    "skipFakeData": false,
    "blueprints": [],
    "otherModules": [],
    "pages": [],
    "serverPort": "8080",
    "authenticationType": "jwt",
    "serviceDiscoveryType": false,
    "clientFramework": "angularX",
    "clientTheme": "none",
    "clientThemeVariant": "",
    "withAdminUi": true,
    "nativeLanguage": "en",
    "jhipsterVersion": "7.0.0-beta.1",
    "creationTimestamp": 1613394227416,
    "jwtSecretKey": "YourJWTSecretKeyWasReplacedByThisMeaninglessTextByTheJHipsterInfoCommandForObviousSecurityReasons"
  }
}
JDL for the Entity configuration(s) entityName.json files generated in the .jhipster directory
JDL entity definitions

Environment and Tools

openjdk version “11.0.10” 2021-01-19 OpenJDK Runtime Environment (build 11.0.10+9-Ubuntu-0ubuntu1.18.04) OpenJDK 64-Bit Server VM (build 11.0.10+9-Ubuntu-0ubuntu1.18.04, mixed mode, sharing)

git version 2.30.0

node: v14.15.4

npm: 6.14.10

yeoman: 3.1.1

Docker version 19.03.8, build afacb8b7f0

docker-compose version 1.27.3, build 4092ae5d

Here the stacktrace:

2021-02-15 14:06:39.170 DEBUG 22830 --- [kground-preinit] org.jboss.logging                        : Logging Provider: org.jboss.logging.Log4j2LoggerProvider
2021-02-15 14:06:39.177  INFO 22830 --- [  restartedMain] com.mycompany.myapp.JhipsterApp          : Starting JhipsterApp using Java 11.0.10 on pgrxps15 with PID 22830 (/home/pgrimaud/tmp/08-default/target/classes started by pgrimaud in /home/pgrimaud/tmp/08-default)
2021-02-15 14:06:39.178 DEBUG 22830 --- [  restartedMain] com.mycompany.myapp.JhipsterApp          : Running with Spring Boot v2.4.2, Spring v5.3.3
2021-02-15 14:06:39.178  INFO 22830 --- [  restartedMain] com.mycompany.myapp.JhipsterApp          : The following profiles are active: dev,api-docs
2021-02-15 14:06:40.916 DEBUG 22830 --- [  restartedMain] i.m.c.u.i.logging.InternalLoggerFactory  : Using SLF4J as the default logging framework
2021-02-15 14:06:41.009 DEBUG 22830 --- [  restartedMain] c.mycompany.myapp.config.WebConfigurer   : Registering CORS filter
2021-02-15 14:06:41.036  INFO 22830 --- [  restartedMain] c.mycompany.myapp.config.WebConfigurer   : Web application configuration, using profiles: dev
2021-02-15 14:06:41.037 DEBUG 22830 --- [  restartedMain] c.mycompany.myapp.config.WebConfigurer   : Initialize H2 console
2021-02-15 14:06:41.044  INFO 22830 --- [  restartedMain] c.mycompany.myapp.config.WebConfigurer   : Web application fully configured
2021-02-15 14:06:41.244 DEBUG 22830 --- [  restartedMain] c.ehcache.core.Ehcache-usersByLogin      : Initialize successful.
2021-02-15 14:06:41.257 DEBUG 22830 --- [  restartedMain] c.ehcache.core.Ehcache-usersByEmail      : Initialize successful.
2021-02-15 14:06:41.261 DEBUG 22830 --- [  restartedMain] c.e.c.E.mycompany.myapp.domain.User      : Initialize successful.
2021-02-15 14:06:41.264 DEBUG 22830 --- [  restartedMain] c.e.c.E.m.myapp.domain.Authority         : Initialize successful.
2021-02-15 14:06:41.267 DEBUG 22830 --- [  restartedMain] c.e.c.E.m.myapp.domain.User.authorities  : Initialize successful.
2021-02-15 14:06:41.280 DEBUG 22830 --- [  restartedMain] c.m.myapp.config.AsyncConfiguration      : Creating Async Task Executor
2021-02-15 14:06:41.343 DEBUG 22830 --- [  restartedMain] c.m.myapp.config.LiquibaseConfiguration  : Configuring Liquibase
2021-02-15 14:06:41.428  WARN 22830 --- [jhipster-task-1] t.j.c.liquibase.AsyncSpringLiquibase     : Starting Liquibase asynchronously, your database might not be ready at startup!
2021-02-15 14:06:42.097 DEBUG 22830 --- [jhipster-task-1] t.j.c.liquibase.AsyncSpringLiquibase     : Liquibase has updated your database in 668 ms
2021-02-15 14:06:42.359 DEBUG 22830 --- [  restartedMain] c.m.myapp.security.jwt.TokenProvider     : Using a Base64-encoded JWT secret key
2021-02-15 14:06:43.588 DEBUG 22830 --- [  restartedMain] t.j.c.apidoc.SpringfoxAutoConfiguration  : Starting OpenAPI docs
2021-02-15 14:06:43.592 DEBUG 22830 --- [  restartedMain] t.j.c.apidoc.SpringfoxAutoConfiguration  : Started OpenAPI docs in 3 ms
2021-02-15 14:06:43.629 DEBUG 22830 --- [  restartedMain] c.m.myapp.config.DatabaseConfiguration   : H2 database is available on port 18080
2021-02-15 14:06:44.180  INFO 22830 --- [  restartedMain] org.jboss.threads                        : JBoss Threads version 3.1.0.Final
2021-02-15 14:06:44.337 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.342 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.355 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.358 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.367 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.393 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.405 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.411 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.437 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.441 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.443 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.446 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.448 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.450 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.452 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.454 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.456 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.458 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.459 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.461 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.464 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.466 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.469 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.471 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.474 DEBUG 22830 --- [  restartedMain] Validator                                : ERROR [ModelSpecification.spec] At least one type of specification is required
2021-02-15 14:06:44.503  INFO 22830 --- [  restartedMain] com.mycompany.myapp.JhipsterApp          : Started JhipsterApp in 5.747 seconds (JVM running for 6.134)
2021-02-15 14:06:44.511  INFO 22830 --- [  restartedMain] com.mycompany.myapp.JhipsterApp          : 
----------------------------------------------------------
	Application 'jhipster' is running! Access URLs:
	Local: 		http://localhost:8080/
	External: 	http://127.0.1.1:8080/
	Profile(s): 	[dev, api-docs]
----------------------------------------------------------

I get this on 7.0.1 as well

Go to src\main\resources\logback-spring.xml and add this lines

<logger name="Validator" level="INFO"/>
<logger name="_org.springframework.web.servlet.HandlerMapping.Mappings" level="INFO"/> <!-- Optional -->

The warning occurs on:

  • POST, PUT, PATCH method of each entity
  • POST /api/authenticate
  • some spring boot actuator endpoints (/management/*)

I don’t know if some Springfox annotation could solve the warning for the first 2 points, but surely we cannot do much on actuator endpoints.

I agree with @jidma, let’s change the logger level of “Validator” to INFO. But let’s also specify in a comment that that line is related to springfox, the logger name does not help.