Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OpenShift Maven Plugin logs warning: Failed to validate resources: Unknown MetaSchema: https://json-schema.org/schema #415

Closed
rohanKanojia opened this issue Sep 29, 2020 · 3 comments · Fixed by #417
Assignees
Labels
bug Something isn't working
Projects
Milestone

Comments

@rohanKanojia
Copy link
Member

Description

Ever since we merged #394, I'm getting this warning in OpenShift Maven Plugin resource goal. It seems to be happening for all projects using OpenShift maven Plugin.

quarkus-customized-image : $ mvn oc:resource  -Popenshift
[INFO] Scanning for projects...
[INFO] 
[INFO] ----< org.eclipse.jkube.quickstarts.maven:quarkus-customized-image >----
[INFO] Building Eclipse JKube :: Quickstarts :: Maven :: Quarkus customized Image 1.0.0
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] 
[INFO] --- openshift-maven-plugin:1.0.1-SNAPSHOT:resource (default-cli) @ quarkus-customized-image ---
[INFO] oc: Using docker image name of namespace: default
[INFO] oc: jkube-controller: Adding a default DeploymentConfig
[INFO] oc: jkube-service: Adding a default service 'quarkus-customized-image' with ports [8080]
[INFO] oc: jkube-revision-history: Adding revision history limit to 2
[INFO] oc: validating /home/rohaan/work/repos/jkube/quickstarts/maven/quarkus-customized-image/target/classes/META-INF/jkube/openshift/quarkus-customized-image-route.yml resource
[WARNING] oc: Failed to validate resources: Unknown MetaSchema: https://json-schema.org/schema
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  3.768 s
[INFO] Finished at: 2020-09-29T20:02:16+05:30
[INFO] ------------------------------------------------------------------------

Is this desired behavior?

Info

  • Eclipse JKube version : 1.0.1-SNAPSHOT(master)
  • Maven version (mvn -v) :
Apache Maven 3.6.3 (cecedd343002696d0abb50b32b541b8a6ba2883f)
Maven home: /opt/apache-maven
Java version: 1.8.0_251, vendor: Oracle Corporation, runtime: /usr/java/jdk1.8.0_251-amd64/jre
Default locale: en_US, platform encoding: UTF-8
OS name: "linux", version: "5.8.10-200.fc32.x86_64", arch: "amd64", family: "unix"
  • Kubernetes / Red Hat OpenShift setup and version :

  • If it's a bug, how to reproduce : Hit oc:resource on any quickstart using SNAPSHOT version of master, you would be able to see this warning.

  • If it's a feature request, what is your use case :

  • Sample Reproducer Project : [GitHub Clone URL]

@manusa manusa added the bug Something isn't working label Sep 29, 2020
@manusa manusa added this to the 1.0.1 milestone Sep 29, 2020
@manusa manusa added this to Planned in Sprint #190 Sep 29, 2020
@manusa manusa moved this from Planned to In progress in Sprint #190 Sep 30, 2020
@manusa manusa self-assigned this Sep 30, 2020
@manusa
Copy link
Member

manusa commented Sep 30, 2020

I tried with several projects, but I'm unable to reproduce:

$ mvn clean package oc:resource -Popenshift
# ...
[INFO] --- openshift-maven-plugin:1.0.1-SNAPSHOT:resource (default-cli) @ quarkus-customized-image ---
[INFO] oc: Using docker image name of namespace: default
[INFO] oc: jkube-controller: Adding a default DeploymentConfig
[INFO] oc: jkube-service: Adding a default service 'quarkus-customized-image' with ports [8080]
[INFO] oc: jkube-revision-history: Adding revision history limit to 2
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  10.760 s
[INFO] Finished at: 2020-09-30T07:19:01+02:00
[INFO] ------------------------------------------------------------------------

Could you provide more details (contents of quarkus-customized-image-route.yml)?
The issue can make sense since now JsonSchemaFactory is initialized using a static method (empty constructor is deprecated).

@manusa
Copy link
Member

manusa commented Sep 30, 2020

Ok, I can reproduce with the external-resources project

@manusa
Copy link
Member

manusa commented Sep 30, 2020

JSON Schema URL provided by Kubernetes Client model is deprecated:
image

Unversioned URL redirects to latest draft (https://json-schema.org/draft/2019-09/schema)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
No open projects
Sprint #190
  
Done
2 participants