You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2023/01/06 14:06:19 UTC
[GitHub] [pulsar-client-node] ericallam opened a new issue, #281: Failed to create producer: ConnectError when upgrading to 1.8.0
ericallam opened a new issue, #281:
URL: https://github.com/apache/pulsar-client-node/issues/281
Hi there, I'm just attempting to upgrade to 1.8.0 (from 1.7.0) and I'm now getting a `Failed to create producer: ConnectError` error when creating a producer. If I downgrade back to 1.7.0 the same code works fine.
```ts
const client = new Pulsar.Client({
serviceUrl: "pulsar+ssl://<cluster>.<namespace>.snio.cloud:6651",
authentication: new AuthenticationOauth2({ ... }),
operationTimeoutSeconds: 5,
});
const producer = await client.createProducer({
topic: "persistent://public/default/testing-topic",
});
```
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar-client-node] shibd commented on issue #281: Failed to create producer: ConnectError when upgrading to 1.8.0
Posted by GitBox <gi...@apache.org>.
shibd commented on issue #281:
URL: https://github.com/apache/pulsar-client-node/issues/281#issuecomment-1383830282
Hi, Let's continue the discussion here.
https://github.com/apache/pulsar-client-node/pull/282#issuecomment-1378497083
I build from source code following Master's `README` and it worked.
I suspect maybe you're using a different server environment?
Can you test by following the steps below:
1. Refer to [How to build](https://github.com/apache/pulsar-client-node/tree/v1.8.0#how-to-build) of master README to build from the source
2. Copy this [demo](https://github.com/shibd/pulsar-node-oauth2-ssl-test/blob/main/producer-oauth2.js) to [example](https://github.com/apache/pulsar-client-node/tree/master/examples) on your host.
3. Change require
```git
const Pulsar = require('shibaodi-pulsar-client');
// change to
const Pulsar = require('../');
```
4. Run this demo.
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar-client-node] shibd commented on issue #281: Failed to create producer: ConnectError when upgrading to 1.8.0
Posted by "shibd (via GitHub)" <gi...@apache.org>.
shibd commented on issue #281:
URL: https://github.com/apache/pulsar-client-node/issues/281#issuecomment-1420992237
### Summary
This is because cross-compilation results in the `CA cert bundle` not being set on the ARM64 Mac. Refer to this: https://github.com/apache/pulsar-client-cpp/issues/184#issuecomment-1420909521
We need to wait for this [PR](https://github.com/apache/pulsar-client-cpp/pull/190) to be released and then upgrade the CPP dependencies.
It can then be solved on arm64 by configuring `tlsTrustCertsFilePath`
```
const client = new Pulsar.Client({
serviceUrl: 'url',
tlsTrustCertsFilePath:'/etc/ssl/cert.pem',
});
```
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar-client-node] shibd commented on issue #281: Failed to create producer: ConnectError when upgrading to 1.8.0
Posted by "shibd (via GitHub)" <gi...@apache.org>.
shibd commented on issue #281:
URL: https://github.com/apache/pulsar-client-node/issues/281#issuecomment-1463221314
v1.8.1 has already been released, and it can fix this issue.
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar-client-node] shibd closed issue #281: Failed to create producer: ConnectError when upgrading to 1.8.0
Posted by "shibd (via GitHub)" <gi...@apache.org>.
shibd closed issue #281: Failed to create producer: ConnectError when upgrading to 1.8.0
URL: https://github.com/apache/pulsar-client-node/issues/281
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar-client-node] shibd commented on issue #281: Failed to create producer: ConnectError when upgrading to 1.8.0
Posted by GitBox <gi...@apache.org>.
shibd commented on issue #281:
URL: https://github.com/apache/pulsar-client-node/issues/281#issuecomment-1374451272
When I use `pulsar+ssl:`, I get the same result as you: `Error: Failed to create producer: ConnectError`
The essential reason should be this:
```
Response failed for getting the well-known configuration https://dev-kt-aa9ne.us.auth0.com. Error Code 60: SSL certificate problem: unable to get local issuer certificate
```
I will check it.
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar-client-node] shibd commented on issue #281: Failed to create producer: ConnectError when upgrading to 1.8.0
Posted by GitBox <gi...@apache.org>.
shibd commented on issue #281:
URL: https://github.com/apache/pulsar-client-node/issues/281#issuecomment-1377380998
This can be caused by static linking cross-compiled OpenSSL.
I push a #282 to fix this. Before that, you can refer to [How to build](https://github.com/apache/pulsar-client-node/tree/v1.8.0#how-to-build) of README to build from the source(I tested it, and it can work).
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar-client-node] ericallam commented on issue #281: Failed to create producer: ConnectError when upgrading to 1.8.0
Posted by GitBox <gi...@apache.org>.
ericallam commented on issue #281:
URL: https://github.com/apache/pulsar-client-node/issues/281#issuecomment-1377401561
Thanks, will take a look at building from source 👍
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar-client-node] ericallam commented on issue #281: Failed to create producer: ConnectError when upgrading to 1.8.0
Posted by GitBox <gi...@apache.org>.
ericallam commented on issue #281:
URL: https://github.com/apache/pulsar-client-node/issues/281#issuecomment-1375629684
Just added the logging a retested with 1.8.0 and here's the log got:
```
[1][ClientConnection:189] [<none> -> pulsar+ssl://<cluster>.<orgid>.snio.cloud:6651] Create ClientConnection, timeout=10000
[3][AuthOauth2:224] Response failed for getting the well-known configuration https://auth.streamnative.cloud/. Error Code 60: SSL certificate problem: unable to get local issuer certificate
[1][ConnectionPool:97] Created connection for pulsar+ssl://<cluster>.<orgid>.snio.cloud:6651
[1][ClientConnection:379] [192.168.1.8:52825 -> 184.72.154.254:6651] Connected to broker
[3][ClientConnection:472] [192.168.1.8:52825 -> 184.72.154.254:6651] Handshake failed: certificate verify failed (SSL routines, tls_process_server_certificate)
[1][ClientConnection:1584] [192.168.1.8:52825 -> 184.72.154.254:6651] Connection closed with ConnectError
[3][ClientImpl:184] Error Checking/Getting Partition Metadata while creating producer on persistent://public/default/test-topic -- ConnectError
[1][ClientConnection:267] [192.168.1.8:52825 -> 184.72.154.254:6651] Destroyed connection
```
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar-client-node] ericallam commented on issue #281: Failed to create producer: ConnectError when upgrading to 1.8.0
Posted by GitBox <gi...@apache.org>.
ericallam commented on issue #281:
URL: https://github.com/apache/pulsar-client-node/issues/281#issuecomment-1377105244
Are there any workarounds for this issue @shibd?
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar-client-node] shibd commented on issue #281: Failed to create producer: ConnectError when upgrading to 1.8.0
Posted by GitBox <gi...@apache.org>.
shibd commented on issue #281:
URL: https://github.com/apache/pulsar-client-node/issues/281#issuecomment-1374450723
Hi, @ericallam Need to confirm, are you getting an auth `AuthenticationError`? In my environment I reproduce and I get an `AuthenticationError`
I get the error log:
```
Response failed for getting the well-known configuration https://dev-kt-aa9ne.us.auth0.com. Error Code 60: SSL certificate problem: unable to get local issuer certificate
```
You can add the following code to get the log information:
```
Pulsar.Client.setLogHandler((level, file, line, message) => {
console.log('[%s][%s:%d] %s', Pulsar.LogLevel.toString(level), file, line, message);
});
```
--
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.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org