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

ALS-7867 #62

Merged
merged 2 commits into from
Jan 8, 2025
Merged

ALS-7867 #62

merged 2 commits into from
Jan 8, 2025

Conversation

TDeSain
Copy link

@TDeSain TDeSain commented Dec 15, 2024

No description provided.

- Deleted `DashboardDrawerList` record from the project.
- Updated `DashboardDrawerController` to return a `List<DashboardDrawer>`.
- Modified `DashboardDrawerService` to utilize a `List` instead of `DashboardDrawerList`.
- Changed `DashboardDrawerRepository` to return `Optional<List<DashboardDrawer>>`.
- Adjusted SQL join in `getDashboardDrawerRows` to use a LEFT JOIN.
- Updated `DashboardDrawerService` to use "default" layout as the fallback.
- Simplified repository queries by removing materialized view checks.
- Renamed methods in `DashboardDrawerRepository` for better clarity.
- Removed `dashboard.layout.type` from `application-bdc.properties`.
- Added unit and integration tests for `DashboardDrawerService`, `DashboardDrawerRepository`, and `DashboardDrawerController`.
@@ -13,7 +15,7 @@ public class DashboardDrawerController {
private DashboardDrawerService dashboardDrawerService;

@GetMapping
public ResponseEntity<DashboardDrawerList> findAll() {
public ResponseEntity<List<DashboardDrawer>> findAll() {
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dumping DashboardDrawerList object in favor of using an actual list

String materializedViewSql = """
select * from dictionary_db.dict.dataset_meta_materialized_view dmmv;
""";
public Optional<List<DashboardDrawer>> getDashboardDrawerRows() {
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Debug log is too chatty. removing materialized views as they are not in use anyways.

@@ -15,7 +15,7 @@ public class DashboardDrawerService {
private final String dashboardLayout;

@Autowired
public DashboardDrawerService(DashboardDrawerRepository repository, @Value("${dashboard.layout.type}") String dashboardLayout) {
public DashboardDrawerService(DashboardDrawerRepository repository, @Value("${dashboard.layout.type:default}") String dashboardLayout) {
Copy link
Author

@TDeSain TDeSain Dec 15, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since there is no other implementation or requirements for other projects at the moment, will just make this the default layout. I do not like the value to be bdc for obvious reasons.

@@ -7,7 +7,6 @@ server.port=80

dashboard.enable.extra_details=true
dashboard.enable.bdc_hack=true
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just use default layout

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Out of scope for this work. I wouldn't build a repository layer here. I would move the repository logic to the dataset repository.

@TDeSain TDeSain self-assigned this Dec 18, 2024
@TDeSain TDeSain requested a review from Luke-Sikina December 18, 2024 13:49
@TDeSain TDeSain requested a review from Gcolon021 January 7, 2025 15:02
@TDeSain
Copy link
Author

TDeSain commented Jan 8, 2025

Tested in bdc dev

@TDeSain TDeSain merged commit db1b1fe into release Jan 8, 2025
2 checks passed
@TDeSain TDeSain deleted the ALS-7867 branch January 8, 2025 14:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants