The long awaited support for VSAM artifacts is now made available in version 2.0.0. The diagram editor’s data model was modified to support the extra data for records and sets, hence the major version upgrade.
Along the development of the VSAM support feature, a lot of work was put in learning the Groovy programming language (as a result of reading some fine Groovy related books during the last year or so), for writing easier to write and better to maintain test cases (using, eventually, the Spock Test Framework). I even developed a DSL (Domain Specific Language) to make creating test contexts easier as well. Although care has been taken to thoroughly test everything, it is still quite possible that not everything will work for you; if you find yourself in that situation, do NOT hesitate to send me a mail and I will try to fix your problem asap.
So, what else is new in this release ?
- When an error occurs on a schema import, you should now get a more decent error reporting dialog and no longer a tiny empty one. Finding the problem on an import wasn’t always easy until now, so I hope this fix makes life easier.
- In contrast to the CA IDMS documentation, which, for sorted sets, specifies that “No element that redefines another element or is subordinate to an element that redefines another element can be used in the sort control element”, such elements are now allowed in a set’s sort key (this was a problem for one diagram editor user, so apparently this constraint isn’t enforced by the CA IDMS schema compiler and that is the reason I removed this check).
- New tabs in the Properties view :
- VSAM CALC : control the vsam-calc-location-mode-specification clause for VSAM CALC records.
- VSAM Type : control the VSAM TYPE clause for VSAM and VSAM CALC records.
- Index : control the indexed-set-mode-specification clause for indexed sets.
I would have liked to add a tab for records and sets, showing the DSL, but I didn’t manage to build the project with Maven because of the Groovy classes involved. I looked at Gradle and the (don’t laugh) wuff plug-in, and they seem promising, but I guess it would take several weeks to get this under control. So that is something to look out for in the future 🙂
It’s been a while since my previous post because I’m working hard on developing a so-called DSL (Domain Specific Language), targeting easier testing : during the development of the VSAM support feature it became clear that an easier way of creating test objects is needed.
Let me show you an example of a piece of syntax that will allow the Schema Diagram Editor to create a set object :
This piece of syntax is far less verbose than the IDMS schema syntax that we’re used to and, of course, it contains some diagram editor specific data. Nevertheless, it is perfectly human readable and feels natural in comparison to the official IDMS schema syntax, plus, it’s easy to tweak.
Behind the scenes, I’m using Groovy, a programming language that runs on the Java VM and integrates perfectly with Java, which offers some really groovy (dynamic) features; a language like Groovy is perfect to do things like this (though I’m far from an expert since I started learning Groovy only a couple of months ago).
At this moment, syntax like this can be generated for any Schema Diagram Editor (.schema) file (i.e. in my development environment) and the code for producing an object tree from that syntax (remember the model ?) is almost finished, so I’ll soon be able to use syntax like this (which actually is Groovy code) in the Diagram Editor’s test cases (which are evolving towards Groovy and Spock, because they make testing easier and more fun to do).
If this turns out to be successful (and I’m sure it will be), it might me a nice idea to use this ‘format’ as an alternative for the xml that is now used to save an IDMS diagram to disk.
As you can read, I’m still having a lot of fun with taking the Eclipse IDMS Schema Diagram Editor further in its development 🙂
While creating a diagram from scratch for a new IDMS schema we’re working on, a couple of bugs came to the surface. A hotfix release is now available : version 1.7.5. If you create diagrams from scratch (this is NOT the same as importing one from schema syntax or directly from a dictionary) or are adding records and sets via the diagram editor, I would advise you update your version of the diagram editor.
The following bugs were fixed (please refer to the GitHub repository for details) :
- 6d2417f: Creating a user owned indexed set does NOT create an indexed set mode specification
- e3a2f32: Trying to reorder the pointers in a record’s prefix results in a NPE
- af66762: Changing a record name does NOT update the graphical figure’s tool tip
- 4a748e1: Changing a set name does NOT update the connection figure’s tool tip
- 88d36c4: Changing a set name does NOT update the set label figure’s tool tip
- d4cb0a7: Changing an index name does NOT update the index figure’s tool tip
- 0f7d92f: Changing a set name does NOT update the connector figures’ tool tips
(drop the set and create it again with version 1.7.5 in the case of the first bug, 6d2417f; an alternative is editing the XML file that holds the diagram, look at a system owned indexed set or an imported user owned indexed set for an example, you’ll want to add an ‘indexedSetModeSpecification’ element).
As I said, I created a diagram from scratch, meaning I had no schema in my dictionary available. Because getting elements into a record is still somewhat tricky in the diagram editor and elements are vital in a diagram of course, I will briefly outline the procedure I followed to create the complete diagram :
- Create a new empty diagram.
- Drop a record for each record in your new schema; for each record, change the following items (via the Properties view) :
- The record name (General tab)
- The record synonym name and version (Dictionary tab)
- Define all records with their synonyms in your dictionary.
- Export your diagram as schema syntax and create the schema in the dictionary using the generated syntax.
- Update your diagram in the diagram editor (Update menu-item when you right-click on your diagram in the Package or Project Explorer view).
- You now have all elements available and can finish your diagram by applying all the details (indexes, sets, location mode, …).
As a bonus, you can export the diagram as schema syntax and use that syntax to define the final version of the schema; there are some things you’ll need to change in the syntax :
- Indexed set mode specification details (key count, displacement)
- You’ll want to specify RECORD LENGTH and CONTROL LENGTH in cases where you want to specify MINIMUM ROOT and FRAGMENT LENGTHs (you can only fill out a number, not any of these 2 special items).
All in all, I’m pretty satisfied with the result and you bet that generating schema syntax can save you time and errors 😉
A new version of Eclipse has just been released; it’s called Mars and refers to version 4.5.
You can download it here.
I have installed the diagram editor through the Eclipse Marketplace client and took it for a (very short) spin in Mars. That didn’t cause any problems, so that is (again) good news.
The legacy Ecore Diagram Editor is now definitely gone, so the model diagram will be replaced by a newer version in the future (a .aird file will replace the .ecorediag file in the model plug-in).
While continuing the work on VSAM support earlier this week, I was notified of some import from schema syntax issues.
I fixed the following bugs and published version 1.7.4 which you should be able to install by selecting the Eclipse workbench’s Help/Check for Updates menu item. I recommend to install this update asap to avoid problems when importing from syntax.
- 335bd1a : logic error when determining record prefix/suffix (import from syntax)
- 67763ec : import from syntax does NOT detect default WITHIN AREA clause (indexes)
- 6dd4b1b : unnecessary min. frag. length invalid > data length (syntax import)
- 210ce21 : unnecessary min. frag. length invalid > data length (Properties)
See GitHub for the code changes and some more (brief) information…
A big thanks to Sat Pal for reporting these issues !
It appears there has been a problem with the diagram editor’s update site. This problem might have been introduced when publishing the latest release, 1.7.3 (on April 25th), but I’m not sure because I always do a test installation and, if my memory serves me well that did work 😦
Anyway, that issue should be resolved now, if you ever encounter problems when installing the diagram editor, contact me !
The develop branch on GitHub contains a version of the diagram editor that is capable of generating diagrams for schemas that contain VSAM records and sets.
In order to be able to use that version, you’ll first have to build the update site for it (which is described here) and then update the diagram editor using that update site. For convenience, I’ve put an archived version of that update site on Dropbox; make sure you use the ‘Archive…’ button to point to the .zip file :
This is only the first version that supports VSAM and it is far from complete, but (hopefully) fine if all you want to do is generate diagrams for your schemas (and thus not develop diagrams from the ground up or modify existing structures).
Also, bear in mind that diagrams that you create with the develop version of the diagram editor are NOT compatible with the current production version.
As always, I welcome all feedback !