-
Bug
-
Resolution: Fixed
-
Major
-
None
-
Platform: All, OS: Linux
When gathering changes using lshistory, the build fails if the specified stream
does not exist. This happens if the stream is new and no changes has been made.
What is worse, however, is that it also requires that changes has been made in
that particular stream for all vobs listed in the load rules. In our setup we
use a specific vob for external dependencies such as boost or some other third
party library. Changes to this vob are not very frequent, so it typically does
not contain tags for all streams using it.
Patching UcmChangeLogAction.getChanges as follows solves the issue for me. This
version will return ok successful in at least one view path (perhaps it always
should return ok, so that it works for newly created streams?). Note, the patch
also contain code for my reported issue 3096.
@Override
public List<UcmActivity> getChanges(Date time, String viewName, String[]
branchNames, String[] viewPaths) th
rows IOException, InterruptedException {
// TH: Patched since this command must allow paths that do not contain
// the specified branch name (happens, for instance, if changes has
// been made only in one of several vobs
List<UcmActivity> history = new ArrayList<UcmActivity>();
boolean ok = false;
IOException exception = null;
for(String path : viewPaths) {
try {
// TH: Added the view name as part of the path (as the current
directory
// is the workspace root and the view will be checked out in a
// directory with the name of the view)
String fullpath = viewName + File.separator + path;
BufferedReader reader = new BufferedReader(
cleartool.lshistory(historyHandler.getFormat() + COMMENT
+ LINEEND, time, viewName, bran
chNames[0],
new String[]
));
history.addAll(parseHistory(reader,viewName));
reader.close();
ok = true; // At least one path was successful
} catch(IOException e)
}
if(ok || exception == null)
else
{ // No path was successful, throwing the last one throw exception; }}
- is duplicated by
-
JENKINS-3096 Build failure on ucm/linux due to failing lshistory
- Closed