[GitHub] [pulsar] liangyuanpeng commented on issue #5348: Load tls file fail on Windows

2019-10-14 Thread GitBox
liangyuanpeng commented on issue #5348: Load tls file fail on Windows
URL: https://github.com/apache/pulsar/issues/5348#issuecomment-541771171
 
 
   @merlimat 
   
   Thanks,Just solved the problem,
   
   I realized what a fool I was
   
   Now,i got the error
   
   ``
   org.apache.pulsar.broker.PulsarServerException: 
org.apache.pulsar.broker.PulsarServerException: 
java.lang.IllegalArgumentException: Private key must be accompanied by 
certificate chain
   ``
   I am checking my configuration
   
   If this is a silly question, I'm sorry for that


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


[GitHub] [pulsar] liangyuanpeng commented on issue #5348: Load tls file fail on Windows

2019-10-14 Thread GitBox
liangyuanpeng commented on issue #5348: Load tls file fail on Windows
URL: https://github.com/apache/pulsar/issues/5348#issuecomment-541754848
 
 
   Update, I confirm that my problem is on configuring TLS transport
   
   and can i not use proxy?
   
   Actually, I tried to start proxy,but i just got error
   
   ```
   23:40:17.052 [main] INFO  
org.apache.pulsar.broker.authorization.AuthorizationService - Authorization is 
disabled
   2019-10-14 11:40:17,127 [sun.misc.Launcher$AppClassLoader@58d25a40] error 
Uncaught exception in thread main: Failed to bind Pulsar Proxy on port 6650
   ```
   
   and my ``proxy.conf``
   
   ```
   # The ZooKeeper quorum connection string (as a comma-separated list)
   zookeeperServers=192.168.1.11
   
   # Configuration store connection string (as a comma-separated list)
   configurationStoreServers=192.168.1.11
   
   # if Service Discovery is Disabled this url should point to the discovery 
service provider.
   brokerServiceURL=pulsar://192.168.1.11:6650
   brokerServiceURLTLS=
   
   # These settings are unnecessary if `zookeeperServers` is specified
   brokerWebServiceURL=http://192.168.1.11:8080
   brokerWebServiceURLTLS=
   ```
   
   


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


[GitHub] [pulsar] liangyuanpeng commented on issue #5348: Load tls file fail on Windows

2019-10-12 Thread GitBox
liangyuanpeng commented on issue #5348: Load tls file fail on Windows
URL: https://github.com/apache/pulsar/issues/5348#issuecomment-541346952
 
 
   
   I tried several times and failed to create a consumer or producer
   
   ``
   org.apache.pulsar.client.impl.ProducerBuilderImpl#create
   ``
   
   ``
   org.apache.pulsar.client.impl.ConsumerBuilderImpl#subscribe
   ``
   
   This is confusing to me


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


[GitHub] [pulsar] liangyuanpeng commented on issue #5348: Load tls file fail on Windows

2019-10-11 Thread GitBox
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:3 
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"))