vdlight Absent Member.
Absent Member.
4161 views

Upgrading a large step from SDK 2005 R2 to SDK 14.0, C++

Jump to solution

When we updated our starteam server some of our own developed programs using SDK 2005 started to crash.

I downloaded update for our server that is version 14 now, sdk 14.0.4.19.

I ran into problems. Because previously i could use a Starteam.TLB file in my c++ project, and get the application to generate information regarding file revisions and changerequests change between labels.

I see in the new SDK, there is only .dll files.

I do not understand how you want me to use thease.

I have found software that can generate TLB from .dll files, like RegAsm but cannot get them to work.

We do not want to rewrite this whole application to c#, want a simple solution how to work with this SDK in C++ enviroment.

Also some API examples would be nice, when it is up and runnning.

Thanks for help!

0 Likes
Reply
1 Solution

Accepted Solutions
Micro Focus Expert
Micro Focus Expert

RE: Upgrading a large step from SDK 2005 R2 to SDK 14.0, C++

Jump to solution

Hi Jens,

>> or is it that the sdk i am using is 32bit and i have a 64bit system maybe?

This is a possibility.

Have you tried doing a clean install of the SDK on a 32 bit machine, and running your code?

>>have the SDK changed so i am using it wrong

I cannot answer the second part of this question.

To the first - yes, the SDK has changed dramatically from 2005 to 16.0 (which ships to supportline tomorrow).

For instance, the COM .dll uses the latest version of the 1.8 JRE & the Windows 2008 runtime to launch an SDK 'bridge' .jar which in turn launches the real SDK .jar, which provides the true implementation.

In the interim, here are a few suggestions.

Please download and install st- sdk- 15- 0- 1- 68- java- win32.exe on a clean 32 bit machine.

This is the most stable version of our SDK available to our customer base.

please ensure that no previous version of starteam exists on this machine.

extract the typelib and install your program.

please see if the problem persists.

if it does, open up a support case through MicroFocus Customer Support.

Provide them with your database and C++ scripts which reliably reproduce the problem.

I shall be glad to investigate.

take care

anil

0 Likes
Reply
14 Replies
vdlight Absent Member.
Absent Member.

RE: Upgrading a large step from SDK 2005 R2 to SDK 14.0, C++

Jump to solution

one more thing i forgot. We are using windows 7, 64bit.

I noticed at the sdk file,

st-sdk-14.0.4.19-runtime-java-win32.exe

is this win64 compatible ?

0 Likes
Reply
Micro Focus Expert
Micro Focus Expert

RE: Upgrading a large step from SDK 2005 R2 to SDK 14.0, C++

Jump to solution

Hullo,

>>we updated our starteam server

When did you do this upgrade, please? I ask because...

>>sdk 14.0.4.19

This build of the SDK is from March 2015. The most recent supported, patch release builds,

(Sep 2016) from MicroFocus supportline are .CPC 14.0.4.181, SDK 14.0.4.122.

>>st-sdk-14.0.4.19-runtime-java-win32.exe

Yes. It will install under c:/program files (x86)/borland/starteam sdk 14.0

however, you should be installing 14.0.4.122 from supportline.

>>using SDK 2005 started to crash.

>>I see in the new SDK, there is only .dll files.

I do apologize, but StarTeam 2005 is 11 year old technology.

The win32.exe does install StarTeam.dll which is a 32 bit COM .dll.

This COM .dll can continue to be used from 32 bit applications which support COM.

I believe that you will be able to generate a .tlb from StarTeam.dll after registering it on your machine.

We do not have a .64 bit COM .dll.

We do, however, have full 64 bit SDK & CPC, and support 64 bit Java & C# customizations.

(which, unlike 32 bits, gives you the benefit of the full addressable memory space of a 64 bit platform)

Some additional notes of interest.

We introduced a new com.starteam namespace for Java, a StarTeam namespace for C#.

the COM.dll continues to work on top of the old, deprecated com.starbase namespace, but only supports the bare minimum functionality available through that old namespace, and is retained for backward compatibility.

Any new functionality of interest can only be exercised through the new namespace, which requires either Java or C# development.

Since you have made such a huge leap - from 2005 to 14.4 - you will discover that file checkins now create ChangePackages, not old style links.

