keyTemplateRetriever Failed retrieving throttling data WSO2 - wso2-api-manager

I was setting up prepackaged WSO2 identity server with WSO2 API Manager.Also was configuring the domain urls.
Now while starting WSO2 API Manager , below error is printed in the logs
[2017-05-12 05:37:35,237] INFO - CarbonEventManagementService Starting polling event receivers
[2017-05-12 05:37:55,848] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Received fatal alert: handshake_failure. Retrying after 15 seconds...
[2017-05-12 05:37:55,850] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Received fatal alert: handshake_failure. Retrying after 15 seconds...
[2017-05-12 05:38:01,861] WARN - FileSystemPreferences Could not lock System prefs. Unix error code 32693.
[2017-05-12 05:38:01,861] WARN - FileSystemPreferences Couldn't flush system prefs: java.util.prefs.BackingStoreException: Couldn't get file lock.
[2017-05-12 05:38:10,877] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Received fatal alert: handshake_failure. Retrying after 15 seconds...
[2017-05-12 05:38:10,878] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Received fatal alert: handshake_failure. Retrying after 15 seconds...
[2017-05-12 05:38:25,940] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Received fatal alert: handshake_failure. Retrying after 15 seconds...
[2017-05-12 05:38:25,940] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Received fatal alert: handshake_failure. Retrying after 15 seconds...
Can anyone tell me what could have i done wrong..May be i did some configuration wrong.Where should i check to find the problem?
Can it be because of SSL issues? I have not yet set up SSL.

Yes, this seems to be from SSL handshake failure specially since you have used hostnames. The default certificates that come with WSO2 Servers are created for localhost.
You can try creating self-signed certificates for APIM and IS hostnames. Then export the public certs of APIM to trust-store.jks of IS and vice versa. This should resolve the SSL handshake failure.
So what happens is when APIM boots up it makes an HTTP call to a web app in Key Manager (throttle data at KM_URL/throttle/data/v1/keyTemplates). APIM decides the URL of the KM from the URL configured in the api-manager.xml
You are seeing the error,
WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Received fatal alert: handshake_failure. Retrying after 15 seconds...
because the APIM cannot make this HTTP call retrieve throttle data from KM.

Related

Artifactory doesn't work after restoring nuget packages

