It's all about the answers!

Ask a question

Do we have a command line to Lock/unlock the stream in RTC 6.0.2?

shibi krishnamoorthy (111) | asked Nov 21 '16, 5:28 a.m.
retagged Oct 06 '17, 4:07 p.m. by Ken Tessier (84117)

Need to lock stream at the start of build and unlock at end of build.

is there is any ANT task/RTC command line to lock/unlock streams.

It would be good if we have an option in the build definition to lock the stream while starting the build.(similar to accept changes in repo before build) I understand that build definition never consider the stream and also has impact on personal build. Guess we can handle this in build definition.(just a suggestion)

Accepted answer

permanent link
David Lafreniere (4.1k7) | answered Oct 05 '17, 5:47 p.m.
edited Oct 05 '17, 5:47 p.m.

There is no Ant Task available to lock a stream, however there is an SCM CLI (Command Line Interface) command to lock a stream/component (added in RTC 6.0.2). See the 'scm set lock' command.

-SCM Command Line Client 'set lock' command:
-New & Noteworthy Mention of Stream/Component Locking:
-Stream/Component Locking Demo Video:

Michael Valenta selected this answer as the correct answer

One other answer

permanent link
Lily Wang (4.9k714) | answered Nov 21 '16, 6:25 p.m.
In RTC the lock is created on file level. If you need to lock an entire stream to prevent users to deliver the change set the the stream, you need to use "Restrict Change Set Delivery to Components in a Stream" pre-condition. However it's not possible to set the pre-condition using SCM command line or Ant task.
I doubt why you need to lock a stream during a build? The build is happened on build workspace, and stream is easy to roll back to the build status using the snapshot created on build workspace.

Ralph Schoon commented Nov 22 '16, 1:56 a.m. | edited Nov 22 '16, 1:56 a.m.

 Apparently in 6.0.2 locking on stream and component level was added.

I was however not able to find a reference to do that with the scm command line. I assume you would have to play with the API if you wanted to  automate it.

Stephane Couillaud commented Sep 12 '17, 2:32 p.m.

 Hi Ralph,

Do you know if there has been any advances since?


Your answer

Register or to post your answer.