[closed] RPG / IBM i / iProjects loading limited set of sourcemembers
Arne Bister (2.6k●1●28●32)
| asked Feb 28 '11, 4:35 a.m.
JAZZ DEVELOPER edited Jun 23 '12, 5:36 p.m.
Working with iProjects for RPG development on IBM i, what feasible options do we have to split a large library of source files into iProjects, such that only the working list of sourcemembers for a certain task gets loaded into the repository workspace?
It seems that once source files and members are added to source control in the context of an iProject, either the entire iProject or select source files with all members can be loaded. There is an option (--> show repository files --> context menu of source member --> load as ...) to load singular source members into a sandbox but then they would be outside an iProject context. How do others work with regard to limiting the amount of source members loaded for working on a task? Just have lots of small iProjects? |
The question has been closed for the following reason: "The question is answered, right answer was accepted" by abister Jun 19 '12, 3:28 a.m.
Accepted answer
Can we correctly analyse dependencies of source files along an arbitrary complex library list with only some source files / members under version control in RTC and the rest on IBM i, so that all versions of certain source files are found? There are a whole bunch of questions here :-) I think you're asking if RTC's IBMi Build with the buildspec is an impact-analysis rebuilder (i.e. which looks at what's changed and calculates the optimal subset of everything that needs to be rebuilt and rebound). It is not that, exactly - it is more similar to the way Apache Ant or a Makefile work - by checking all targets. and rebuilding if they are out-of-synch with their dependencies. One of the good things about this is that the Builders can specify dependencies on any objects or members in the file system, regardless of whether they're under source control or not. If you specify the dependency with library value &SP (aka SearchPath), it will look through the library list to find this dependency, and rebuild if out of synch. The library list is derived from the Build Definition/Jazz Source Control-IBM i page. We set *CURLIB to the iProject's , using the i Projects' object library and source library, and appending whatever Reference Libraries you specify to the library list in the same order (e.g. Baselib, Corelib, 3rdparty-lib, prodlib, etc). We do have source scanners for some build dependencies (e.g. to find copy/include members, and externally-described file's members, in the workspace), and also use these dependencies to determine if the target needs to be rebuilt. These search only within RTC's SCM, so they wouldn't find relationships to external files on the IBMi file system. You would need to specify those external object or member references in the Buildspec builders. I hope this answers your questions on this post -Sean- Arne Bister selected this answer as the correct answer
|
8 other answers
Is there a way of comparing contents of a repository workspace in RTC with the (non versioned) contents of a library on IBM i? If so, how does it behave for IBM i w/ a different character set than the one where the versioned sources are from? There is a "Compare workspace with IBMi libraries" feature, which is limited to comparing Build workspaces to the libraries they are loaded to for an RTC build. Currently, however, this doesn't allow you to compare any workspace to any (set of) libraries on IBMi. To use this feature, select the build workspace, right-click, and select Compare With->IBMi libraries, then login. RTC will use the iProject-library mappings from the associated Build Definition, process the comparison, and open the Compare with IBM i libraries view, |
In a customer environment certain sourcemembers can only be built after a certain command has been run on IBM i. Only some sourcemembers are afflicted and the commands / parameters for them vary. Is there an option to apply different preconditions to sourcemembers (as a user attribute?) such that during a buildspecification build the commands specified in the precondition are executed before each sourcemember is built? I'd recommend changing the Build Specification like this: a) add an extra Command Set to run this setup command and the compile command, using &substitution variables in the setup command that can be specified in the Builder. b) add specific Builders with <include> specification that specifies the special member. In each of these builders, define the values for the substitution variables c) change the default generic Builder to exclude these members. If there are a large number of diverse exceptions, there is always the possibility of writing a build utility program on IBMi to delegate this decision-making to, and have a simple Buildspec Command Set to call this program (e.g. "CALL BLDMYMBR(&L &F &M )") for each member found by the Builder. |
In a customer environment certain sourcemembers can only be built after a certain command has been run on IBM i. Only some sourcemembers are afflicted and the commands / parameters for them vary. Is there an option to apply different preconditions to sourcemembers (as a user attribute?) such that during a buildspecification build the commands specified in the precondition are executed before each sourcemember is built?
I have only found pre- and postconditions as general entries in the build definition specification. But we need different preconditions for each sourcemember which has one and not each sourcemember has a precondition. |
Can we correctly analyse dependencies of source files along an arbitrary complex library list with only some source files / members under version control in RTC and the rest on IBM i, so that all versions of certain source files are found?
Library list (example): Customer Client1 - Client2 - Client3 Lib 1 ! Lib 2 ! Lib 3 ! Baselib ! Corelib Standard sources are in Corelib. A developer searches for source in e.g. Corelib, Baselib, copies the sourcemembers to "Customer" and makes changes. This source change might necessitate changes in a dependent source, versions of which might reside in Lib 1-3, "Client 1-3 a) Does source code data query allow to find all of these versions for the set of libraries? Do we support impact analysis on library content which is (not yet) versioned in RTC? b) Does the IBM i build specification build allow to build the necessary changes into all of the affected libraries? |
Is there a way of comparing contents of a repository workspace in RTC with the (non versioned) contents of a library on IBM i? If so, how does it behave for IBM i w/ a different character set than the one where the versioned sources are from?
Can non-versioned content of libraries on IBM i be tied into impact analysis to find out e.g. which parts are potentially affected by a change of a field definition or table in a database? |
In a customer environment certain sourcemembers can only be built after a certain command has been run on IBM i. Only some sourcemembers are afflicted and the commands / parameters for them vary. Is there an option to apply different preconditions to sourcemembers (as a user attribute?) such that during a buildspecification build the commands specified in the precondition are executed before each sourcemember is built? I'd recommend changing the Build Specification like this: a) add an extra Command Set to run this setup command and the compile command, using &substitution variables in the setup command that can be specified in the Builder. b) add specific Builders with <include> specification that specifies the special member. In each of these builders, define the values for the substitution variables c) change the default generic Builder to exclude these members. If there are a large number of diverse exceptions, there is always the possibility of writing a build utility program on IBMi to delegate this decision-making to, and have a simple Buildspec Command Set to call this program (e.g. "CALL BLDMYMBR(&L &F &M )") for each member found by the Builder. I have found that I can add properties to a source member by going to the iProject Navigator view -> context menu of a source member -> Properties -> Jazz source code management -> User defined properties (names may vary as I only have the german names). Can these values be queried at build time or used to define pre commands which then are executed by a command set? F. e. : Property: preCommand = CRTDUPOBJ MYFILE QTEMP/MYFILE |
Working with iProjects for RPG development on IBM i, what feasible options do we have to split a large library of source files into iProjects, such that only the working list of sourcemembers for a certain task gets loaded into the repository workspace? Is this limitation planned to be resolved. Breaking down source libaries into many iProjects is not always appropriate. From an out of hours emergency fix scenario, the developer only wants to work on the pgm(s) which need fixing, rather than loading a whole project or projects. |
Hi,
the scenario description for what is called sparse loading is being implemented as we speak. It seems that in 4.0 M7 there should be some tangible things to try out if I read this work item correctly. Good news: IBM i is included in the work. You can even see in which successful build the changeset of that resolved work item was first included. - Arne |