Join 34,000+ subscribers and receive articles from our
blog about software quality, testing, QA and security.

Watches from two servers running same code


#1

Is there a way to combine/seperate the watch variables from both servers (same application)?

It seems that the watch pane only reflect the last update.


#2

Hello,

Thanks for your posting. That’s currently not supported and I would recommend adding a prefix/suffix to the Watch names, e.g.

Server 1: Global.SessionCount Server 2: Global.SessionCount

Would this work for you?

Regards,
Tobias


#3

Thanks, I figured that was the way it had to be done. Thanks.

public static class Global
    {
        public static string ServerName { get { return System.Environment.MachineName; } }

        private static int _SessionCount { get; set; }
        public static int SessionCount {
            get { return _SessionCount; }
            set {
                _SessionCount = value;
                SiAuto.Main.WatchInt( Global.ServerName + ": Global.SessionCount", value);
            }
        }
    }