Conversation
|
TypeScript types have been updated based on the JSON schema changes in the PR |
openmetadata-sdk/src/main/java/org/openmetadata/sdk/services/EntityServiceBase.java
Outdated
Show resolved
Hide resolved
openmetadata-service/src/main/java/org/openmetadata/service/jdbi3/UserRepository.java
Show resolved
Hide resolved
openmetadata-service/src/main/java/org/openmetadata/service/jdbi3/TeamRepository.java
Show resolved
Hide resolved
| if (team.getDefaultPersona() == null) { | ||
| return; | ||
| } | ||
| if (team.getTeamType() != null && !GROUP.equals(team.getTeamType())) { |
There was a problem hiding this comment.
💡 Edge Case: validateDefaultPersona allows null teamType for non-Group teams
In validateDefaultPersona(), the condition team.getTeamType() != null && !GROUP.equals(team.getTeamType()) allows a team with null teamType to have a defaultPersona set. If teamType is somehow null (e.g., during data migration or a bug), the validation silently passes.
This is a minor concern since teamType is likely always set by the time this validation runs, but for defensive programming, consider inverting the check:
if (team.getDefaultPersona() != null && !GROUP.equals(team.getTeamType())) {
throw new IllegalArgumentException(...);
}This way, only explicitly GROUP-typed teams pass validation, regardless of nulls.
Suggested fix:
private void validateDefaultPersona(Team team) {
if (team.getDefaultPersona() == null) {
return;
}
if (!TeamType.GROUP.equals(team.getTeamType())) {
throw new IllegalArgumentException(
"Default persona can only be set for teams of type Group.");
}
Entity.getEntityReferenceById(Entity.PERSONA, team.getDefaultPersona().getId(), NON_DELETED);
}
Was this helpful? React with 👍 / 👎
openmetadata-sdk/src/main/java/org/openmetadata/sdk/services/EntityServiceBase.java
Show resolved
Hide resolved
🔍 CI failure analysis for 3310211: Two CI jobs failed on commit 3310211 (TestCaseResultTab merge): (1) py-run-build-tests - IBM ODBC driver download failure (network connectivity to public.dhe.ibm.com), (2) maven-collate-ci - external Collate workflow timeout (1h limit, recurring 100% on all 9+ commits). Both are infrastructure issues unrelated to PR's UI changes.IssueTwo CI jobs failed on commit 3310211:
Root CauseJob 1: py-run-build-tests (Build Failure)Build failure - external dependency download:
Full error: Job 2: maven-collate-ci (Timeout)External workflow timeout:
Why These Failures Are Unrelated to PRCommit 3310211 changes:
py-run-build-tests failure:
maven-collate-ci failure:
DetailsHistorical pattern - maven-collate-ci:
Timeout characteristics:
py-run-build-tests characteristics:
Overall PR StatusPR functionality - all working:
CI results from commit e0a44ac:
Improvement maintained:
ConclusionBoth failures are infrastructure issues unrelated to PR changes: 1. py-run-build-tests:
2. maven-collate-ci:
PR status:
Code Review
|
| Auto-apply | Compact |
|
|
Was this helpful? React with 👍 / 👎 | Gitar
|
|



Describe your changes:
Fixes #23101
Screen.Recording.2026-02-25.at.3.54.02.PM.mov
Type of change:
Checklist:
Fixes <issue-number>: <short explanation>Summary by Gitar
defaultPersonafield to Group-type teams; team members automatically inherit itinheritedPersonasfield on users, automatically populated from team membershipsThis will update automatically on new commits.