Hi Isuru,

Yes, That was the cause thank you for pointing it out. However, In the
puppet script DataPublisher is set to false [2]. We will need to fix this
in the script IMO. Created a git issue to fix it in puppet scripts [2] and
to handle it gracefully in apim side [3].

[1] https://github.com/wso2/puppet-apim/blob/v2.1.0/
wso2am_runtime/hieradata/dev/wso2/wso2am_runtime/pattern-6/
gateway-manager.yaml#L98
[2] https://github.com/wso2/puppet-apim/issues/63
[3] https://github.com/wso2/product-apim/issues/2630

Regards,
Jason

Jason De Silva
*Software Engineer - QA*
Mobile: +94 (0) 772 097 678
Email: [email protected]
WSO2 Inc. www.wso2.com
<http://wso2.com/signature>

On Fri, Jan 26, 2018 at 8:14 PM, Isuru Haththotuwa <[email protected]> wrote:

> You have set DataPublisher.Enabled to false, need to set it to true.
>
> On Fri, Jan 26, 2018 at 8:02 PM, Jason De Silva <[email protected]> wrote:
>
>> Hi All,
>>
>> We have configured APIM 2.1.0 cluster (pattern 6) via puppet referring
>> the doc at [3]. We are encountering the below NPE [2] for each API
>> invocation. We are using a wum updated 2.1.0 pack. Below is the relevant
>> "ThrottlingConfigurations" [1] of api-manager.xml.
>> What can be the cause for this?
>>
>> [1]
>> <ThrottlingConfigurations>
>>         <EnableAdvanceThrottling>true</EnableAdvanceThrottling>
>>         <DataPublisher>
>>             <Enabled>false</Enabled>
>>             <Type>Binary</Type>
>>                 <ReceiverUrlGroup>tcp://tm.dev.wso2.org:9611
>> </ReceiverUrlGroup>
>>                 <AuthUrlGroup>ssl://tm.dev.wso2.org:9711</AuthUrlGroup>
>>                 <Username>admin</Username>
>>                 <Password>admin</Password>
>>             <DataPublisherPool>
>>                 <MaxIdle>1000</MaxIdle>
>>                 <InitIdleCapacity>200</InitIdleCapacity>
>>             </DataPublisherPool>
>>             <DataPublisherThreadPool>
>>                 <CorePoolSize>200</CorePoolSize>
>>                 <MaxmimumPoolSize>1000</MaxmimumPoolSize>
>>                 <KeepAliveTime>200</KeepAliveTime>
>>             </DataPublisherThreadPool>
>>         </DataPublisher>
>>         <PolicyDeployer>
>>             <ServiceURL>https://tm.dev.wso2.org:9443/services/</ServiceU
>> RL>
>>             <Username>admin</Username>
>>           <Password>admin</Password>
>>         </PolicyDeployer>
>>   ....
>>
>>
>> [2]
>> TID: [-1234] [] [2018-01-26 14:07:41,822] ERROR
>> {org.wso2.carbon.apimgt.gateway.throttling.publisher.ThrottleDataPublisher}
>> -  Error while publishing throttling events to global policy server
>> {org.wso2.carbon.apimgt.gateway.throttling.publisher.Throttl
>> eDataPublisher}
>> java.lang.NullPointerException
>>     at org.wso2.carbon.apimgt.gateway.throttling.publisher.Throttle
>> DataPublisher.publishNonThrottledEvent(ThrottleDataPublisher.java:119)
>>     at org.wso2.carbon.apimgt.gateway.handlers.throttling.ThrottleH
>> andler.doRoleBasedAccessThrottlingWithCEP(ThrottleHandler.java:349)
>>     at org.wso2.carbon.apimgt.gateway.handlers.throttling.ThrottleH
>> andler.doThrottle(ThrottleHandler.java:512)
>>     at org.wso2.carbon.apimgt.gateway.handlers.throttling.ThrottleH
>> andler.handleRequest(ThrottleHandler.java:460)
>>     at org.apache.synapse.rest.API.process(API.java:325)
>>     at org.apache.synapse.rest.RESTRequestHandler.dispatchToAPI(RES
>> TRequestHandler.java:90)
>>     at org.apache.synapse.rest.RESTRequestHandler.process(RESTReque
>> stHandler.java:69)
>>     at org.apache.synapse.core.axis2.Axis2SynapseEnvironment.inject
>> Message(Axis2SynapseEnvironment.java:304)
>>     at org.apache.synapse.core.axis2.SynapseMessageReceiver.receive
>> (SynapseMessageReceiver.java:78)
>>     at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:180)
>>     at org.apache.synapse.transport.passthru.ServerWorker.processNo
>> nEntityEnclosingRESTHandler(ServerWorker.java:330)
>>     at org.apache.synapse.transport.passthru.ServerWorker.run(Serve
>> rWorker.java:159)
>>     at org.apache.axis2.transport.base.threads.NativeWorkerPool$1.
>> run(NativeWorkerPool.java:172)
>>     at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPool
>> Executor.java:1142)
>>     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoo
>> lExecutor.java:617)
>>     at java.lang.Thread.run(Thread.java:745)
>>
>> [3] https://docs.wso2.com/display/AM2xx/Using+Puppet+Modules+to+
>> Set+up+WSO2+API-M+with+Pattern+6#0abc8ab76a4d4ddfaa7faf25e4b39cba
>>
>> Jason De Silva
>> *Software Engineer - QA*
>> Mobile: +94 (0) 772 097 678
>> Email: [email protected]
>> WSO2 Inc. www.wso2.com
>> <http://wso2.com/signature>
>>
>
>
>
> --
> Thanks and Regards,
>
> Isuru H.
> +94 716 358 048 <+94%2071%20635%208048>* <http://wso2.com/>*
>
>
>
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to