Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: remove circular dep in admin svc, adjusts default superuser env flag name and default #572

Merged
merged 2 commits into from
May 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@ public class PulsarApplicationListener implements ApplicationListener<ContextRef
@Value("${default.environment.bookie_url}")
private String defaultEnvironmentBookieUrl;

@Value("${default.superuser.enable}")
private Boolean defaultSuperuserEnable = false;
@Value("${default.superuser.enabled}")
private Boolean defaultSuperuserEnabled;

@Value("${default.superuser.name}")
private String defaultSuperuserName;
Expand Down Expand Up @@ -94,8 +94,8 @@ public void onApplicationEvent(ContextRefreshedEvent event) {
}

private void seedDefaultSuperuser() {
if(defaultSuperuserEnable == false) {
log.debug("Superuser seed disabled");
if(defaultSuperuserEnabled == false) {
log.info("Superuser seed via application.properties is disabled");
return;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,9 +71,6 @@ public class PulsarAdminServiceImpl implements PulsarAdminService {
@Autowired
private EnvironmentsRepository environmentsRepository;

@Autowired
private EnvironmentCacheService environmentCacheService;
maranmaran marked this conversation as resolved.
Show resolved Hide resolved

@PreDestroy
public void destroy() {
pulsarAdmins.values().forEach(value -> value.close());
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/application.properties
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ default.environment.service_url=
default.environment.bookie_url=

# default superuser configuration
default.superuser.enable=
default.superuser.enabled=false
maranmaran marked this conversation as resolved.
Show resolved Hide resolved
default.superuser.name=
default.superuser.password=
default.superuser.email=
Expand Down
Loading