When a team member restores nuget packages using donet, artifactory enters a loop with the errors below until the memory overflows.
The problem only happens when he adds in his Nuget.Config the tag protocolVersion="3"
<add key="Company" value="https://repo.company.com/artifactory/api/nuget/v3/rdi-nuget-virtual" protocolVersion="3" />
In the tests we noticed that the use of the protocolversion=3 tag causes this.
This tag is necessary because the download of the file is much faster
Anyone have an idea what it could be?
Could you help me please?
logs below
Version jfrog: 7.29.8 rev 72908900
2022-01-11T14:00:57.263Z [jfrt ] [WARN ] [6cdecc92eaf486c7] [.r.ArtifactoryResponseBase:136] [ttp-nio-8081-exec-43] - Sending HTTP error code 403: Download request for repo:path 'nuget-remote-cache:.nuGetV3/feed.json' is forbidden for user: 'lcunha'.
2022-01-11T14:00:57.264Z [jfrt ] [ERROR] [6cdecc92eaf486c7] [etV3VirtualAndRemoteCommon:274] [ttp-nio-8081-exec-43] - Failed to download resource in repo: nuget-remote, at url: https://api.nuget.org/v3/index.json. HTTP STATUS CODE: 403
2022-01-11T14:00:57.264Z [jfrt ] [ERROR] [6cdecc92eaf486c7] [etV3VirtualAndRemoteCommon:133] [ttp-nio-8081-exec-43] - Failed to convert artifactory url (https://repostaging.companysoftware.com:443/artifactory/api/nuget/v3/company-nuget-virtual/registration-semver2) to original remote url for repo: nuget-remote, package: xunit.core
java.lang.NullPointerException: null
at java.base/java.util.Objects.requireNonNull(Objects.java:221)
2022-01-11T14:01:56.786Z [jfrou] [ERROR] [2016c910242342cc] [external_topology.go:82 ] [main ] - Failed fetching external topology from Access: Get "http://localhost:8040/access/api/v1/topology": net/http: request canceled (Client.Timeout exceeded while awaiting headers)
2022-01-11T14:02:04.871Z [jfrou] [WARN ] [7f3fb3a30ade9665] [local_topology.go:268 ] [main ] - Readiness test failed with the following error: "required node services are missing or unhealthy"
2022-01-11T14:02:09.877Z [jfrou] [ERROR] [7f3fb3a30ade9665] [local_topology.go:128 ] [main ] - periodic send heartbeat failed for 4 consecutive times. Last error: failed sending heartbeat information to Access: failed closing Access grpc client: closing heartbeat client and waiting for response timed-out
java.lang.OutOfMemoryError: Java heap space
-XX:OnOutOfMemoryError="kill -9 %p"
Executing /bin/sh -c "kill -9 3974"...
2022-01-11T14:02:11.185Z [jfrou] [WARN ] [5a89519a8048b91d] [local_topology.go:268 ] [main ] - Readiness test failed with the following error: "required node services are missing or unhealthy"
2022-01-11T14:02:11.196Z [jfrou] [ERROR] [79bb63bc55c1ed15] [external_topology.go:82 ] [main ] - Failed fetching external topology from Access: Get "http://localhost:8040/access/api/v1/topology": read tcp 127.0.0.1:55970-127.0.0.1:8040: read: connection reset by peer
2022/01/11 14:02:11 httputil: ReverseProxy read error during body copy: read tcp 127.0.0.1:56788->127.0.0.1:8045: read: connection reset by peer
2022/01/11 14:02:11 httputil: ReverseProxy read error during body copy: read tcp 127.0.0.1:56788->127.0.0.1:8045: read: connection reset by peer
2022/01/11 14:02:11 httputil: ReverseProxy read error during body copy: read tcp 127.0.0.1:56788->127.0.0.1:8045: read: connection reset by peer
2022-01-11T14:02:11.208Z 35[jfob ] [WARN ] [1ed879c85a5af005] [access_join.go:70 ] [main ] - Refreshing platform config change events gRPC stream - target server is unavailable - if issue persists check communication with access [access_client]
/opt/jfrog/artifactory/app/bin/artifactory.sh: line 359: 3974 Killed $TOMCAT_HOME/bin/catalina.sh run
Can you share your setup?
-The application server is the CentOS Linux release 7.9.2009 (Core)
-MySQL as backend Database
-Also, we are using the Apache as reverse proxy to apply the SSL certificate.
How are you running Artifactory?
-The Artifactory is container based: releases-docker.jfrog.io/jfrog/artifactory-pro:7.29.8
How much resources to you give it? Memory and CPU
The server has allocated:
2 vCPU
16 GB RAM
SSD
What are the java memory settings? Mostly interested in heap settings (Xms and Xmx)?
We are using the standard configuration. No changes were made in the Xms and Xms parameters.
As you are using Artifactory v7.x? You may refer to our System Requirements wiki page for the recommended hardware based on your environment.
Also, from on the error message shared, it looks like the user does not have proper permissions hence we see 403 errors. Please do validate and assign the required permissions to the user and let us know the results.
Sending HTTP error code 403:
Download request for repo:
path 'nuget-remote-cache:.nuGetV3/feed.json' is forbidden for user: 'lcunha'.

Hyperledger fabric gateway is not able to get network

I am developing a Fabric application, and I am facing the issue where gateway is not able to get the network
366 | await gateway.connect(ccp, gatewayOpts);
367 | const network = await gateway.getNetwork(channelName);
| ^
368 | const contract = network.getContract(chaincodeName);
In Line number 367 I am facing an error
Following is the error :-
2021-07-24T13:39:03.866Z - error: [ServiceEndpoint]: Error: Failed to connect before the deadline on Endorser- name: peer0.org1.example.com, url:grpcs://localhost:7051, connected:false, connectAttempted:true
2021-07-24T13:39:03.867Z - error: [ServiceEndpoint]: waitForReady - Failed to connect to remote gRPC server peer0.org1.example.com url:grpcs://localhost:7051 timeout:3000
2021-07-24T13:39:03.893Z - info: [NetworkConfig]: buildPeer - Unable to connect to the endorser peer0.org1.example.com due to Error: Failed to connect before the deadline on Endorser- name: peer0.org1.example.com, url:grpcs://localhost:7051, connected:false, connectAttempted:true
at checkState (/home/user/Documents/Learnings/aries-learning/aries-javascript/aries-framework-javascript/node_modules/#grpc/grpc-js/src/client.ts:169:18)
at Timeout._onTimeout (/home/user/Documents/Learnings/aries-learning/aries-javascript/aries-framework-javascript/node_modules/#grpc/grpc-js/src/channel.ts:579:9)
at listOnTimeout (internal/timers.js:554:17)
at processTimers (internal/timers.js:497:7) {
connectFailed: true
}
2021-07-24T13:39:07.452Z - error: [ServiceEndpoint]: Error: Failed to connect before the deadline on Discoverer- name: peer0.org1.example.com, url:grpcs://localhost:7051, connected:false, connectAttempted:true
2021-07-24T13:39:07.452Z - error: [ServiceEndpoint]: waitForReady - Failed to connect to remote gRPC server peer0.org1.example.com url:grpcs://localhost:7051 timeout:3000
2021-07-24T13:39:07.453Z - error: [ServiceEndpoint]: ServiceEndpoint grpcs://localhost:7051 reset connection failed :: Error: Failed to connect before the deadline on Discoverer- name: peer0.org1.example.com, url:grpcs://localhost:7051, connected:false, connectAttempted:true
2021-07-24T13:39:07.453Z - error: [DiscoveryService]: send[mychannel] - no discovery results
Can anyone help me in resolving this?
Thanks
That can be many things, but is quite often a TLS issue. Check the peer logs. You may see a Bad TLS message, etc. Or notice that it does not have an attempt to contact it, so it might be dns, or more general connectivity issues.

Errors while starting WSO2 API Manager 2.1.0

I am getting errors and warnings while trying to bring up WSO2 API Manager 2.1.0 for the first time. [CentOS Linux release 7.3.1611 (Core)]. Excerpts are given below. I have already tried the suggestions at: Failed to start wso2 API Manager v2.0.0 on centos 7.0
$ ./wso2server.sh
JAVA_HOME environment variable is set to /usr/java/jdk1.8.0_60
CARBON_HOME environment variable is set to /home/devwso2/wso2am-2.1.0
Using Java memory options: -Xms256m -Xmx1024m
[2017-02-22 06:03:46,688] INFO - QpidBundleActivator Setting BundleContext in PluginManager
[2017-02-22 06:03:48,217] INFO - CarbonCoreActivator Starting WSO2 Carbon...
[2017-02-22 06:03:48,217] INFO - CarbonCoreActivator Operating System : Linux 3.10.0-514.6.1.el7.x86_64, amd64
[2017-02-22 06:03:48,218] INFO - CarbonCoreActivator Java Home : /usr/java/jdk1.8.0_60/jre
[2017-02-22 06:03:48,218] INFO - CarbonCoreActivator Java Version : 1.8.0_60
[2017-02-22 06:03:48,218] INFO - CarbonCoreActivator Java VM : Java HotSpot(TM) 64-Bit Server VM 25.60-b23,Oracle Corporation
[2017-02-22 06:03:48,218] INFO - CarbonCoreActivator Carbon Home : /home/devwso2/wso2am-2.1.0
[2017-02-22 06:03:48,218] INFO - CarbonCoreActivator Java Temp Dir : /home/devwso2/wso2am-2.1.0/tmp
[2017-02-22 06:03:48,218] INFO - CarbonCoreActivator User : devwso2, en-US, UTC
[2017-02-22 06:03:48,387] WARN - ValidationResultPrinter Swap Memory size (MB): 0 of the system is below the recommended minimum size :2047
[2017-02-22 06:03:48,389] WARN - ValidationResultPrinter Carbon is configured to use the default keystore (wso2carbon.jks). To maximize security when deploying to a production environment, configure a new keystore with a unique password in the production server profile.
.....................
[2017-02-22 06:04:46,407] ERROR - Main Exception during startup. Triggering shutdown
org.wso2.andes.kernel.AndesException: Unable to initialise application registry
at org.wso2.andes.server.Broker.startupImpl(Broker.java:308)
at org.wso2.andes.server.Broker.startup(Broker.java:110)
at org.wso2.andes.server.Main.startBroker(Main.java:217)
at org.wso2.andes.server.Main.execute(Main.java:206)
at org.wso2.andes.server.Main.<init>(Main.java:54)
at org.wso2.andes.server.Main.main(Main.java:47)
at org.wso2.carbon.andes.internal.QpidServiceComponent.startAndesBroker(QpidServiceComponent.java:420)
at org.wso2.carbon.andes.internal.QpidServiceComponent.activate(QpidServiceComponent.java:165)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.eclipse.equinox.internal.ds.model.ServiceComponent.activate(ServiceComponent.java:260)
at org.eclipse.equinox.internal.ds.model.ServiceComponentProp.activate(ServiceComponentProp.java:146)
at org.eclipse.equinox.internal.ds.model.ServiceComponentProp.build(ServiceComponentProp.java:345)
at org.eclipse.equinox.internal.ds.InstanceProcess.buildComponent(InstanceProcess.java:620)
at org.eclipse.equinox.internal.ds.InstanceProcess.buildComponents(InstanceProcess.java:197)
at org.eclipse.equinox.internal.ds.Resolver.getEligible(Resolver.java:343)
at org.eclipse.equinox.internal.ds.SCRManager.serviceChanged(SCRManager.java:222)
at org.eclipse.osgi.internal.serviceregistry.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:107)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:861)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148)
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEventPrivileged(ServiceRegistry.java:819)
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEvent(ServiceRegistry.java:771)
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:130)
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:214)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:433)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:451)
at org.wso2.carbon.server.admin.internal.ServerAdminServiceComponent.activate(ServerAdminServiceComponent.java:106)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.eclipse.equinox.internal.ds.model.ServiceComponent.activate(ServiceComponent.java:260)
at org.eclipse.equinox.internal.ds.model.ServiceComponentProp.activate(ServiceComponentProp.java:146)
at org.eclipse.equinox.internal.ds.model.ServiceComponentProp.build(ServiceComponentProp.java:345)
at org.eclipse.equinox.internal.ds.InstanceProcess.buildComponent(InstanceProcess.java:620)
at org.eclipse.equinox.internal.ds.InstanceProcess.buildComponents(InstanceProcess.java:197)
at org.eclipse.equinox.internal.ds.Resolver.getEligible(Resolver.java:343)
at org.eclipse.equinox.internal.ds.SCRManager.serviceChanged(SCRManager.java:222)
at org.eclipse.osgi.internal.serviceregistry.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:107)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:861)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148)
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEventPrivileged(ServiceRegistry.java:819)
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEvent(ServiceRegistry.java:771)
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:130)
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:214)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:433)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:451)
at org.wso2.carbon.core.init.CarbonServerManager.initializeCarbon(CarbonServerManager.java:514)
at org.wso2.carbon.core.init.CarbonServerManager.start(CarbonServerManager.java:219)
at org.wso2.carbon.core.internal.CarbonCoreServiceComponent.activate(CarbonCoreServiceComponent.java:94)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.eclipse.equinox.internal.ds.model.ServiceComponent.activate(ServiceComponent.java:260)
at org.eclipse.equinox.internal.ds.model.ServiceComponentProp.activate(ServiceComponentProp.java:146)
at org.eclipse.equinox.internal.ds.model.ServiceComponentProp.build(ServiceComponentProp.java:345)
at org.eclipse.equinox.internal.ds.InstanceProcess.buildComponent(InstanceProcess.java:620)
at org.eclipse.equinox.internal.ds.InstanceProcess.buildComponents(InstanceProcess.java:197)
at org.eclipse.equinox.internal.ds.Resolver.getEligible(Resolver.java:343)
at org.eclipse.equinox.internal.ds.SCRManager.serviceChanged(SCRManager.java:222)
at org.eclipse.osgi.internal.serviceregistry.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:107)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:861)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148)
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEventPrivileged(ServiceRegistry.java:819)
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEvent(ServiceRegistry.java:771)
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:130)
at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:214)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:433)
at org.eclipse.equinox.http.servlet.internal.Activator.registerHttpService(Activator.java:81)
at org.eclipse.equinox.http.servlet.internal.Activator.addProxyServlet(Activator.java:60)
at org.eclipse.equinox.http.servlet.internal.ProxyServlet.init(ProxyServlet.java:40)
at org.wso2.carbon.tomcat.ext.servlet.DelegationServlet.init(DelegationServlet.java:38)
at org.apache.catalina.core.StandardWrapper.initServlet(StandardWrapper.java:1269)
at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1182)
at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1072)
at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:5368)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5660)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1571)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1561)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: org.wso2.andes.transport.TransportException: Could not bind to /0.0.0.0:5672
at org.wso2.andes.transport.network.mina.MinaNetworkTransport.accept(MinaNetworkTransport.java:147)
at org.wso2.andes.server.Broker.startAMQPListener(Broker.java:201)
at org.wso2.andes.server.Broker.startupImpl(Broker.java:295)
... 89 more
Caused by: java.net.BindException: Address already in use
at sun.nio.ch.Net.bind0(Native Method)
at sun.nio.ch.Net.bind(Net.java:433)
at sun.nio.ch.Net.bind(Net.java:425)
at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:223)
at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:74)
at org.apache.mina.transport.socket.nio.SocketAcceptor.registerNew(SocketAcceptor.java:363)
at org.apache.mina.transport.socket.nio.SocketAcceptor.access$800(SocketAcceptor.java:55)
at org.apache.mina.transport.socket.nio.SocketAcceptor$Worker.run(SocketAcceptor.java:222)
at org.apache.mina.util.NamePreservingRunnable.run(NamePreservingRunnable.java:51)
... 1 more
[2017-02-22 06:04:46,415] INFO - ApplicationRegistry Shutting down ApplicationRegistry(org.wso2.andes.server.registry.ConfigurationFileApplicationRegistry#1524f58a)
[2017-02-22 06:04:46,415] INFO - ApplicationRegistry Shutting down ApplicationRegistry:org.wso2.andes.server.registry.ConfigurationFileApplicationRegistry#1524f58a
[2017-02-22 06:04:46,418] INFO - PrincipalDatabaseAuthenticationManager Unregistering UserManagementMBean
[2017-02-22 06:04:46,421] INFO - CarbonServerManager Shutdown hook triggered....
[2017-02-22 06:04:46,426] INFO - CarbonServerManager Gracefully shutting down WSO2 API Manager...
[2017-02-22 06:04:46,428] INFO - ServerManagement Starting to switch to maintenance mode...
[2017-02-22 06:04:46,429] INFO - ServerManagement Stopped all transport listeners
[2017-02-22 06:04:46,429] INFO - ServerManagement Waiting for request service completion...
[2017-02-22 06:04:46,435] INFO - ServerManagement All requests have been served.
[2017-02-22 06:04:46,435] INFO - ServerManagement Waiting for deployment completion...
[2017-02-22 06:04:46,491] INFO - WebApplication Unloaded webapp: StandardEngine[Catalina].StandardHost[localhost].StandardContext[/api/am/admin/v0.11]
[2017-02-22 06:04:46,536] INFO - WebApplication Unloaded webapp: StandardEngine[Catalina].StandardHost[localhost].StandardContext[/throttle/data/v1]
[2017-02-22 06:04:46,566] INFO - WebApplication Unloaded webapp: StandardEngine[Catalina].StandardHost[localhost].StandardContext[/am/sample/calculator/v1]
[2017-02-22 06:04:46,627] INFO - WebApplication Unloaded webapp: StandardEngine[Catalina].StandardHost[localhost].StandardContext[/shindig]
[2017-02-22 06:04:46,653] INFO - WebApplication Unloaded webapp: StandardEngine[Catalina].StandardHost[localhost].StandardContext[/api/am/publisher/v0.11]
[2017-02-22 06:04:46,682] INFO - WebApplication Unloaded webapp: StandardEngine[Catalina].StandardHost[localhost].StandardContext[/api/am/store/v0.11]
[2017-02-22 06:04:46,699] INFO - WebApplication Unloaded webapp: StandardEngine[Catalina].StandardHost[localhost].StandardContext[/authenticationendpoint]
[2017-02-22 06:04:46,719] INFO - WebApplication Unloaded webapp: StandardEngine[Catalina].StandardHost[localhost].StandardContext[/oauth2]
[2017-02-22 06:04:46,735] INFO - WebApplication Unloaded webapp: StandardEngine[Catalina].StandardHost[localhost].StandardContext[/am/sample/pizzashack/v1]
[2017-02-22 06:04:46,756] INFO - WebApplication Unloaded webapp: StandardEngine[Catalina].StandardHost[localhost].StandardContext[/client-registration/v0.11]
[2017-02-22 06:04:46,764] INFO - WebApplication Unloaded webapp: StandardEngine[Catalina].StandardHost[localhost].StandardContext[/admin]
[2017-02-22 06:04:46,775] INFO - WebApplication Unloaded webapp: StandardEngine[Catalina].StandardHost[localhost].StandardContext[/portal]
[2017-02-22 06:04:46,783] INFO - WebApplication Unloaded webapp: StandardEngine[Catalina].StandardHost[localhost].StandardContext[/store]
[2017-02-22 06:04:46,791] INFO - WebApplication Unloaded webapp: StandardEngine[Catalina].StandardHost[localhost].StandardContext[/publisher]
[2017-02-22 06:04:46,791] INFO - ServerManagement All deployment tasks have been completed.
[2017-02-22 06:04:46,791] INFO - ServerManagement Waiting for server task completion...
[2017-02-22 06:04:46,805] INFO - ServerManagement All server tasks have been completed.
[2017-02-22 06:04:46,805] INFO - CarbonServerManager Shutting down WSO2 API Manager...
[2017-02-22 06:04:46,811] INFO - CarbonServerManager Shutting down OSGi framework...
[2017-02-22 06:04:54,812] INFO - CarbonEventManagementService Starting polling event receivers
[2017-02-22 06:05:15,404] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:05:15,412] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:05:17,532] WARN - AppDeployerServiceComponent Waiting for required OSGi services: org.wso2.carbon.application.deployer.synapse.service.SynapseAppDeployerService,
[2017-02-22 06:05:17,545] WARN - StartupFinalizerServiceComponent Waiting for required OSGi services: org.wso2.carbon.application.deployer.service.CappDeploymentService,org.wso2.carbon.server.admin.common.IServerAdmin,org.wso2.carbon.throttling.agent.ThrottlingAgent,
[2017-02-22 06:05:30,413] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:05:30,418] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:05:44,927] WARN - SynapseAppDeployerDSComponent Waiting for required OSGi services: org.wso2.carbon.message.processor.service.MessageProcessorDeployerService,org.wso2.carbon.message.store.service.MessageStoreDeployerService,org.wso2.carbon.proxyadmin.service.ProxyDeployerService,
[2017-02-22 06:05:45,415] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:05:45,420] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:06:00,419] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:06:00,421] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:06:15,422] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:06:15,423] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:06:17,531] WARN - AppDeployerServiceComponent Waiting for required OSGi services: org.wso2.carbon.application.deployer.synapse.service.SynapseAppDeployerService,
[2017-02-22 06:06:17,546] WARN - StartupFinalizerServiceComponent Waiting for required OSGi services: org.wso2.carbon.application.deployer.service.CappDeploymentService,org.wso2.carbon.server.admin.common.IServerAdmin,org.wso2.carbon.throttling.agent.ThrottlingAgent,
[2017-02-22 06:06:30,425] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:06:30,426] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:06:44,926] WARN - SynapseAppDeployerDSComponent Waiting for required OSGi services: org.wso2.carbon.message.processor.service.MessageProcessorDeployerService,org.wso2.carbon.message.store.service.MessageStoreDeployerService,org.wso2.carbon.proxyadmin.service.ProxyDeployerService,
[2017-02-22 06:06:45,428] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:06:45,428] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:07:00,430] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:07:00,431] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:07:15,434] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:07:15,434] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:07:17,531] WARN - AppDeployerServiceComponent Waiting for required OSGi services: org.wso2.carbon.application.deployer.synapse.service.SynapseAppDeployerService,
[2017-02-22 06:07:17,545] WARN - StartupFinalizerServiceComponent Waiting for required OSGi services: org.wso2.carbon.application.deployer.service.CappDeploymentService,org.wso2.carbon.server.admin.common.IServerAdmin,org.wso2.carbon.throttling.agent.ThrottlingAgent,
[2017-02-22 06:07:30,438] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:07:30,438] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:07:36,930] INFO - SynapseTaskManager Shutting down the task manager
[2017-02-22 06:07:44,926] WARN - SynapseAppDeployerDSComponent Waiting for required OSGi services: org.wso2.carbon.message.processor.service.MessageProcessorDeployerService,org.wso2.carbon.message.store.service.MessageStoreDeployerService,org.wso2.carbon.proxyadmin.service.ProxyDeployerService,
[2017-02-22 06:07:45,440] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:07:45,442] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:08:00,444] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:08:00,445] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:08:15,452] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:08:15,452] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:08:17,531] WARN - AppDeployerServiceComponent Waiting for required OSGi services: org.wso2.carbon.application.deployer.synapse.service.SynapseAppDeployerService,
[2017-02-22 06:08:17,545] WARN - StartupFinalizerServiceComponent Waiting for required OSGi services: org.wso2.carbon.application.deployer.service.CappDeploymentService,org.wso2.carbon.server.admin.common.IServerAdmin,org.wso2.carbon.throttling.agent.ThrottlingAgent,
[2017-02-22 06:08:30,456] WARN - KeyTemplateRetriever Failed retrieving throttling data from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:08:30,456] WARN - BlockingConditionRetriever Failed retrieving Blocking Conditions from remote endpoint: Connection refused. Retrying after 15 seconds...
[2017-02-22 06:08:44,927] WARN - SynapseAppDeployerDSComponent Waiting for required OSGi services: org.wso2.carbon.message.processor.service.MessageProcessorDeployerService,org.wso2.carbon.message.store.service.MessageStoreDeployerService,org.wso2.carbon.proxyadmin.service.ProxyDeployerService,
[2017-02-22 06:08:45,458] ERROR - BlockingConditionRetriever Exception when retrieving Blocking Conditions from remote endpoint
java.net.ConnectException: Connection refused
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:589)
at sun.security.ssl.SSLSocketImpl.connect(SSLSocketImpl.java:668)
at org.apache.http.conn.ssl.SSLSocketFactory.connectSocket(SSLSocketFactory.java:522)
at org.apache.http.conn.ssl.SSLSocketFactory.connectSocket(SSLSocketFactory.java:401)
at org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:178)
at org.apache.http.impl.conn.AbstractPoolEntry.open(AbstractPoolEntry.java:144)
at org.apache.http.impl.conn.AbstractPooledConnAdapter.open(AbstractPooledConnAdapter.java:131)
at org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:610)
at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:445)
at org.apache.http.impl.client.AbstractHttpClient.doExecute(AbstractHttpClient.java:863)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:82)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:106)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:57)
at org.wso2.carbon.apimgt.gateway.throttling.util.BlockingConditionRetriever.retrieveBlockConditionsData(BlockingConditionRetriever.java:79)
at org.wso2.carbon.apimgt.gateway.throttling.util.BlockingConditionRetriever.loadBlockingConditionsFromWebService(BlockingConditionRetriever.java:105)
at org.wso2.carbon.apimgt.gateway.throttling.util.BlockingConditionRetriever.run(BlockingConditionRetriever.java:51)
at java.util.TimerThread.mainLoop(Timer.java:555)
at java.util.TimerThread.run(Timer.java:505)
[2017-02-22 06:08:45,458] ERROR - KeyTemplateRetriever Exception when retrieving throttling data from remote endpoint
java.net.ConnectException: Connection refused
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:589)
at sun.security.ssl.SSLSocketImpl.connect(SSLSocketImpl.java:668)
at org.apache.http.conn.ssl.SSLSocketFactory.connectSocket(SSLSocketFactory.java:522)
at org.apache.http.conn.ssl.SSLSocketFactory.connectSocket(SSLSocketFactory.java:401)
at org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:178)
at org.apache.http.impl.conn.AbstractPoolEntry.open(AbstractPoolEntry.java:144)
at org.apache.http.impl.conn.AbstractPooledConnAdapter.open(AbstractPooledConnAdapter.java:131)
at org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:610)
at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:445)
at org.apache.http.impl.client.AbstractHttpClient.doExecute(AbstractHttpClient.java:863)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:82)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:106)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:57)
at org.wso2.carbon.apimgt.gateway.throttling.util.KeyTemplateRetriever.retrieveKeyTemplateData(KeyTemplateRetriever.java:83)
at org.wso2.carbon.apimgt.gateway.throttling.util.KeyTemplateRetriever.loadKeyTemplatesFromWebService(KeyTemplateRetriever.java:111)
at org.wso2.carbon.apimgt.gateway.throttling.util.KeyTemplateRetriever.run(KeyTemplateRetriever.java:54)
at java.util.TimerThread.mainLoop(Timer.java:555)
at java.util.TimerThread.run(Timer.java:505)
Exception in thread "Timer-5" java.lang.NullPointerException
at java.util.Objects.requireNonNull(Objects.java:203)
at java.util.Arrays$ArrayList.<init>(Arrays.java:3813)
at java.util.Arrays.asList(Arrays.java:3800)
at org.wso2.carbon.apimgt.gateway.throttling.util.KeyTemplateRetriever.loadKeyTemplatesFromWebService(KeyTemplateRetriever.java:111)
at org.wso2.carbon.apimgt.gateway.throttling.util.KeyTemplateRetriever.run(KeyTemplateRetriever.java:54)
at java.util.TimerThread.mainLoop(Timer.java:555)
at java.util.TimerThread.run(Timer.java:505)
[2017-02-22 06:09:16,963] INFO - BinaryDataReceiverServiceComponent Binary Data Receiver server shutting down...
[2017-02-22 06:09:16,964] INFO - BinaryDataReceiver Stopping Binary Server..
[2017-02-22 06:09:17,531] WARN - AppDeployerServiceComponent Waiting for required OSGi services: org.wso2.carbon.application.deployer.synapse.service.SynapseAppDeployerService
I was running Java 17 SDK and got this same problem. Solved this by running the WSO2 script with Java 11 SDK instead.
You can either :
Change your JAVA_HOME variable value
Create a new environment variable pointing to Java 11 SDK and replace recursively inside the WSO2 directory JAVA_HOME with the new environment variable you have created
This is because port 5672 is occupied at the time when the API Manager server starts up. You can have 2 options I can think of to proceed with,
Change the default port offset.
You can either start the API manager server with -DportOffset=[offset] (ex- -DportOffset=1) or change the value in /repository/conf to a value other than 0 and start the server.
Stop the existing process of already occupied server
Without worrying about port offset, you can run the API Manager server on 5672 port for AMQP transport.
Search the process of occupied port (5672 in this case)
netstat -nlp|grep 5672
Output should looks like something below
tcp 0 0 0.0.0.0:5672 0.0.0.0:* LISTEN 6187/java
Kill the process
kill -9 [Process_ID]
(here, 6187)
Then start the server and you won't see the exception anymore.
I was trying from long time. RMQ was running in my system.
Got to C:\Program Files (x86)\RabbitMQ Server\rabbitmq_server-3.3.4\sbin and run
rabbitmq-service.bat stop
Port 5672 is needed for API Manager, from your exception trace, that port is occupied by another process.
Normally RabbitMQ uses 5672, if that's the case you have to shut down that process. If you have another API Manager running on the physical node, then you have to offset the port with -DportOffset=1
There's a problem with your port 5672,this port is already in use by some other process. So shutdown your wso2 process by ps -ef|grep wso2 and then kill -9 .
Then change your port by following this link and start wso2 api manager again.
https://docs.wso2.com/display/AM200/Changing+the+Default+Ports+with+Offset
As Tanvi and Abimaran said, Port 5672 is used for queuing. It's very common to get this error when configuring two nodes in one machine for trying cluster. If this port has been used by another application, and you can't shut that application down, then you can change
connectionfactory.TopicConnectionFactory = amqp://admin:admin#clientid/carbon?brokerlist='tcp://localhost:5672'
connectionfactory.QueueConnectionFactory = amqp://admin:admin#clientID/test?brokerlist='tcp://localhost:5672'
to another port for API manager in (/repository/config/jndi.properties).
You could change the default ports with an offset. So go to :
deployment.toml
and for example change the following config:
[server]
offset=1
so port no 5672 will be change to 5673.

