Skip to content
This repository has been archived by the owner on Jun 10, 2022. It is now read-only.

unable producer to specific topic #287

Open
afety opened this issue Dec 26, 2019 · 0 comments
Open

unable producer to specific topic #287

afety opened this issue Dec 26, 2019 · 0 comments

Comments

@afety
Copy link

afety commented Dec 26, 2019

I use some code from Example to test send message to specific topic,

        $config = ProducerConfig::getInstance();
        $config->setMetadataRefreshIntervalMs(10000);
        $config->setMetadataBrokerList('127.0.0.1:9092');
        $config->setBrokerVersion('1.0.0');
        $config->setRequiredAck(1);

        $producer = new Producer(function () {
            return [
                [
                    'topic' => 'logTest',
                    'value' => 'test....message.',
                    'key' => '',
                ],
            ];
        });

then I receive any Fatal error: Requested topic "logTest" does not exist. Did you forget to create it?"

I am sure this topic exists,and this image is a screenshot of kafka-manager
企业微信截图_20191226143234

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant