Closed cacidavidschermers closed 7 years ago
hi @cacidavidschermers ,
2 questions :
FROM graviteeio/management-api:latest
COPY my-plugin.zip plugins/
Hello Nicolas,
Creating our own docker images is an option. If that's not necessary I would like to prevent that.
The storage has read/write rights. The full stacktrace:
07:34:05.689 [gravitee] WARN o.s.c.a.AnnotationConfigApplicationContext - Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'nodeHttpServer': Unsatisfied dependency expressed through field 'httpServer'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'vertxNodeHttpServer' defined in io.gravitee.management.services.http.spring.HttpServerSpringConfiguration: Unsatisfied dependency expressed through method 'httpServer' parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'vertx' defined in io.gravitee.management.services.http.spring.HttpServerSpringConfiguration: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [io.vertx.core.Vertx]: Factory method 'vertx' threw exception; nested exception is java.lang.IllegalStateException: Failed to create cache dir
org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'nodeHttpServer': Unsatisfied dependency expressed through field 'httpServer'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'vertxNodeHttpServer' defined in io.gravitee.management.services.http.spring.HttpServerSpringConfiguration: Unsatisfied dependency expressed through method 'httpServer' parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'vertx' defined in io.gravitee.management.services.http.spring.HttpServerSpringConfiguration: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [io.vertx.core.Vertx]: Factory method 'vertx' threw exception; nested exception is java.lang.IllegalStateException: Failed to create cache dir
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:569)
at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:88)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:349)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1219)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:543)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:482)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:751)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:861)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:541)
at io.gravitee.management.standalone.Container.initializeContext(Container.java:94)
at io.gravitee.management.standalone.Container.initialize(Container.java:53)
at io.gravitee.management.standalone.Container.
Vertx cannot create is temporary cache dir (https://github.com/eclipse/vert.x/blob/dae6d1635cba75dd8c37776cac355d7175cb8cdd/src/main/java/io/vertx/core/impl/FileResolver.java#L299).
I don't know how openshift works, but it seems to be a misconfiguration in the storage settings.Is there any difference between the configuration of the gateway and the management-api ?
We have to add this jvm options in launcher : -Dvertx.disableFileCaching=true
Why ? Vertx should be able to create its cache directory. Am I wrong ?
We do not need it. Please have a look to gateway launcher
We use the gravitee.io docker images in our openshift platform. We wrote a own plugin which must be uploaded in the gateway and api-management docker images. I can upload the plugin to the running pods but the pods needs a restart to be activated. We've added persistent storage to the pods but the api-management pod is in error after adding the storage.
Expected Behavior
Pod has persistent storage, expect to startup the gateway and api-management pods correctly
Current Behavior
Pod has persistent storage, gateway pod start correctly, the api-management pod is not starting because of this exception:
Factory method 'vertx' threw exception; nested exception is java.lang.IllegalStateException: Failed to create cache dir
How can I put the plugin to the pods and keep the pods persistent to be able to restart the pods and activate the plugins?
Your Environment
OpenShift platform where the docker images are added