- 28 8月, 2019 40 次提交
-
-
由 lipenghui 提交于
Fixes #4785 ### Motivation 1. Stop return partition name in table list, just return the partitioned topic name in table list. This will avoid huge tables while user create large number of partition. 2. Make partition as internal column, provide users with the ability to get which partition data in and filtration based on partition. For example: ``` SELECT * FROM "my-table" WHERE "__partition__" = 0; SELECT * FROM "my-table" WHERE "__partition__" in (2,3); SELECT * FROM "my-table" WHERE "__partition__" < 1; ``` ### Modifications 1. Add "__partition__" internal column. 2. Add domain handle for "__partition__". ### Verifying this change Added new unit test to verify this change ### Does this pull request potentially affect one of the following parts: *If `yes` was chosen, please highlight the changes* - Dependencies (does it add or upgrade a dependency): (no) - The public API: (yes) - The schema: (no) - The default values of configurations: (no) - The wire protocol: ( no) - The rest endpoints: (no) - The admin cli options: (no) - Anything that affects deployment: (no) ### Documentation - Does this pull request introduce a new feature? (yes) (cherry picked from commit 5adc522e)
-
由 Sergii Zhevzhyk 提交于
The checksyle plugin was added to the pulsar sql module to enforce the defined style. All violations were fixed: - Ordering of imports. - Formatting of the code. - Absent Javadoc comments. - Other small issues. (cherry picked from commit f6fee1c6)
-
由 Matteo Merli 提交于
(cherry picked from commit f88ea9df)
-
由 Boyang Jerry Peng 提交于
(cherry picked from commit 075f28b7)
-
由 lipenghui 提交于
### Motivation Fix #4732 ### Modifications Add options to rewrite the namespace delimiter, disable by default Enable rewrite namespace delimiter can work well with superset: <img width="1279" alt="superset" src="https://user-images.githubusercontent.com/12592133/61385412-f0f35700-a8e4-11e9-87b2-a31b62128b58.png"> ### Does this pull request potentially affect one of the following parts: *If `yes` was chosen, please highlight the changes* - Dependencies (does it add or upgrade a dependency): (no) - The public API: (no) - The schema: (no) - The default values of configurations: (no) - The wire protocol: (no) - The rest endpoints: (no) - The admin cli options: (no) - Anything that affects deployment: (no) ### Documentation - Does this pull request introduce a new feature? (no) (cherry picked from commit 6ddd51ff)
-
由 Jia Zhai 提交于
Motivation In PR #4764, we allow to create partitioned topic with 1 partition, But in Pulsar Client, user still not able to do it. This fix try to make sure user could create consumer/producer for 1 partitioned topic . Modifications - old and new added unit test passed. (cherry picked from commit 128287e3)
-
由 Kezhu Wang 提交于
### Motivation Fix concurrent access of `uninitializedCursors` in `ManagedLedgerImpl.asyncOpenCursor`. ### Modifications * Adds test to expose concurrent access of `uninitializedCursors` in `ManagedLedgerImpl.asyncOpenCursor`. * Fixes concurrent access of `uninitializedCursors` in `ManagedLedgerImpl.asyncOpenCursor`. (cherry picked from commit 5bf319e4)
-
由 Robert Moucha 提交于
### Motivation Incorrect value is being used in Pulsar Helm template `autorecovery-deployment.yaml` ### Modifications Proper variable name set. ### Verifying this change Fixed variable name is already set in `values.yaml` and `values-mini.yaml`. This change is a trivial rework / code cleanup without any test coverage. ### Documentation None needed. (cherry picked from commit 2b52ccb2)
-
由 Xiaobing Fang 提交于
Fixes #4852 Bug: After create an empty ledger by sub/unsub and trim ledgers, the first position in managedLedger is ahead of the last when create a consumer without reopen the managed ledger. Reason: Last position will be update when opening managedLedger. Because when creating an empty Ledger without reopening managedLedger, the last position is not be updated. Since the ledger pointed of the last position has been deleted, the first position point to the new ledger. Fix: The first position should fall back to last position. (cherry picked from commit 46bfb2c2)
-
由 Yi Tang 提交于
### Motivation jdbc sink treat all record as INSERT before #4358 , now it requires an indispensable action property which seems to be a break change, and we can deal records without any action property as INSERT. ### Modifications treat action not set as INSERT action like before. (cherry picked from commit d8356d8c)
-
由 Xiaobing Fang 提交于
the 0 size limit can't means "infinite" size quota (cherry picked from commit 77f63709)
-
由 Boyang Jerry Peng 提交于
(cherry picked from commit 3c9136b2)
-
由 Xiaobing Fang 提交于
fix #4755 Retention policy is used in Ledger GC and Topic GC. Default retention policy is not uploaded to zookeeper, but it is getted from zookeeper when it is used. So, if zookeeper doesn't have retention policy, we should load it from default config file. In Ledger GC configuration, it's OK. https://github.com/apache/pulsar/blob/075f28b71c8fd9259ce8e136dbb81c0629c3f271/pulsar-broker/src/main/java/org/apache/pulsar/broker/service/BrokerService.java#L739-L742 But in Topic GC, do nothing. (cherry picked from commit 1dcac8cc)
-
由 Boyang Jerry Peng 提交于
### Modifications When submitting a function via REST interface, if user doesn't provide the function package or function runtime as part of function config, the function will get submitted and deployed to run but the typeClassName for the source will not be set causing a weird error in the function instance code (cherry picked from commit e1547e12)
-
由 Boyang Jerry Peng 提交于
### Motivation A message doesn't get automatically ACKed if there is the output topic is not set (cherry picked from commit 19b883b7)
-
由 tuteng 提交于
### Motivation Currently our JDBC Sink not support deletion and update events. Support for delete and update events. ### Modifications Support for delete and update events. Add some document for JDBC Sink. https://github.com/apache/pulsar/issues/4073 ### Verifying this change local Unit Test pass. Integration test pass
-
由 Rui Fu 提交于
### Motivation `pulsar-function-go/conf` package apply `instance-conf-path` with default value `HOME_PATH+github.com/apache/pulsar/pulsar-function-go/conf/conf.yaml`, once function deployed, the running node may not have the yaml conf file exist, then go function will panic with `not found conf file` error. This PR changed the logic of config parsing, parse `confContent` first, then parse `confFilePath` if `confContent` empty. (cherry picked from commit 8a3b3af6)
-
由 Matteo Merli 提交于
### Motivation After the changes in #3118, there has a been a sharp increase of memory utilization for the UnackedMessageTracker due to the time buckets being created. This is especially true when the acktimeout is set to a larger value (eg: 1h) where 3600 time-buckets are being created. This lead to use 20MB per partition even when no message is tracked. Allowing to configure the tick time so that application can tune it based on needs. Additionally, fixed the logic that keeps creating hash maps and throwing them away at each tick time iteration, since that creates a lot of garbage and doesn't take care of the fact that the hash maps are expanding based on the required capacity (so next time they are already of the "right" size). On a final note: the current default of 1sec seems very wasteful. Something like 10s should be more appropriate as default. (cherry picked from commit f13af487)
-
由 Boyang Jerry Peng 提交于
### Motivation Currently, if the kubernetes namespace set to deploy functions in is different than the one in which brokers/workers reside, get status and stats doesn't work because the url for instances does not specify the namespace. (cherry picked from commit 8c3445ad)
-
由 Boyang Jerry Peng 提交于
(cherry picked from commit 26fc4efe)
-
由 Rui Fu 提交于
### Motivation Currently golang function needs to be compiled before deploy to pulsar, so the executable permission is required when function package is downloaded to local node from bookkeeper. This PR is intent to make golang function package executable after download from bookkeeper, to make sure the function is ok to run. (cherry picked from commit bf58c8eb)
-
由 Jia Zhai 提交于
**Motivation** when create partitioned topic, there is a check that `numPartitions > 1`, if numPartitions==1, it will fail. Some user may want to create partitioned topic with only 1 topic at the start time, and during using it, could update to more topics later. **Modification** change check of `numPartitions > 1` to `numPartitions > 0` expect all existing ut passed. (cherry picked from commit 5162393c)
-
由 Yuto Furuta 提交于
(cherry picked from commit 9605aede)
-
由 massakam 提交于
### Motivation If trying to build master C++ code with the `USE_LOG4CXX` flag turned ON, compilation errors occur: ``` /tmp/pulsar/pulsar-client-cpp/lib/Log4cxxLogger.cc: In static member function ‘static log4cxx::LevelPtr pulsar::Log4CxxLogger::getLevel(pulsar::Logger::Level)’: /tmp/pulsar/pulsar-client-cpp/lib/Log4cxxLogger.cc:53:18: error: ‘DEBUG’ was not declared in this scope case DEBUG: ^ /tmp/pulsar/pulsar-client-cpp/lib/Log4cxxLogger.cc:55:18: error: ‘INFO’ was not declared in this scope case INFO: ^ /tmp/pulsar/pulsar-client-cpp/lib/Log4cxxLogger.cc:57:18: error: ‘WARN’ was not declared in this scope case WARN: ^ /tmp/pulsar/pulsar-client-cpp/lib/Log4cxxLogger.cc:59:18: error: ‘ERROR’ was not declared in this scope case ERROR: ^ /tmp/pulsar/pulsar-client-cpp/lib/Log4cxxLogger.cc:52:16: error: enumeration value ‘LEVEL_DEBUG’ not handled in switch [-Werror=switch] switch (level) { ^ /tmp/pulsar/pulsar-client-cpp/lib/Log4cxxLogger.cc:52:16: error: enumeration value ‘LEVEL_INFO’ not handled in switch [-Werror=switch] /tmp/pulsar/pulsar-client-cpp/lib/Log4cxxLogger.cc:52:16: error: enumeration value ‘LEVEL_WARN’ not handled in switch [-Werror=switch] /tmp/pulsar/pulsar-client-cpp/lib/Log4cxxLogger.cc:52:16: error: enumeration value ‘LEVEL_ERROR’ not handled in switch [-Werror=switch] cc1plus: some warnings being treated as errors make[2]: *** [lib/CMakeFiles/pulsarStatic.dir/Log4cxxLogger.cc.o] Error 1 make[2]: *** Waiting for unfinished jobs.... ``` This is because the enum values renamed in https://github.com/apache/pulsar/pull/4664 are still used in `Log4cxxLogger.cc`. ### Modifications Fixed the enum values used in `Log4cxxLogger.cc` by adding the prefix `LEVEL_`. (cherry picked from commit af8ea71a)
-
由 冉小龙 提交于
Fixes #4589 Motivation When using Partition-topic, the logic of redeliver messages will not be triggered when the time of ackTimeout arrives. This is because the unAckedMessageTrackerPtr_->add(msg.getMessageId()) is not call in the listener handling of partitioned topic in cpp code (cherry picked from commit cc5f25bf)
-
由 lipenghui 提交于
Fixes #4734 ### Motivation "publish_time" is Pulsar SQL internal column, as Pulsar only stores timestamps, it doesn’t store the timezone information. Use timestamp as "publish_time" type is more correct way in Pulsar SQL. ### Modifications Change type of publish_time to timestamp. ### Verifying this change predicate of publish_time is pushdown Use `__publish_time__` to trim messages: ``` SELECT COUNT(*) FROM "sql-test-1" WHERE "__publish_time__" >= TIMESTAMP '2019-07-18 17:26:50.119' AND "__publish_time__" < TIMESTAMP '2019-07-18 17:26:51.119'; ``` ![image](https://user-images.githubusercontent.com/12592133/61447301-43835080-a983-11e9-814b-bc2b378f02b9.png) Without `__publish_time__` predicate: ``` SELECT COUNT(*) FROM "sql-test-1"; ``` ![image](https://user-images.githubusercontent.com/12592133/61447427-82190b00-a983-11e9-8d3f-3bf2a4798047.png) (cherry picked from commit 6f5416ee)
-
由 Yong Zhang 提交于
## Motivation Currently, In Pulsar Kerberos authentication, The server type part of pulsar node principle is hard coded as "broker" and "proxy". The expected principle for pulsar nodes would be like "broker/brokera.host.name@your.com" or "proxy/proxyb.host.name@your.com". But some times, user may want to re-use existing principle like "u-service/host.name@some.com", to test and play around, then "u-service" will not match service type of "broker" or "proxy", and the authentication will be rejected. This change is to remove the check of "broker" or "proxy" service type check. ## Modifaction Remove the check of "broker" or "proxy" service type check. (cherry picked from commit f5b20cd3)
-
由 Boyang Jerry Peng 提交于
* Fix: predicate pushdown for Pulsar SQL NPE * fix unit test (cherry picked from commit ac10b006)