Getting error on calling APIs of APIMAN

27 Views Asked by At

So, I just started using APIMAN and did some configurations. I created one API service with BASIC Authentication. In that I used JDBC url as jdbc:mysql://localhost:3036/Demo.

Then I created one application service to consume that API. But when I am using API endpoint it's throwing me some errors.

Error:-

{"responseCode":500,"message":"Unable to get driver instance for jdbcUrl=jdbc:mysql://localhost:3306/?user=root","trace":"java.lang.RuntimeException: Unable to get driver instance for jdbcUrl=jdbc:mysql://localhost:3306/?user=root\n\tat com.zaxxer.hikari.util.DriverDataSource.(DriverDataSource.java:88)\n\tat com.zaxxer.hikari.pool.PoolElf.initializeDataSource(PoolElf.java:143)\n\tat com.zaxxer.hikari.pool.HikariPool.(HikariPool.java:112)\n\tat com.zaxxer.hikari.HikariDataSource.(HikariDataSource.java:73)\n\tat io.apiman.gateway.engine.impl.DefaultJdbcComponent.datasourceFromConfig(DefaultJdbcComponent.java:101)\n\tat io.apiman.gateway.engine.impl.DefaultJdbcComponent.createShared(DefaultJdbcComponent.java:58)\n\tat io.apiman.gateway.engine.impl.DefaultJdbcComponent.createStandalone(DefaultJdbcComponent.java:70)\n\tat io.apiman.gateway.engine.policies.auth.JDBCIdentityValidator.createClient(JDBCIdentityValidator.java:126)\n\tat io.apiman.gateway.engine.policies.auth.JDBCIdentityValidator.validate(JDBCIdentityValidator.java:90)\n\tat io.apiman.gateway.engine.policies.BasicAuthenticationPolicy.validateCredentials(BasicAuthenticationPolicy.java:169)\n\tat io.apiman.gateway.engine.policies.BasicAuthenticationPolicy.doApply(BasicAuthenticationPolicy.java:126)\n\tat io.apiman.gateway.engine.policies.BasicAuthenticationPolicy.doApply(BasicAuthenticationPolicy.java:45)\n\tat io.apiman.gateway.engine.policies.AbstractMappedPolicy.apply(AbstractMappedPolicy.java:70)\n\tat io.apiman.gateway.engine.policy.RequestChain.applyPolicy(RequestChain.java:68)\n\tat io.apiman.gateway.engine.policy.Chain.doApply(Chain.java:148)\n\tat io.apiman.gateway.engine.policies.RateLimitingPolicy$1.handle(RateLimitingPolicy.java:104)\n\tat io.apiman.gateway.engine.policies.RateLimitingPolicy$1.handle(RateLimitingPolicy.java:91)\n\tat io.apiman.gateway.engine.es.ESRateLimiterComponent.updateBucketAndReturn(ESRateLimiterComponent.java:117)\n\tat io.apiman.gateway.engine.es.ESRateLimiterComponent.accept(ESRateLimiterComponent.java:83)\n\tat io.apiman.gateway.engine.policies.RateLimitingPolicy.doApply(RateLimitingPolicy.java:91)\n\tat io.apiman.gateway.engine.policies.RateLimitingPolicy.doApply(RateLimitingPolicy.java:45)\n\tat io.apiman.gateway.engine.policies.AbstractMappedPolicy.apply(AbstractMappedPolicy.java:70)\n\tat io.apiman.gateway.engine.policy.RequestChain.applyPolicy(RequestChain.java:68)\n\tat io.apiman.gateway.engine.policy.Chain.doApply(Chain.java:148)\n\tat io.apiman.gateway.engine.impl.ApiRequestExecutorImpl.lambda$execute$4(ApiRequestExecutorImpl.java:276)\n\tat io.apiman.gateway.engine.impl.ApiRequestExecutorImpl.lambda$loadPolicies$7(ApiRequestExecutorImpl.java:666)\n\tat io.apiman.gateway.engine.policy.PolicyFactoryImpl.loadPolicy(PolicyFactoryImpl.java:95)\n\tat io.apiman.gateway.engine.impl.ApiRequestExecutorImpl.loadPolicies(ApiRequestExecutorImpl.java:634)\n\tat io.apiman.gateway.engine.impl.ApiRequestExecutorImpl.lambda$execute$6(ApiRequestExecutorImpl.java:397)\n\tat io.apiman.gateway.engine.impl.SecureRegistryWrapper$2.handle(SecureRegistryWrapper.java:189)\n\tat io.apiman.gateway.engine.impl.SecureRegistryWrapper$2.handle(SecureRegistryWrapper.java:171)\n\tat io.apiman.gateway.engine.es.CachingESRegistry.getContract(CachingESRegistry.java:103)\n\tat io.apiman.gateway.engine.impl.SecureRegistryWrapper.getContract(SecureRegistryWrapper.java:171)\n\tat io.apiman.gateway.engine.impl.ApiRequestExecutorImpl.execute(ApiRequestExecutorImpl.java:363)\n\tat io.apiman.gateway.platforms.servlet.GatewayServlet.doAction(GatewayServlet.java:178)\n\tat io.apiman.gateway.platforms.servlet.GatewayServlet.service(GatewayServlet.java:79)\n\tat javax.servlet.http.HttpServlet.service(HttpServlet.java:790)\n\tat io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:85)\n\tat io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:62)\n\tat io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36)\n\tat org.wildfly.extension.undertow.security.SecurityContextAssociationHandler.handleRequest(SecurityContextAssociationHandler.java:78)\n\tat io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)\n\tat io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:131)\n\tat io.undertow.servlet.handlers.security.ServletAuthenticationCallHandler.handleRequest(ServletAuthenticationCallHandler.java:57)\n\tat io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)\n\tat io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:46)\n\tat io.undertow.servlet.handlers.security.ServletConfidentialityConstraintHandler.handleRequest(ServletConfidentialityConstraintHandler.java:64)\n\tat io.undertow.security.handlers.AuthenticationMechanismsHandler.handleRequest(AuthenticationMechanismsHandler.java:60)\n\tat io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:77)\n\tat io.undertow.security.handlers.NotificationReceiverHandler.handleRequest(NotificationReceiverHandler.java:50)\n\tat io.undertow.security.handlers.AbstractSecurityContextAssociationHandler.handleRequest(AbstractSecurityContextAssociationHandler.java:43)\n\tat io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)\n\tat org.wildfly.extension.undertow.security.jacc.JACCContextIdHandler.handleRequest(JACCContextIdHandler.java:61)\n\tat io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)\n\tat org.wildfly.extension.undertow.deployment.GlobalRequestControllerHandler.handleRequest(GlobalRequestControllerHandler.java:68)\n\tat io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)\n\tat io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:292)\n\tat io.undertow.servlet.handlers.ServletInitialHandler.access$100(ServletInitialHandler.java:81)\n\tat io.undertow.servlet.handlers.ServletInitialHandler$2.call(ServletInitialHandler.java:138)\n\tat io.undertow.servlet.handlers.ServletInitialHandler$2.call(ServletInitialHandler.java:135)\n\tat io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:48)\n\tat io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43)\n\tat org.wildfly.extension.undertow.security.SecurityContextThreadSetupAction.lambda$create$0(SecurityContextThreadSetupAction.java:105)\n\tat org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1508)\n\tat org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1508)\n\tat org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1508)\n\tat org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1508)\n\tat io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:272)\n\tat io.undertow.servlet.handlers.ServletInitialHandler.access$000(ServletInitialHandler.java:81)\n\tat io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:104)\n\tat io.undertow.server.Connectors.executeRootHandler(Connectors.java:326)\n\tat io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:812)\n\tat java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)\n\tat java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)\n\tat java.lang.Thread.run(Thread.java:748)\nCaused by: java.sql.SQLException: No suitable driver\n\tat java.sql.DriverManager.getDriver(DriverManager.java:315)\n\tat com.zaxxer.hikari.util.DriverDataSource.(DriverDataSource.java:81)\n\t... 74 more\n"}

0

There are 0 best solutions below