调用APIMAN API

时间:2018-05-18 13:59:41

标签: mysql jdbc apiman

所以,我刚开始使用API​​MAN并做了一些配置。我使用BASIC身份验证创建了一个API服务。在那里我使用JDBC url作为jdbc:mysql:// localhost:3036 / Demo。

然后我创建了一个应用程序服务来使用该API。但是当我使用API​​端点时,它会给我一些错误。

错误: -

  

{" responseCode":500," message":"无法获取jdbcUrl的驱动程序实例= jdbc:mysql:// localhost:3306 /?user = root& #34;," trace":" java.lang.RuntimeException:无法获取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.en gine.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 $执行$ 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.Authenti cationMechanismsHandler.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.UndertowDeploymentInfoServic E $ UndertowThreadSetupAction.lambda $创建$ 0(UndertowDeploymentInfoService.java:1508)\ n \达org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService $ UndertowThreadSetupAction.lambda $创建$ 0(UndertowDeploymentInfoService.java:1508)\ n \达组织。 wildfly.extension.undertow.deployment.UndertowDeploymentInfoService $ UndertowThreadSetupAction.lambda $ create $ 0(UndertowDeploymentInfoService.java:1508)\ n \ tat io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:272)\ n \ t \ tti 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.ThreadPoolExecut或$ Worker.run(ThreadPoolExecutor.java:624)\ n \ tat java.lang.Thread.run(Thread.java:748) \ n由:java.sql.SQLException提供:没有合适的驱动程序\ 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 个答案:

没有答案