You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by GitBox <gi...@apache.org> on 2022/04/20 07:27:51 UTC
[GitHub] [iotdb] MarcosZyk opened a new pull request, #5607: [IOTDB-2932]Fix localPartitionTable concurrent bug
MarcosZyk opened a new pull request, #5607:
URL: https://github.com/apache/iotdb/pull/5607
## Description
### Cause
There are three components involved in timeseries creation: storage group, schemaRegionId, and schemaRegion.
The three components are managed respectively by storageGroupSchemaManager, localSchemaPartitionTable and SchemaEngine.
The creation of each component are separated, while the timeseries creation requires all the three components and concurrent timeseries creation will fetch unready resource.
### Solution
Strengthen the auto create method to cover all the three component.
--
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: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [iotdb] MarcosZyk commented on a diff in pull request #5607: [IOTDB-2932]Fix localPartitionTable concurrent bug
Posted by GitBox <gi...@apache.org>.
MarcosZyk commented on code in PR #5607:
URL: https://github.com/apache/iotdb/pull/5607#discussion_r854074926
##########
server/src/main/java/org/apache/iotdb/db/metadata/schemaregion/SchemaEngine.java:
##########
@@ -57,11 +64,39 @@ public static SchemaEngine getInstance() {
return SchemaEngineManagerHolder.INSTANCE;
}
- public void init() {
+ public Map<PartialPath, List<SchemaRegionId>> init() throws MetadataException {
schemaRegionMap = new ConcurrentHashMap<>();
- schemaRegionStoredMode =
- SchemaEngineMode.valueOf(IoTDBDescriptor.getInstance().getConfig().getSchemaEngineMode());
+ schemaRegionStoredMode = SchemaEngineMode.valueOf(config.getSchemaEngineMode());
logger.info("used schema engine mode: {}.", schemaRegionStoredMode);
+
+ return initSchemaRegion();
+ }
+
+ private Map<PartialPath, List<SchemaRegionId>> initSchemaRegion() throws MetadataException {
Review Comment:
Fixed.
--
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: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [iotdb] qiaojialin commented on a diff in pull request #5607: [IOTDB-2932]Fix localPartitionTable concurrent bug
Posted by GitBox <gi...@apache.org>.
qiaojialin commented on code in PR #5607:
URL: https://github.com/apache/iotdb/pull/5607#discussion_r853914827
##########
server/src/main/java/org/apache/iotdb/db/metadata/schemaregion/SchemaEngine.java:
##########
@@ -57,11 +64,39 @@ public static SchemaEngine getInstance() {
return SchemaEngineManagerHolder.INSTANCE;
}
- public void init() {
+ public Map<PartialPath, List<SchemaRegionId>> init() throws MetadataException {
schemaRegionMap = new ConcurrentHashMap<>();
- schemaRegionStoredMode =
- SchemaEngineMode.valueOf(IoTDBDescriptor.getInstance().getConfig().getSchemaEngineMode());
+ schemaRegionStoredMode = SchemaEngineMode.valueOf(config.getSchemaEngineMode());
logger.info("used schema engine mode: {}.", schemaRegionStoredMode);
+
+ return initSchemaRegion();
+ }
+
+ private Map<PartialPath, List<SchemaRegionId>> initSchemaRegion() throws MetadataException {
Review Comment:
add javadoc
--
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: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [iotdb] qiaojialin merged pull request #5607: [IOTDB-2932]Fix localPartitionTable concurrent bug
Posted by GitBox <gi...@apache.org>.
qiaojialin merged PR #5607:
URL: https://github.com/apache/iotdb/pull/5607
--
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: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org