liangyuanpeng commented on issue #5348: Load tls file fail on Windows
URL: https://github.com/apache/pulsar/issues/5348#issuecomment-541054996
 
 
   @merlimat 
   Yes, you are right and it solved my TLS problem´╝üThank you 
   
   But, new wrong and can you help me?  thanks!
   
   ```
   01:17:01.451 [main] INFO  org.apache.pulsar.PulsarBrokerStarter - 
PulsarService started.
   01:17:06.427 [pulsar-load-manager-4-1] INFO  
org.apache.pulsar.broker.loadbalance.impl.ModularLoadManagerImpl - Writing 
local data to ZooKeeper because maximum change 16.146893799304962% exceeded 
threshold 10%; time since last report written is 9.862 seconds
   01:17:06.496 [pulsar-ordered-OrderedExecutor-0-0-EventThread] INFO  
org.apache.pulsar.zookeeper.ZooKeeperDataCache - [State:CONNECTED Timeout:30000 
sessionid:0x100011c11560006 local:/192.168.1.11:47124 
remoteserver:192.168.1.11/192.168.1.11:2181 lastZxid:241 xid:48 sent:48 recv:49 
queuedpkts:0 pendingresp:0 queuedevents:0] Received ZooKeeper watch event: 
WatchedEvent state:SyncConnected type:NodeDataChanged 
path:/loadbalance/brokers/192.168.1.11:8080
   01:17:32.931 [pulsar-io-22-1] INFO  
org.apache.pulsar.broker.service.ServerCnx - New connection from 
/192.168.1.8:53104
   01:17:32.949 [pulsar-io-22-1] WARN  
org.apache.pulsar.broker.service.ServerCnx - [/192.168.1.8:53104] Got exception 
TooLongFrameException : Adjusted frame length exceeds 5253120: 369296132 - 
discarded
   io.netty.handler.codec.TooLongFrameException: Adjusted frame length exceeds 
5253120: 369296132 - discarded
           at 
io.netty.handler.codec.LengthFieldBasedFrameDecoder.fail(LengthFieldBasedFrameDecoder.java:522)
 ~[io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
           at 
io.netty.handler.codec.LengthFieldBasedFrameDecoder.failIfNecessary(LengthFieldBasedFrameDecoder.java:500)
 ~[io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
           at 
io.netty.handler.codec.LengthFieldBasedFrameDecoder.exceededFrameLength(LengthFieldBasedFrameDecoder.java:387)
 ~[io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
           at 
io.netty.handler.codec.LengthFieldBasedFrameDecoder.decode(LengthFieldBasedFrameDecoder.java:430)
 ~[io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
           at 
io.netty.handler.codec.LengthFieldBasedFrameDecoder.decode(LengthFieldBasedFrameDecoder.java:343)
 ~[io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
           at 
io.netty.handler.codec.ByteToMessageDecoder.decodeRemovalReentryProtection(ByteToMessageDecoder.java:502)
 ~[io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
           at 
io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:441)
 ~[io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
           at 
io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:278)
 ~[io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
           at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:362)
 [io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
           at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:348)
 [io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
           at 
io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:340)
 [io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
           at 
io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1434)
 [io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
           at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:362)
 [io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
           at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:348)
 [io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
           at 
io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:965)
 [io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
           at 
io.netty.channel.epoll.AbstractEpollStreamChannel$EpollStreamUnsafe.epollInReady(AbstractEpollStreamChannel.java:799)
 [io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
           at 
io.netty.channel.epoll.EpollEventLoop.processReady(EpollEventLoop.java:433) 
[io.netty-netty-all-4.1.32.Final.jar:4.1.32.Final]
   ```
   
   and my code
   
   ```
           String localClusterUrl = "pulsar+ssl://192.168.1.11:6650";
   
           PulsarClient client = PulsarClient.builder()
                   .tlsTrustCertsFilePath("H:\\pulsar\\ssl\\1.11\\ca.cert.pem")
   //                
.authentication("org.apache.pulsar.client.impl.auth.AuthenticationTls","tlsCertFile:H:\\pulsar\\ssl\\1.11\\admin.cert.pem,tlsKeyFile:H:\\pulsar\\ssl\\1.11\\admin.key-pk8.pem")
                   
.authentication(AuthenticationFactory.TLS("H:\\pulsar\\ssl\\1.11\\admin.cert.pem","H:\\pulsar\\ssl\\1.11\\admin.key-pk8.pem"))
                   .serviceUrl(localClusterUrl)
                   .build();
           Producer<byte[]> producer = 
client.newProducer().topic("persistent://public/default/topic-1").create();
   
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to