Synergy

Issue Tracker (powered by SPIT)

Feature #72 - Logging to file

Status:
Fixed
Priority:
High
Assignee:
None
Category:
None
Target:
1.3.6
Created by:
Created on:
27 May 2009
Updated by:
None
Updated on:
21 Jan 2011 17:45
Platform:
None
Google ID:
gc-63
Redmine ID:
73

Google user: nick.bolton.uk

As defined in ["/p/synergy-plus/wiki/SpecAnalysis":SpecAnalysis #Logging the specification], there are a number
of different log outputters, however, there appears to be no method of
logging to a specified file.

It may be useful for end users, to specify a system file to which Synergy+
should output in the synergyc and synergys command line argyments.

Of course, it is necessary on Unix to run, say, synergyc in foreground mode
(but in the background) and direct the output to a log file.

synergyc -f my-server > synergyc.log 2>&1

This approach does however require a slightly more in depth understanding
of the Linux command line, which not all users are interested in learning.



#1

27 May 2009: Issue Importer wrote a comment.

Google user: nick.bolton.uk

Corrections:

The wiki URL intended was:
"http://code.google.com/p/synergy-plus/wiki/SpecAnalysis#Logging":http://code.google.com/p/synergy-plus/wiki/SpecAnalysis#Logging

The example command to run synergyc in the backrgound with logging is incorrect;
while it does redirect the output, it does not run the process in the background. To
do this, an additional ampersand must be added.

synergyc -f my-server > synergyc.log 2>&1&

The behaviour to implement should be as similar to this as possible; the user must be
able to use the following command to follow the output:

tail -f synergyc.log


#2

27 May 2009: Issue Importer wrote a comment.

Google user: nick.bolton.uk

The argument syntax should be like so:

synergyc -l synergyc.log my-server

Where -l is the "log to file" argument, and synergyc.log is a user specified log file
name.


#3

8 Jun 2009: Issue Importer wrote a comment.

Google user: nick.bolton.uk

Moving this up to high priority as it will improve development efficiency.


#4

8 Jun 2009: Issue Importer wrote a comment.

Google user: nick.bolton.uk

Me and Sorin agree that this will be useful for debugging when running as Windows
service. The stderr stream may not be flexible enough.


#5

8 Jun 2009: Issue Importer wrote a comment.

Google user: nick.bolton.uk

It may also be a good idea to have the Windows GUI console window read the contents
of this file every 1 second, instead of writing to the text box directly.


8 Jun 2009: Issue Importer changed Priority.

Normal High


#6

21 Jun 2009: Issue Importer wrote a comment.

Google user: nick.bolton.uk

This would apply to both client and server:

  • synergyc
  • synergys

#7

14 Jul 2009: Issue Importer wrote a comment.

Google user: edw...@carrel.org

Here's a completely random thought?

Have we considered substituting in a third-party logging library for our internally
rolled logging system? It would be one less thing we would have to extend and
maintain ourselves. shrug


#8

14 Jul 2009: Issue Importer wrote a comment.

Google user: nick.bolton.uk

Cool. What ideas for libs did you have? What would be the advantages over a flat file?


#9

10 Aug 2009: Issue Importer wrote a comment.

Google user: nick.bolton.uk


10 Aug 2009: Issue Importer changed Status.

New Accepted


#10

15 Sep 2009: Issue Importer wrote a comment.

Google user: ad...@mar.lt

I made a patch for logging to files.

I added -l + COutputterFileLogger implementation (+modified headers)

It patches both synergys and synergyc. I've created logger in mainLoop(), maybe it
needs some refactoring?

It's my first patch for OS project, so check it carefully.
Thanks.


#11

15 Sep 2009: Issue Importer wrote a comment.

Google user: ad...@mar.lt

Made some changes to prev. diff to match
"http://code.google.com/p/synergy-plus/wiki/Specification":http://code.google.com/p/synergy-plus/wiki/Specification


15 Sep 2009: Issue Importer uploaded a file.

loggingToFile.diff - 27 Aug 2010 23:34


15 Sep 2009: Issue Importer uploaded a file.

loggingToFile-2.diff - 27 Aug 2010 23:34


#12

21 Sep 2009: Issue Importer wrote a comment.

Google user: syed.a...@gilani.eu

Patch applied to main branch.
Please post feedback.


21 Sep 2009: Issue Importer changed Status.

Accepted ?


#13

27 Dec 2009: Issue Importer wrote a comment.

Google user: nick.bolton.uk

Works nicely for me - thanks patch author!


27 Dec 2009: Issue Importer changed Status.

? ?


#14

5 Jun 2010: Issue Importer wrote a comment.

Google user: nick.bolton.uk


5 Jun 2010: Issue Importer changed Target.

? ?


23 Sep 2010 20:57: Nick Bolton changed Status.

? New


23 Sep 2010 20:57: Nick Bolton changed Target.

? ?


23 Sep 2010 20:57: Nick Bolton changed Status.

New Accepted


#15

23 Sep 2010 20:57: Nick Bolton wrote a comment.

Needs backporting to 1.3.2.1


23 Sep 2010 21:23: Nick Bolton changed Status.

Accepted InProgress


23 Sep 2010 21:23: Nick Bolton changed Assignee.

3


#16

23 Sep 2010 21:23: Nick Bolton wrote a comment.

Backported to see if this would help diagnose #2689 but it doesn't have times! So that's probably the next step (to add times to log messages).

TODO: See if newer version has times in the log file, and if it does, backport that issue. Otherwise create a new issue for this purpose, and implement in all versions.


11 Jan 2011 17:09: Nick Bolton changed Status.

InProgress Fixed


11 Jan 2011 17:09: Nick Bolton changed Target.

?


#17

11 Jan 2011 17:09: Nick Bolton wrote a comment.

Abandoning 1.3.2.x roadmap.


16 Jan 2011 23:48: Nick Bolton changed Assignee.

3


21 Jan 2011 17:45: Nick Bolton changed Target.

1.3.6