This will affect the semantics of your old applications.

To revert back to behavior that your old applications expect, you may want to turn off Change Packages.

You do this by setting CheckinChangePackages = 0 in your server config .xml file

I hope this all helps, please feel free to open support cases for additional guidance.

Take care

anil

0 Likes
Reply
vdlight Absent Member.
Absent Member.

RE: Upgrading a large step from SDK 2005 R2 to SDK 14.0, C++

Jump to solution

Hello and thanks for answer!

the update on our server was done last week, CW 42 and yes!, we are really slow with this kind of updates i am sad to say, 😞

understand that support for so old softwares is not easy.

i also have read some in this forum, and also realize that SDK 15 is backwards compatible and should have COM support. So i am currently downloading 15.0.1.68.

it will be a huge step, if i get this to work, from 2005 until now.

I will report back with status.

0 Likes
Reply
Micro Focus Expert
Micro Focus Expert

RE: Upgrading a large step from SDK 2005 R2 to SDK 14.0, C++

Jump to solution

excellent, you are better off going with 15.0.1.68, which is the 'latest' release SDK & CPC platform.

note that everything i have said regarding 32 v/s 64 bit support is still the same.

since your upgrade is a week old, please set CheckinChangePackages = 0

in your server config xml file

you will not run into any unpleasant surprises that way.

take care

anil

0 Likes
Reply
Highlighted
Micro Focus Expert
Micro Focus Expert

RE: Upgrading a large step from SDK 2005 R2 to SDK 14.0, C++

Jump to solution

Hi Vdlight

Can you open a support case and we will be happy to assist and advise

0 Likes
Reply
vdlight Absent Member.
Absent Member.

RE: Upgrading a large step from SDK 2005 R2 to SDK 14.0, C++

Jump to solution

I have opened an issue regarding this to keep track, thanks.

Status so far, is that i have installed "st-sdk-15.0.1.68-runtime-net-win32"

Tried with regasm to generate a new TLB file,

but it seems not to work ok, no error messages, but output tlb file is only 1172 bytes.

And it is generated from StarTeam.dll, that is 1 966 080 bytes ?

so this tlb is not usable at all for me in our Embarcardero XE, C++ project

0 Likes
Reply
Micro Focus Expert
Micro Focus Expert

RE: Upgrading a large step from SDK 2005 R2 to SDK 14.0, C++

Jump to solution

>>Tried with regasm to generate a new TLB file,

>>but it seems not to work ok, no error messages, but output tlb file is only 1172 bytes.

>>And it is generated from StarTeam.dll, that is 1 966 080 bytes ?

You need the OLE-COM Object Viewer, available as part of whatever is the latest Windows SDK. Then you can go to File->View Type Lib and save the IDL to a text file. Then you can use MIDL (also part of the Windows SDK) to regenerate a TLB and header file. Something like this should do for basic cases:

midl /out c:\temp /header MyHeader.h MyIDLFile.idl

(i also provided support with the .idl & the . h files, which they have passed on to you)

regasm.exe produces type libraries from managed .NET .dll's (to support COM interop)

StarTeam.dll is an unmanaged COM .dll

i hope this helps

take care

anil

0 Likes
Reply
vdlight Absent Member.
Absent Member.

RE: Upgrading a large step from SDK 2005 R2 to SDK 14.0, C++

Jump to solution

i got the .idl files, thanks!

Why do i need Object viewer to save to a text file ? why not run MIDL against your .idl directly

i tried running midl aginst the StarTeamSDK.idl.

Get following error, MIDL2379, size limit.

I use Developer Command prompt for VS2012

seems like in need to split the idl somehow

0 Likes
Reply
Micro Focus Expert
Micro Focus Expert

RE: Upgrading a large step from SDK 2005 R2 to SDK 14.0, C++

Jump to solution

we use the VS2005 development environment, IDL Compiler & Linker to produce the COM .dll

0 Likes
Reply
vdlight Absent Member.
Absent Member.

RE: Upgrading a large step from SDK 2005 R2 to SDK 14.0, C++

Jump to solution

now i did a test, why i need TLB when i got .c and .h files.

So i just added those to my project and, it compiles, so far so good.

Now i am trying functionality and it breaks directly.

