/** * INTERNAL: * Create root noun for TopLink dms metrics. */ protected void createRootNoun() { root = Noun.create(EclipseLinkRootNoun); }
/** * INTERNAL: * Create root noun for TopLink dms metrics. */ protected void createRootNoun() { root = Noun.create(EclipseLinkRootNoun); }
/** * INTERNAL: * Look for noun based on the given type and weight. If not found and the parent noun is not null, create a new noun. */ protected Noun getNounByType(String type, Noun parentNoun, int weight) { if (getProfileWeight() < weight) { return null; } Noun noun = null; Map map = null; if (weight == DMSConsole.NORMAL) { map = getNormalWeightNouns(); } else if (weight == DMSConsole.HEAVY) { map = getHeavyWeightNouns(); } else if (weight == DMSConsole.ALL) { map = getAllWeightNouns(); } if (map != null) { noun = (Noun)map.get(type); if (noun == null) { if (parentNoun != null) { noun = Noun.create(parentNoun, type, type); map.put(type, noun); } } } return noun; }
/** * INTERNAL: * Look for noun based on the given type and weight. If not found and the parent noun is not null, create a new noun. */ protected Noun getNounByType(String type, Noun parentNoun, int weight) { if (getProfileWeight() < weight) { return null; } Noun noun = null; Map map = null; if (weight == DMSConsole.NORMAL) { map = getNormalWeightNouns(); } else if (weight == DMSConsole.HEAVY) { map = getHeavyWeightNouns(); } else if (weight == DMSConsole.ALL) { map = getAllWeightNouns(); } if (map != null) { noun = (Noun)map.get(type); if (noun == null) { if (parentNoun != null) { noun = Noun.create(parentNoun, type, type); map.put(type, noun); } } } return noun; }
/** * INTERNAL: * Build dms NORMAL weight sensors for TopLink dms metrics. */ protected void initializeNormalWeightSensors() { createRootNoun(); Noun sessionNoun = Noun.create(root, "Session" + getSessionName(), SessionNounType); //SessionName State.create(sessionNoun, SessionProfiler.SessionName, "", DMSLocalization.buildMessage("session_name"), (this.getSession().getName() == "") ? "session name not specified" : getSession().getName()); //LoginTime State sessionLoginTime = State.create(sessionNoun, SessionProfiler.LoginTime, "", DMSLocalization.buildMessage("session_login_time"), "not available"); this.getNormalWeightSensors().put(SessionProfiler.LoginTime, sessionLoginTime); this.getNormalWeightNouns().put(SessionNounType, sessionNoun); }
/** * INTERNAL: * Build dms NORMAL weight sensors for TopLink dms metrics. */ protected void initializeNormalWeightSensors() { createRootNoun(); Noun sessionNoun = Noun.create(root, "Session" + getSessionName(), SessionNounType); //SessionName State.create(sessionNoun, SessionProfiler.SessionName, "", DMSLocalization.buildMessage("session_name"), (this.getSession().getName() == "") ? "session name not specified" : getSession().getName()); //LoginTime State sessionLoginTime = State.create(sessionNoun, SessionProfiler.LoginTime, "", DMSLocalization.buildMessage("session_login_time"), "not available"); this.getNormalWeightSensors().put(SessionProfiler.LoginTime, sessionLoginTime); this.getNormalWeightNouns().put(SessionNounType, sessionNoun); }
getHeavyWeightSensors().put(SessionProfiler.UowCreated, unitOfWork); Noun transactionNoun = Noun.create(root, "Transaction" + getSessionName(), TransactionNounType); getHeavyWeightNouns().put(TransactionNounType, transactionNoun); Noun rcmNoun = Noun.create(root, "RCM" + getSessionName(), RcmNounType); getHeavyWeightNouns().put(RcmNounType, rcmNoun); Noun connectionsNoun = Noun.create(root, "Connection" + getSessionName(), ConnectionNounType); getHeavyWeightNouns().put(ConnectionNounType, connectionsNoun); Noun cacheNoun = Noun.create(root, "Cache" + getSessionName(), CacheNounType); getHeavyWeightNouns().put(CacheNounType, cacheNoun);
getHeavyWeightSensors().put(SessionProfiler.UowCreated, unitOfWork); Noun transactionNoun = Noun.create(root, "Transaction" + getSessionName(), TransactionNounType); getHeavyWeightNouns().put(TransactionNounType, transactionNoun); Noun rcmNoun = Noun.create(root, "RCM" + getSessionName(), RcmNounType); getHeavyWeightNouns().put(RcmNounType, rcmNoun); Noun connectionsNoun = Noun.create(root, "Connection" + getSessionName(), ConnectionNounType); getHeavyWeightNouns().put(ConnectionNounType, connectionsNoun); Noun cacheNoun = Noun.create(root, "Cache" + getSessionName(), CacheNounType); getHeavyWeightNouns().put(CacheNounType, cacheNoun);
Noun miscellaneousNoun = Noun.create(root, "Miscellaneous" + getSessionName(), MiscellaneousNounType); getAllWeightNouns().put(MiscellaneousNounType, miscellaneousNoun);
Noun miscellaneousNoun = Noun.create(root, "Miscellaneous" + getSessionName(), MiscellaneousNounType); getAllWeightNouns().put(MiscellaneousNounType, miscellaneousNoun);