ERROR when sending data to my KAA server

When using first kaa server application and sending data to my Kaa server from outside I get this error: CONNACK message + KAASYNC message.
My configuration for kaa server is:
transport host...=localhost=My PUBLIC ip
My config mongo on kaa server is:
host: MY PUBLIC IP port: 27017
THIS IS WHAT I GET WHEN I COMPILE MY SDK
[pool-2-thread-1] INFO org.kaaproject.kaa.client.channel.failover.DefaultFailoverManager - Server [BOOTSTRAP, -1835393002] failed
[pool-2-thread-1] WARN org.kaaproject.kaa.client.channel.impl.DefaultChannelManager - Attempt to connect to the next bootstrap service will be made in 2000 ms, according to failover strategy decision
[pool-1-thread-1] INFO FirstKaaDemo - Sampled Temperature: 34
[pool-4-thread-14] INFO org.kaaproject.kaa.client.logging.strategies.RecordCountLogUploadStrategy - Need to upload logs - current count: 14, threshold: 1
[Thread-2] INFO org.kaaproject.kaa.client.channel.impl.channels.DefaultOperationTcpChannel - Can't sync. Channel [default_operation_tcp_channel] is waiting for CONNACK message + KAASYNC message
[pool-6-thread-1] INFO org.kaaproject.kaa.client.channel.impl.channels.AbstractHttpChannel - Processing sync all for channel default_bootstrap_channel
[pool-1-thread-1] INFO FirstKaaDemo - Sampled Temperature: 25
[pool-4-thread-15] INFO org.kaaproject.kaa.client.logging.strategies.RecordCountLogUploadStrategy - Need to upload logs - current count: 15, threshold: 1
[Thread-2] INFO org.kaaproject.kaa.client.channel.impl.channels.DefaultOperationTcpChannel - Can't sync. Channel [default_operation_tcp_channel] is waiting for CONNACK message + KAASYNC message
Step 1: Change Kaa Host/IP
To VM ip address. My case is 192.168.1.142
Step 2: Regenerate SDK and recompide and run. Done

Async Data Publisher Error

My WSO2 API Manager is logging continuously below logs. How to resolve this.
[2016-06-10 02:12:47,630] ERROR - AsyncDataPublisher Reconnection failed for for tcp://localhost:7612
[2016-06-10 02:13:17,852] ERROR - AsyncDataPublisher Reconnection failed for for tcp://localhost:7612
[2016-06-10 02:13:47,798] ERROR - AsyncDataPublisher Reconnection failed for for tcp://localhost:7612

Resources