I cannot create a server factory.

IStServerFactory* pServerFactory = NULL;

_pServer = NULL;

// Instantiate a serverfactory object   //

hr = CoCreateInstance(CLSID_StServerFactory, NULL, CLSCTX_SERVER,

IID_IStServerFactory, (void**)&pServerFactory);

this fails, am i missing something.

0 Likes
Reply
Micro Focus Expert
Micro Focus Expert

RE: Upgrading a large step from SDK 2005 R2 to SDK 14.0, C++

Jump to solution

>>this fails, am i missing something.

that's hard to tell, unless you know how it fails, what error code you get back, what the matching error message is when looking up that error code on google or microsoft msdn, etc...

in general, you need to have the 32 bit java JRE installed on your machine, the SDK installed in the correct folder, and the COM .dll registered using regsvr32.dll

once you have that, i'd suggest opening up an old version of visual basic, loading a reference to the .dll, and test that it works with a few lines of vb code.

i.e. create an sdk server object, connect to the starteam server and login.

if that works, then you know that the same code should work when loaded through any COM compliant container, including VB, C++, SCCI, PowerBuilder, Windows Scripting Host, etc...

I hope this helps

take care

anil

0 Likes
Reply
vdlight Absent Member.
Absent Member.

RE: Upgrading a large step from SDK 2005 R2 to SDK 14.0, C++

Jump to solution

I have had some progress.

First i removed old sdk versions from system and got clean start.

I downloaded, st- sdk- 14- 0- 4- 122- java- win32.exe

This installed fine, and i found the StarTeamSDK140.dll file, in the lib folder. This seems to work , it was able to generate a type library to use in my project.

So now i can, login to starteam server (that is now also updated to version 15). I can read views, i can read projects, i can read change requests.

But, it is unstable.

It crashes from time to time. For instance, sometimes when i uses fetchAllLabels on a view.

It does not crash every time, just from time to time. Realy annoyng.

It also crash when i am using an item, and i am trying to get itemhistory.

Code:

item- >get_ History(&itemHistoryCollection);

hr = ItemHistoryCollection- > get_ _ NewEnum(&itemHistoryDispatch);

Then it crashes with an access vioalation on an address.

Exception class C000000005

This is a major problem, because this happens almost every time.

I have no clue why theese crashes occur?

have the SDK changed so i am using it wrong, or is it that the sdk i am using is 32bit and i have a 64bit system maybe?

0 Likes
Reply
Micro Focus Expert
Micro Focus Expert

RE: Upgrading a large step from SDK 2005 R2 to SDK 14.0, C++

Jump to solution

Hi Jens,

>> or is it that the sdk i am using is 32bit and i have a 64bit system maybe?

This is a possibility.

Have you tried doing a clean install of the SDK on a 32 bit machine, and running your code?

>>have the SDK changed so i am using it wrong

I cannot answer the second part of this question.

To the first - yes, the SDK has changed dramatically from 2005 to 16.0 (which ships to supportline tomorrow).

For instance, the COM .dll uses the latest version of the 1.8 JRE & the Windows 2008 runtime to launch an SDK 'bridge' .jar which in turn launches the real SDK .jar, which provides the true implementation.

In the interim, here are a few suggestions.

Please download and install st- sdk- 15- 0- 1- 68- java- win32.exe on a clean 32 bit machine.

This is the most stable version of our SDK available to our customer base.

please ensure that no previous version of starteam exists on this machine.

extract the typelib and install your program.

please see if the problem persists.

if it does, open up a support case through MicroFocus Customer Support.

Provide them with your database and C++ scripts which reliably reproduce the problem.

I shall be glad to investigate.

take care

anil

0 Likes
Reply
vdlight Absent Member.
Absent Member.

RE: Upgrading a large step from SDK 2005 R2 to SDK 14.0, C++

Jump to solution

Hi

I just want to inform some good news.

I, again for the third or forth time, uninstalled all sdk. I rebootet windows inbetween and all to get a so clean enviroment as i can. Then i reinstalled 15-0-1-68 win32 version.

And it worked!!

It now runs perfectly, not any trace of crashes, i am stunned.

But happy!

Thanks for all the assistance.

0 Likes
Reply
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.