[Logo] JCVSForum - Community Support For JCVS Users and Developers
  [Search] Search   [Recent Topics] Recent Topics   [Hottest Topics] Hottest Topics   [Members]  Member Listing   [Groups] Back to home page 
[Register] Register / 
[Login] Login 
Problem with log command  XML
Forum Index » JCVS Developers
Author Message
angus70



Joined: 08/09/2004 04:30:30
Messages: 13
Offline

<pre>Hi, I use jcvs library with ssh connection and I experienced a curious problem
with a log command. The result of the command is duplicated and appear twice !

Of course, I defined correctly all the parameters like username, password etc...
the command succeed but the result appear duplicated !

Here is my code , could someone help me ?


</pre>

This message was edited 4 times. Last update was at 21/02/2005 20:21:24

[Email]
time


[Avatar]

Joined: 05/06/2004 18:09:23
Messages: 367
Location: Bangkok
Offline

You do not include the output of your program, so I am not sure what you mean by
"output is duplicated". First, if you are setting the CVSUserInterface, the
class you are using can be outputing the server's output, and then you display
it a second time with getDisplayResults().

Also, note that your command spec: ":log:p:EAF:di:" is not quite right, because
the "F" flag says to send all of the CVSEntrys as filename arguments. So if you
are seeing two log outputs for one file, it could be because you are setting
those files as explicit arguments, as well as having the "F" flag set them for
you. So you are asking for the output for the same file twice. Try using this
command specification: ":log:p:EA:di:".

I am going to try to email my sample code to you and hope it helps.
[Email] [WWW]
Anonymous



Hello Tim,

First of all, I want to thank you for your quick reply. You save my life
I don't receive your mail on my mail box, but it is not necessary now.

The problem came, as you said, from my command spec which should be
":log:p:EA:di:" and not ":log:p:EAF:di:".

It seems that I have not perfectly understand the syntax.
In fact, I try to use jCVS library without the graphical interface, and I find
not evident to develop some commands from scratch.
If you have time, I think it will be a good idea to put some examples of a check
out or a log on the forum or on a document on your site for poor developer like
me!

Furthermore, I have some questions that still remain :

Why do I have to define a project and a request object with approximatively the
same arguments ? (I feel that I am doing the work twice for nothing...). Is it
possible to use only the project object ?

I am not sure to understand well how the ' CVSUserInterface' is used in your
library. In my application, I just need to get response from the server (like in
displayResponse function).
I see in CVSClient code that a NullCVSUI is implemented. Am I obliged to
implement such interface to do what I want ?

I succeed to etablish an ssh connection with a private/public key
authentification by modifying your CVSClient. I found only a SSH password
authentification method implemented in it. It seems that you haven't implement
the 'private/public key' case in your CVSClient. Am I rigth or is there
something I miss ? In this case, it would be a good idea to create a connection
object (which could implement SSH,pserver conections...) to pass to the
CVSClient in a next release of your library.

Well, I hope that my experience of newby of jCVS library give you some ideas to
make it better. (it is already the best library I found !!!)

Regards

Fabian
time


[Avatar]

Joined: 05/06/2004 18:09:23
Messages: 367
Location: Bangkok
Offline

Why do I have to define a project and a request object with approximatively the
same arguments ? (I feel that I am doing the work twice for nothing...). Is it
possible to use only the project object ?

I am not sure to understand well how the ' CVSUserInterface' is used in your
library. In my application, I just need to get response from the server (like in
displayResponse function).
I see in CVSClient code that a NullCVSUI is implemented. Am I obliged to
implement such interface to do what I want ?

I succeed to etablish an ssh connection with a private/public key
authentification by modifying your CVSClient. I found only a SSH password
authentification method implemented in it. It seems that you haven't implement
the 'private/public key' case in your CVSClient. Am I rigth or is there
something I miss ? In this case, it would be a good idea to create a connection
object (which could implement SSH,pserver conections...) to pass to the
CVSClient in a next release of your library.


1) The reason for the separation of CVSProject and CVSRequest is a layer issue. It is possible to make CVSRequests without a CVSProject, although it is rare. Thus, the two must be separated. However, you should never have to fill out a CVSRequest except in the cases of Checkout and Export, as there is no CVSProject to fill in the CVSRequest for you. See the sample code in the tutorial.

2) The CVSUserInterface is most important for GUI's. It is the only way for the GUI to get callbacks to report the progress of a request to the user. In the case of command line apps and other text based apps, the CVSResponse.getDisplayResults() or getDisplayText() method is essentially all you need. NullCVSUI is a convenience for those who want the UI callbacks to do nothing.

3) I will add the SSH key pair change to the todo list.

[TODO]

This message was edited 1 time. Last update was at 08/10/2006 14:59:30

[Email] [WWW]
 
Forum Index » JCVS Developers
Go to:   
Powered by JForum 2.1.9 © JForum Team