apache / apache/pulsar-client-cpp

[Bug] subscribeAsync and createProducerAsync return UnknownErrorCode when built using devtoolset-11

Offen
#255 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
C++
Sterne
71
Forks
90
Ø Merge
2 Std. 33 Min.
Gemergte PRs (30 T.)
3

Beschreibung

### Search before asking

- [X] I searched in the [issues](https://github.com/apache/pulsar-client-cpp/issues) and found nothing similar.

### Version

OS: CentOS 7
Pulsar C++ client: 3.1.2

### Minimal reproduce step

1. Install gcc 11.
```
yum install devtoolset-11
. /opt/rh/devtoolset-11/enable
```

2. Install the same dependencies as this Dockerfile:
https://github.com/apache/pulsar-client-cpp/blob/v3.1.2/pkg/rpm/Dockerfile

3. Build rpm using this spec file:
https://github.com/apache/pulsar-client-cpp/blob/v3.1.2/pkg/rpm/SPECS/pulsar-client.spec

4. Install pulsar client library.
```
rpm -ivh apache-pulsar-client*.rpm
```

### What did you expect to see?

#subscribeAsync and #createProducerAsync return ResultOk.

### What did you see instead?

#subscribeAsync and #createProducerAsync return UnknownErrorCode.
When I tried to output the value of return value, it returned unexpected values like 1915086316.

### Anything else?

When built using gcc-toolset-11 on Rocky Linux 8, #subscribeAsync and #createProducerAsync return ResultOk.

### Are you willing to submit a PR?

- [ ] I'm willing to submit a PR!

Beitragsleitfaden

Beitragsleitfaden öffnen

Rechercherichtung

Reproduce the issue on CentOS 7 with devtoolset-11 using pkg/rpm/Dockerfile and pkg/rpm/SPECS/pulsar-client.spec. Trace subscribeAsync and createProducerAsync to determine why their returned values become UnknownErrorCode, then verify both return ResultOk with valid values in the reported build.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
cpp, linux
Bereich
api
Issue-Typ
Bug
Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Aktivitätsstatus
Veraltet
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
35/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.