Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 302019 - PBS support
Summary: PBS support
Status: CLOSED FIXED
Alias: None
Product: PTP
Classification: Tools
Component: RM (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Roland Schulz CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-02-05 19:52 EST by Dieter Krachtus CLA
Modified: 2010-05-31 19:08 EDT (History)
6 users (show)

See Also:


Attachments
Eclipse Java proxy project. (3.44 KB, application/zip)
2010-02-05 19:53 EST, Dieter Krachtus CLA
no flags Details
PBS patch (16.67 KB, patch)
2010-02-05 19:54 EST, Dieter Krachtus CLA
no flags Details | Diff
Eclipse Java proxy project. (1.26 MB, application/zip)
2010-02-12 12:43 EST, Dieter Krachtus CLA
no flags Details
PBS patch (28.92 KB, patch)
2010-02-12 12:43 EST, Dieter Krachtus CLA
no flags Details | Diff
Eclipse Java proxy project. (809.38 KB, application/zip)
2010-03-01 16:42 EST, Dieter Krachtus CLA
no flags Details
latest version of PBS Proxy (1.34 MB, patch)
2010-03-05 01:16 EST, Roland Schulz CLA
no flags Details | Diff
PBS patch (1.38 MB, patch)
2010-03-09 10:11 EST, Dieter Krachtus CLA
no flags Details | Diff
Latest version after making it more general (742.12 KB, patch)
2010-03-27 01:35 EDT, Roland Schulz CLA
g.watson: iplog+
Details | Diff
new version. Adding org.eclipse.ptp.proxy.jproxy. Enabling submit. (173.50 KB, patch)
2010-04-15 01:41 EDT, Roland Schulz CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Dieter Krachtus CLA 2010-02-05 19:52:04 EST
Build Identifier: HEAD

Initial PBS support. The attached files below contain the beginning of the remote Java proxy. Mainly includes communication with the server sending events/messages that are generated by live monitoring PBS XML output (qstat, pbsnodes).

Reproducible: Always
Comment 1 Dieter Krachtus CLA 2010-02-05 19:53:25 EST
Created attachment 158367 [details]
Eclipse Java proxy project.
Comment 2 Dieter Krachtus CLA 2010-02-05 19:54:05 EST
Created attachment 158368 [details]
PBS patch
Comment 3 Dieter Krachtus CLA 2010-02-05 20:02:56 EST
I already started implementing the XML output monitoring by the Java proxy used to propagate PBS updates in the form of events/messages to Eclipse (not included yet in the files above). I try to get more progress done over the weekend - feedback is appreciated.
Comment 4 Greg Watson CLA 2010-02-05 20:56:28 EST
Please add a declaration of your right to contribute this software. Thanks!
Comment 5 Dieter Krachtus CLA 2010-02-05 21:17:10 EST
(In reply to comment #4)
> Please add a declaration of your right to contribute this software. Thanks!

I, Dieter Krachtus, declare that I developed attached code from scratch, without referencing any 3rd party materials except material licensed under the EPL.
Comment 6 Roland Schulz CLA 2010-02-05 21:27:02 EST
(In reply to comment #5)
> (In reply to comment #4)
> > Please add a declaration of your right to contribute this software. Thanks!
> 
> I, Dieter Krachtus, declare that I developed attached code from scratch,
> without referencing any 3rd party materials except material licensed under the
> EPL.

I, Roland Schulz, declare that I developed attached code from scratch,
without referencing any 3rd party materials except material licensed under the
EPL.
Comment 7 Greg Watson CLA 2010-02-08 14:50:46 EST
Hi, any new files that you contribute require a copyright statement like the following as the first thing in the file. Would you please add to any new files and resubmit? Also, if you have additional source, please attach to the bug asap. Thanks.

/*******************************************************************************
 * Copyright (c) {DATE} {INITIAL COPYRIGHT OWNER} {OTHER COPYRIGHT OWNERS}.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *    {INITIAL AUTHOR} - initial API and implementation
 *******************************************************************************/
Comment 8 Dieter Krachtus CLA 2010-02-12 12:42:29 EST
+ PBS XML output (qstat, pbsnode) is unmarshalled into JavaBeans.
+ Proxy server event loop added. 
+ Events are generated and proxy client UI is populated with machines,queues,nodes,jobs.
+ add copyright information to new files.
- runtime commands triggered by the UI (e.g. remove job) are still ignored.



Usage:
Import the attached zip files in Eclipse as new project and apply the attached patch (created against HEAD). Launch Eclipse PTP, switch to the 'Parallel Runtime' perspective and add a PBS Resource Manager in the 'Resource Managers' view: use 'local' for remote service provider and proxy server location. Add path to proxy executable (.sh file for Unix - chmod +x, .bat file for Windows). Start the resource manager to trigger communication and population of the UI.

This code is still incomplete/buggy and merely a snapshot for interested testers/reviewers.
Comment 9 Dieter Krachtus CLA 2010-02-12 12:43:12 EST
Created attachment 159004 [details]
Eclipse Java proxy project.
Comment 10 Dieter Krachtus CLA 2010-02-12 12:43:40 EST
Created attachment 159005 [details]
PBS patch
Comment 11 Dieter Krachtus CLA 2010-03-01 16:41:33 EST
(In reply to comment #10)
> Created an attachment (id=159005) [details]
> PBS patch

New snapshot of the current PBS support proxy server project.

Main changes include the initial support to detect changes in resources like jobs and the successful communication to the Eclipse client by generating NEW_JOB, REMOVE_JOB events. The UI is successfully updated (i.e. jobs are added and removed from the jobs list in real time).
Comment 12 Dieter Krachtus CLA 2010-03-01 16:42:52 EST
Created attachment 160546 [details]
Eclipse Java proxy project.
Comment 13 Greg Watson CLA 2010-03-04 17:05:11 EST
I've added an empty project to CVS.
Comment 14 Roland Schulz CLA 2010-03-05 01:16:19 EST
Created attachment 161074 [details]
latest version of PBS Proxy

This patch includes both the Jproxy project and the changes to other parts of the code.
Before applying the patch, checkout the org.eclipse.ptp/rms/org.eclipse.ptp.rm.pbs.jproxy CVS project.

New features in this version:
    queues are shown (Benjamin Lindner)
    node and machine status is shown
Comment 15 Randy Roberts CLA 2010-03-05 11:48:33 EST
(In reply to comment #13)
> I've added an empty project to CVS.

Remember to add this to the project set, when the time comes.
Comment 16 Greg Watson CLA 2010-03-05 12:32:57 EST
I've updated the project sets and build files to include jproxy rather than the C proxy.
Comment 17 Dieter Krachtus CLA 2010-03-09 10:06:55 EST
This patch removes all dummy data used before by introducing an actual hierarchy between resource_manager, machines, queues, nodes and jobs. The UI is now almost fully populated and correctly updates as new/remove events now work properly for queues, nodes and jobs. The 'Resource Manager View tree model' is properly updated but not visually refreshed (double click on tree node visually refreshes its leaves).

upcoming: change events, proper source code documentation
Comment 18 Dieter Krachtus CLA 2010-03-09 10:11:07 EST
Created attachment 161471 [details]
PBS patch

Patch against PTP HEAD.
Comment 19 Roland Schulz CLA 2010-03-27 01:35:49 EDT
Created attachment 163134 [details]
Latest version after making it more general

As before: you need to make the proxy.sh executable and specify the proxy.sh path in the "Add new PBS RM Dialog".

Monitoring and deleting of jobs works.
It should be easy to create new RMs based on this.

Submitting of jobs does not work yet.
Comment 20 Greg Watson CLA 2010-04-14 18:48:02 EDT
This has now been committed with some changes:

1. The patch to AbstractRemoteProxyRuntimeClient hasn't been committed as it will break all existing proxies.
2. The sample XML files haven't been committed as IP concerns were raised by Eclipse.
3. The attribute descriptions have been removed due to IP concerns. It would be best if these could be obtained by the proxy, but if not we can submit another CQ.
Comment 21 Roland Schulz CLA 2010-04-15 01:17:43 EDT
(In reply to comment #20)
> This has now been committed with some changes:
> 
> 1. The patch to AbstractRemoteProxyRuntimeClient hasn't been committed as it
> will break all existing proxies.
Dieter only did this to fix a problem under Windows (that it splits arguments separated by a "="). There should be a different way. And anyhow PBS won't run often on Windows.

> 2. The sample XML files haven't been committed as IP concerns were raised by
> Eclipse.
There are not needed. Just used for testing. So this is OK.

> 3. The attribute descriptions have been removed due to IP concerns. It would be
> best if these could be obtained by the proxy, but if not we can submit another
> CQ.

As discussed before, we don't think you can discover it. Also as discussed, it will be moved into an XML file. But I assume regarding IP concern it doesn't matter whether it is in XML or in the java code.
Comment 22 Roland Schulz CLA 2010-04-15 01:41:04 EDT
Created attachment 164931 [details]
new version. Adding org.eclipse.ptp.proxy.jproxy. Enabling submit.

The patch assumes an complete empty (including no .project, .settings, ...) org.eclipse.ptp.proxy.jproxy project.

The test XML files are not included. Thus debugReadFromFiles has to be false and a PBS server has to be available on the machine where the proxy is running. 

new in this patch:
commit 7f636f2
Author: Roland Schulz <rschulz@rschulz-laptop.(none)>

    undo usage of OSGI-INF for bundle-name

commit 1faf70a
Author: Roland Schulz <rschulz@rschulz-laptop.(none)>

    undo unnessary changes (debugging, format changes, ...) to clean up patch
    undo of change to --host, --port format

commit 23fb0fb
Author: Roland Schulz <rschulz@rschulz-laptop.(none)>

    fix merge
    fix copyright

commit 6200b0c
Author: Roland Schulz <rschulz@rschulz-laptop.(none)>

    satisfy Helios requirements (warnings in MANIFEST, externalize strings)


commit 529053f
Author: Roland Schulz <rschulz@rschulz-laptop.(none)>

    don't use PBS -d option because not supported by abe

commit 5a00a91
Author: Roland Schulz <rschulz@rschulz-laptop.(none)>

    deactived packet debugging (can be reactivated in ProxyPacket)
    send error message if exec of qsub throws IOExeception (e.g. file not found)


commit 2207350
Author: arossi <arossi@ncsa.uiuc.edu>

    Fixed the saving of widget state to preserve entries from open to open.

commit f3dd3e4
Author: Roland Schulz <rschulz@rschulz-laptop.(none)>

    implemented 1st test version for submiting jobs (submitting works, but errors
    don't and many things still hard-coded)


commit b136215
Author: arossi <arossi@ncsa.uiuc.edu>

    A simple test implementation of PBS job submission.

commit 65dd7a2
Author: arossi <arossi@ncsa.uiuc.edu>
    Changed Job Attributes to be stored in a map; made their names public.
    First pass at rebuilding the LaunchConfigurationDynamicTabs to expose two levels of detail.
    Currently the run command does not seem actually to do anything.
Comment 23 Dieter Krachtus CLA 2010-04-15 07:30:57 EDT
Yes. I think one could modify the Windows jproxy.bat file in order to keep the arguments from getting split. I'll look into it.



> > 1. The patch to AbstractRemoteProxyRuntimeClient hasn't been committed as it
> > will break all existing proxies.
> Dieter only did this to fix a problem under Windows (that it splits arguments
> separated by a "="). There should be a different way. And anyhow PBS won't run
> often on Windows.