Skip to content

Commit

Permalink
fix: review fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
tamassoltesz committed Oct 1, 2024
1 parent 72706f9 commit 807f617
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 7 deletions.
5 changes: 3 additions & 2 deletions config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,7 @@ core_config_version: 0
# if there are more CUDs in the database and block all other CUDs from being used from this instance.
# supertokens_saas_load_only_cud:

# (DIFFERENT_ACROSS_TENANTS | OPTIONAL | Default: 1) int value. If specified, the supertokens core will use the
# specified number of threads to complete the migration of users.
# (DIFFERENT_ACROSS_TENANTS | OPTIONAL | Default: number of available processor cores) int value. If specified,
# the supertokens core will use the specified number of threads to complete the migration of users.
# bulk_migration_parallelism:

4 changes: 2 additions & 2 deletions devConfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,6 @@ disable_telemetry: true
# if there are more CUDs in the database and block all other CUDs from being used from this instance.
# supertokens_saas_load_only_cud:

# (DIFFERENT_ACROSS_TENANTS | OPTIONAL | Default: 1) int value. If specified, the supertokens core will use the
# specified number of threads to complete the migration of users.
# (DIFFERENT_ACROSS_TENANTS | OPTIONAL | Default: number of available processor cores) int value. If specified,
# the supertokens core will use the specified number of threads to complete the migration of users.
# bulk_migration_parallelism:
Original file line number Diff line number Diff line change
Expand Up @@ -264,8 +264,8 @@ private String validateAndNormaliseExternalUserId(String externalUserId, List<St
return null;
}

if (externalUserId.length() > 255) {
errors.add("externalUserId " + externalUserId + " is too long. Max length is 255.");
if (externalUserId.length() > 128) {
errors.add("externalUserId " + externalUserId + " is too long. Max length is 128.");
}

if (!allExternalUserIds.add(externalUserId)) {
Expand Down
4 changes: 3 additions & 1 deletion src/main/java/io/supertokens/config/CoreConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,9 @@ public class CoreConfig {

@NotConflictingInApp
@JsonProperty
private int bulk_migration_parallelism = 1;
@ConfigDescription("If specified, the supertokens core will use the specified number of threads to complete the " +
"migration of users. (Default: number of available processor cores).")
private int bulk_migration_parallelism = Runtime.getRuntime().availableProcessors();

public static Set<String> getValidFields() {
CoreConfig coreConfig = new CoreConfig();
Expand Down

0 comments on commit 807f617

Please sign in to comment.