am I crazy or isnât there a way to correlate these log entries with a specific client/user/session?
Iâm unsuccessfully trying to correlate wrapper log magnifying glass hover Navigation/Sidebar@L[0]
with Thread [perspective-worker-3155827] id=12266073, (BLOCKED)
and output of system.perspective.getSessionInfo()
may have some useful info (though not the original stacktrace)
Perspective Workstation is configured for auto-launch for all users. âperc' is presumably a Dell-specific (iDRAC related)? user . Unsure if itâs actively being âviewedâ somewhere or perhaps just open on a server-room KVM display as this is a clientâs environment. But someone clearly had to log into the Workstation instance.
though of course I canât be sure this is the session of interest
EDIT:
hereâs a script for anyone else whoâs curious:
getOrphanedPerspectiveClients (Gateway Event/Message Handler)
# def handleMessage(payload): # type: ignore (ignition copy/paste)
"""Usage
system.util.sendRequest(
project = 'Project Name', # env-specific
messageHandler ='getOrphanedPerspectiveClients',
payload = dict(
orphanedView = 'Templates/Tanks/Tank@C$0:0$0:42' # env-specific from offending logs (gateway webpage logs magnifying glass hover or raw wrapper.log view key)
)
)
"""
def getOrphanedPerspectiveClients(payload):
from com.inductiveautomation.ignition.common import TypeUtilities
payload = TypeUtilities.pyToGson(payload)
import system
from com.inductiveautomation.ignition.gateway import IgnitionGateway
IGg = IgnitionGateway.get(); mM = IGg.moduleManager
PerspectiveContext = mM.resolveClass('com.inductiveautomation.perspective.gateway.api.PerspectiveContext').get(IGg).getSessionMonitor().getClientSessionsForProject(system.project.getProjectName())
results = []
for session in PerspectiveContext:
for page in session.getPages():
for view in page.getViews():
if view.getId() == payload.orphanedView:
results.append({'address': session.props.address, 'username': session.props.auth.user.userName})
return results
return getOrphanedPerspectiveClients(payload)
looks like my intuition was correct - returned {'address': u'[0:0:0:0:0:0:0:1]', 'username': u'Perc'}
for me
does this mean I can kill that session without remorse as it canât possibly be working - or do I need to ask someone to check it to be certain?
EDIT 2:
well, after all that - I just found the âLog Activityâ section under the âDetailsâ button per-userâŚ
guess I was assuming from this thread that there would only be one (or at least not many) offending sessions, so the admittedly non-unique view idâs might not exist in multiple sessions.
For what itâs worth, evey single session in my gateway is spamming âUnable to send updates to clientâ, and if I pass in a view id shown under a particular user's session log activity to my function (after modifying to return a list), it returns a different address and username.
my session (Admin) is âstaticâ - Itâs just open, not in use, so presumably my view ids wouldnât be changing?
example: