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

FDP-94: Add monitoring and small fixes #9

Merged
merged 12 commits into from
Dec 7, 2023
Merged

Conversation

jasperkamerling
Copy link
Contributor

No description provided.

JelleHoffman
JelleHoffman previously approved these changes Nov 30, 2023
JelleHoffman
JelleHoffman previously approved these changes Dec 1, 2023
LucianoFavoroso
LucianoFavoroso previously approved these changes Dec 1, 2023
.register(registry)
.record(duration)
}
}

Choose a reason for hiding this comment

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

new line

Signed-off-by: Jasper Kamerling <[email protected]>
LucianoFavoroso
LucianoFavoroso previously approved these changes Dec 1, 2023
Copy link
Collaborator

Choose a reason for hiding this comment

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

Is dit voldoende om ook bijv. fail-rates uit te halen? Of moeten we wat counters toeveoegen?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Is het überhaupt nodig om fouten te timen? Kunnen we niet gerichter timeouts, technische exceptions etc. 'counten'?

createErrorResponse(response);
connectionCacheService.removeConnection(connectionId);
return;
}
} catch (final InterruptedException e) {
LOGGER.error("Error while waiting for response", e);
monitoringService.recordConnectionTime(startTime, request.getContextPath(), false);

Choose a reason for hiding this comment

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

Mogelijk is het nuttiger om errors te tellen. Eventueel naast het meten van de duratie.

sanderv
sanderv previously approved these changes Dec 7, 2023
sanderv
sanderv previously approved these changes Dec 7, 2023

// After adding an entry it should be 1
cacheMap["key"] = "value"
assertEquals(1.0, gauge.value())

Choose a reason for hiding this comment

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

Actual first param, Expected as second param.


// After reassigning the key it should stay at 1
cacheMap["key"] = "new-value"
assertEquals(1.0, gauge.value())

Choose a reason for hiding this comment

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

Actual first param, Expected as second param.


// After adding a second key it should be 2
cacheMap["new-key"] = "new-value"
assertEquals(2.0, gauge.value())

Choose a reason for hiding this comment

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

Actual first param, Expected as second param.


// Check if the meter exists and is 0
assertNotNull(meterRegistry.find(CACHE_SIZE_METRIC).gauge())
assertEquals(0.0, gauge.value())

Choose a reason for hiding this comment

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

Actual first param, Expected as second param.


}

}

Choose a reason for hiding this comment

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

new line

Copy link

sonarqubecloud bot commented Dec 7, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

72.5% 72.5% Coverage
0.0% 0.0% Duplication

@jasperkamerling jasperkamerling merged commit 3e4fcac into main Dec 7, 2023
4 checks passed
@jasperkamerling jasperkamerling deleted the feature/FDP-94 branch December 7, 2023 15:08
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.

5 participants