≡ Menu

How To Track The Deployed BMIDE Template Version

Share the knowledge

I’ve got a tip to share today, but frankly, I’m hoping someone out there has a better solution — so if you do, please leave a comment and enlighten me!

Which BMIDE Template Version is Currently Deployed?

One advantage to the new BMIDE way of developing a data model is that the data model now exists as a set of XML files which can be managed with a version control system. It is very useful to be able to track changes to the model over time and to be able to coordinate development with others, however the problem is, how can I tell which BMIDE template version is actually deployed to each specific instance of Teamcenter? How can I check if we’re using this morning’s data model or if we’re still using the version that we deployed last week? How do I verify that all of our development, test, and production systems all have the save version of the data model?

I’ve found no good solution, but here’s the best we’ve been able to come up with:

A solution

When I’m ready to package and deploy an update to the data model I update the display name of the template with a date-stamp. For example, PLM Dojo Data Model 2011.12.29a.

Problems with the Solution

There are two things I don’t like about this solution. First, it’s dependent on me remembering to update the display name. I’m getting better, but I haven’t always been perfectly diligent about it. Second, as best as I can tell the only way to check the display name of the current template is to launch TEM and then check on what’s installed with that. I would much prefer to be able to tell from within a client session. Something on the About dialog window would be just about ideal.

Anyone Got a Better Idea?

Here’s where I’m hoping someone out there might have a more creative solution. My ideal solution would work without me having to remember to do something special and be something I could verify from the client.

So, any ideas out there?

  • Shiv Patil

    Hi Scott,

    I am thinking of this solution. Don’t know how much it will be useful for you.
    I assume that you are on Tc8.3. In this all the BMIDE templates will be stored in a folder inside Teamcenter. Use General search in Name field provide “Fnd0BMIDEResource”. This will give us a folder containing the deployed templates. Now we can select master.xml or model_backup.xml and view its properties. See the last modified date. Like this you can get the details of when was the last time templates got deployed. Now we can go back to version control system and find the status of the template on that date.

    This solution looks bit complicated and too technical but results are reliable.( I hope all the tempates are deployed successfully)

    With Regards
    Shiv Patil

    • http://plmdojo.com Scott Pigman

      Thanks, Shiv, I did not know about the fnd0BMIDEResource folder. That is useful information. I wouldn’t trust the last modified date though, after all, the admin could have accidentally grabbed the wrong package to deploy. We’ve had it happen. Still, I presume that the display name is embedded in one of those XML files. At least I wouldn’t have to fire up TEM to check the display name.

      thanks for contributing,

      S

  • http://hooverm.pip.verisignlabs.com/ Teamcenter Heretic

    So, while this doesn’t address the requiremrent here is what I do to find out what is what in a deployment (windoz flavor):

    1. Set the environment variables PASSWD and TEMP_WORKING_DIR

    2. Copy all of the template files into the temporary directory:

    copy %TC_DATA%model*_dependency.xml %TEMP_WORKING_DIR%
    copy %TC_DATA%model*_template.xml %TEMP_WORKING_DIR%
    copy %TC_DATA%modellang*_template_*.xml %TEMP_WORKING_DIR%lang
    copy %TC_DATA%modelmaster.xml %TEMP_WORKING_DIR%

    3. Consolidate the template files:

    %TC_ROOT%binbmide_consolidator -dir=%TEMP_WORKING_DIR% -file=model_consolidated.xml -consolidate=all

    4. Extract from the database:

    %TC_ROOT%binbusiness_model_extractor -u=infodba -p=%PASSWD% -g=dba -outfile=model_extracted.xml -mode=all

    5. Compare templates vs. database:

    %TC_ROOT%binbmide_comparator -compare=all -old=model_extracted.xml -new=model_consolidated.xml -delta=check_delta.xml -log=compare_model.log

    Now you simply look at the delta file for add/delete/change lines

    • http://plmdojo.com Scott Pigman

      Cool, thanks. I didn’t know about this option. It’s not quite what I’m looking for but it’s always good to have another tool in the toolbox. I’m sure it’ll come in handy someday.

  • Guest

    You can modify the install-Script of the BMIDE-TemplateProject and add a preference_manager command that sets a preference to the current date or whatever you want during tem-install.

    • http://plmdojo.com Scott Pigman

       That’s a very interesting idea, and timely too. I was working on the install scripts and adding calls to preference_manager just this week. Since we’re using Subversion, what I’d like to do is user the “global rev” in the preference value somehow. Regular SVN keyword substitution doesn’t support the substituting the global revision number. It seems though that svnversion may be an option if I can figure out how to invoke it during the process of building a template to deploy. I’ll have to ponder this a bit more, thanks again.

      • Guest

        AFAIK you cannot hook into the Package-Process. I also wanted to do this before. What I do is having a script on the server that does the checkout of the package from svn, unzip,makes some changes like the preference,…,zip the install-archive.

  • Vijay Lakshman

    As a part of the Live Update project we added new functionality to the BMIDE which had  similar requrements. We needed to something similar to what DMS does and manage timestamps and similar such info for our templates.
    Whenever you do a hot deploy or package a template from BMIDE we update a file called “client_[your_template_name].properties”
    This file lies within your project dir. It contains a FullDeployCS. We call this the full deploy consistency stamp.

    Now open up your tc command prompt and type in the following command:
    bmide_manage_templates -u=[username]-p=[passsword] -g=dba -option=list

    This will generate an output file similar to one below:

    —————————————————————————————————————–
    Template   | Full Deploy CS                                                           | Full Deploy Date
    ——————————————————————————————————————
    customa      | 163FECDEBE7F7015F4603611B6639941   | 23-Apr-2012 10:04           |
    foundation | gMN9JINUIV0pjD                                                  | 19-Apr-2012 15:19             |

    Compare this with your client_*.properties consistency stamp and you know if you are in sync or not.
    We use this internally to find out who is in sync and who isnt.

    • http://plmdojo.com/ Scott Pigman

      That sounds like exactly what I was looking for. Thank you for sharing. I’ll give this a try tomorrow.
      Thanks again,
      ~Scott

  • Pingback: 12 Ways to Improve the BMIDE Interface | The PLM Dojo()

Optimization WordPress Plugins & Solutions by W3 EDGE