m_normalizePayload.normalize(model, payload);
}
private void setDefaultThreshold(Model model, Payload payload) {
Map<String, Domain> domains = m_manager.getLongConfigDomains();
Domain d = domains.get(payload.getDomain());
if (d != null) {
int longUrlTime = d.getUrlThreshold() == null ? m_manager.getLongUrlDefaultThreshold() : d.getUrlThreshold()
.intValue();
if (longUrlTime != 500 && longUrlTime != 1000 && longUrlTime != 2000 && longUrlTime != 3000
&& longUrlTime != 4000 && longUrlTime != 5000) {
double sec = (double) (longUrlTime) / (double) 1000;
NumberFormat nf = new DecimalFormat("#.##");
String option = "<option value=\"" + longUrlTime + "\"" + ">" + nf.format(sec) + " Sec</option>";
model.setDefaultThreshold(option);
}
int longSqlTime = d.getSqlThreshold();
if (longSqlTime != 100 && longSqlTime != 500 && longSqlTime != 1000) {
double sec = (double) (longSqlTime);
NumberFormat nf = new DecimalFormat("#");
String option = "<option value=\"" + longSqlTime + "\"" + ">" + nf.format(sec) + " ms</option>";