perforce-plugin icon indicating copy to clipboard operation
perforce-plugin copied to clipboard

p4.prog reporting feature

Open jkapica opened this issue 10 years ago • 6 comments

This patch provides capability to report custom p4 program name to the Perforce server.

p4.prog is an arbitrary string which identifies the application establishing connection to p4 server. It can be later traced in server logs as well as with p4 monitor. It is very useful if you have several automated systems connecting to p4 server, and you want to be able to easily trace and account them.

Javadoc is pretty scanty about the parameter, below link to python docs: http://www.perforce.com/perforce/doc.current/manuals/p4script/03_python.html#1120041

jkapica avatar Apr 08 '14 08:04 jkapica

plugins » perforce-plugin #94 SUCCESS This pull request looks good

I definitely vote for such feature. BTW, the PR follows the extensive approach, because it adds new entries to the monstrous PerforceSCM class. I'd suggest to move such feature to a separate class if there is any possibility of new features/configuration options to be added.

Probably, it would be good to have a P4ProgramProvider extension point (see #45 for a similar approach). It will allow to provide more flexibility and to decouple logic from PerforceSCM as well.

Unfortunately, seems the development of the plugin has been put on hold due to the unclear situation with guys from Perforce, who want to create their own plugin. Probably, @rpetti could provide more information on future actions with the existing plugin.

oleg-nenashev avatar Apr 08 '14 09:04 oleg-nenashev

Thank you for a pull request! Please check this document for how the Jenkins project handles pull requests

jenkinsadmin avatar Apr 08 '14 12:04 jenkinsadmin

Your proposal is reasonable and it would probably be more elegant, unfortunately I'm not sure when I'll find some time to rewrite it the way you described. From my pov I have a working solution that is "good enough" atm.

I'd be interested to hear about the perforce2 plugin. Maybe there is no point in making this one more elegant, if it's going to be scratched anyway.

jkapica avatar Apr 10 '14 08:04 jkapica

@jkapica Do you plan to rework this PR? The improvement LGTM, but it should be merged with a current version at least

oleg-nenashev avatar Nov 05 '14 05:11 oleg-nenashev

Sorry. After I got it working in my instance, this endded up on end of my priorities list. I agree that the rework is a good idea, but it may be over my capacity. TBH, I'm still running old version. Since there are conflicts in this pull request, you are free to reject it. I will review this item again, and create new request when time for update comes. Hopefully sooner rather than later :}

jkapica avatar Nov 05 '14 20:11 jkapica