| Line 177... |
Line 177... |
| 177 |
|
177 |
|
| 178 |
mLogger.fatal("run calling deliverChange on AbtPublish");
|
178 |
mLogger.fatal("run calling deliverChange on AbtPublish");
|
| 179 |
deliverChange(null, "AbtPublish", false);
|
179 |
deliverChange(null, "AbtPublish", false);
|
| 180 |
// preserve
|
180 |
// preserve
|
| 181 |
String reportingFullyPublished = mReportingFullyPublished;
|
181 |
String reportingFullyPublished = mReportingFullyPublished;
|
| 182 |
String reportingNewLabel = mReportingNewLabel;
|
182 |
String reportingNewVcsTag = mReportingNewVcsTag;
|
| 183 |
mLogger.fatal("run calling deliverChange on AbtTearDown");
|
183 |
mLogger.fatal("run calling deliverChange on AbtTearDown");
|
| 184 |
deliverChange(null, "AbtTearDown", false);
|
184 |
deliverChange(null, "AbtTearDown", false);
|
| 185 |
|
185 |
|
| 186 |
// DEVI 47395 delete the build file now
|
186 |
// DEVI 47395 delete the build file now
|
| 187 |
// this will prevent any chance of multiply publishing a package version
|
187 |
// this will prevent any chance of multiply publishing a package version
|
| Line 229... |
Line 229... |
| 229 |
|
229 |
|
| 230 |
if ( reportingFullyPublished != null && reportingFullyPublished.compareTo("yes") == 0 )
|
230 |
if ( reportingFullyPublished != null && reportingFullyPublished.compareTo("yes") == 0 )
|
| 231 |
{
|
231 |
{
|
| 232 |
buildErrorOccurred = false;
|
232 |
buildErrorOccurred = false;
|
| 233 |
|
233 |
|
| 234 |
if ( reportingNewLabel.length() > 0 )
|
234 |
if ( reportingNewVcsTag.length() > 0 )
|
| 235 |
{
|
235 |
{
|
| 236 |
Integer rtagId = new Integer(mRtagId);
|
236 |
Integer rtagId = new Integer(mRtagId);
|
| 237 |
|
237 |
|
| 238 |
if ( mGbeGatherMetricsOnly == null )
|
238 |
if ( mGbeGatherMetricsOnly == null )
|
| 239 |
{
|
239 |
{
|
| 240 |
// publish to release manager
|
240 |
// publish to release manager
|
| 241 |
mLogger.fatal("run calling mReleaseManager.autoMakeRelease");
|
241 |
mLogger.fatal("run calling mReleaseManager.autoMakeRelease");
|
| 242 |
mReleaseManager.autoMakeRelease(rtagId.toString(), mReportingPackageName, mReportingPackageExtension, mReportingPackageVersion, reportingNewLabel, mReportingPackageDepends, mReportingIsRipple);
|
242 |
mReleaseManager.autoMakeRelease(rtagId.toString(),
|
| - |
|
243 |
mReportingPackageName,
|
| - |
|
244 |
mReportingPackageExtension,
|
| - |
|
245 |
mReportingPackageVersion,
|
| - |
|
246 |
reportingNewVcsTag,
|
| - |
|
247 |
mReportingPackageDepends,
|
| - |
|
248 |
mReportingIsRipple);
|
| 243 |
}
|
249 |
}
|
| 244 |
|
250 |
|
| 245 |
FileInputStream abtmetrics = new FileInputStream( rtagId.toString() + "abtmetrics.txt" );
|
251 |
FileInputStream abtmetrics = new FileInputStream( rtagId.toString() + "abtmetrics.txt" );
|
| 246 |
DataInputStream din = new DataInputStream( abtmetrics );
|
252 |
DataInputStream din = new DataInputStream( abtmetrics );
|
| 247 |
InputStreamReader isr = new InputStreamReader( din );
|
253 |
InputStreamReader isr = new InputStreamReader( din );
|
| Line 255... |
Line 261... |
| 255 |
mLogger.fatal("run calling mReleaseManager.insertPackageMetrics");
|
261 |
mLogger.fatal("run calling mReleaseManager.insertPackageMetrics");
|
| 256 |
mReleaseManager.insertPackageMetrics(rtagId.toString(), mReportingPackageName, mReportingPackageExtension, metrics );
|
262 |
mReleaseManager.insertPackageMetrics(rtagId.toString(), mReportingPackageName, mReportingPackageExtension, metrics );
|
| 257 |
}
|
263 |
}
|
| 258 |
else
|
264 |
else
|
| 259 |
{
|
265 |
{
|
| 260 |
mLogger.info("run package not labelled in ClearCase on " + mReportingPackageName + mReportingPackageVersion);
|
266 |
mLogger.info("run package not labelled in Version Control on " + mReportingPackageName + mReportingPackageVersion);
|
| 261 |
// max 50 characters
|
267 |
// max 50 characters
|
| 262 |
rootCause = "Error publishing to ClearCase";
|
268 |
rootCause = "Error publishing to Version Control System";
|
| 263 |
throw new Exception();
|
269 |
throw new Exception();
|
| 264 |
}
|
270 |
}
|
| 265 |
}
|
271 |
}
|
| 266 |
else
|
272 |
else
|
| 267 |
{
|
273 |
{
|
| Line 271... |
Line 277... |
| 271 |
|
277 |
|
| 272 |
}
|
278 |
}
|
| 273 |
catch( Exception e)
|
279 |
catch( Exception e)
|
| 274 |
{
|
280 |
{
|
| 275 |
// a build error occurred or
|
281 |
// a build error occurred or
|
| 276 |
// an error occurred publishing to ClearCase or Release Manager
|
282 |
// an error occurred publishing to Version Control or Release Manager
|
| 277 |
// take out the archive entry first
|
283 |
// take out the archive entry first
|
| 278 |
String fs = System.getProperty( "file.separator" );
|
284 |
String fs = System.getProperty( "file.separator" );
|
| 279 |
String dpkgArchiveEntry = new String(Package.mGbeDpkg + fs + mReportingPackageName + fs + mReportingPackageVersion);
|
285 |
String dpkgArchiveEntry = new String(Package.mGbeDpkg + fs + mReportingPackageName + fs + mReportingPackageVersion);
|
| 280 |
File dpkgArchiveEntryFile = new File(dpkgArchiveEntry);
|
286 |
File dpkgArchiveEntryFile = new File(dpkgArchiveEntry);
|
| 281 |
mLogger.info("run checking existence of " + dpkgArchiveEntry);
|
287 |
mLogger.info("run checking existence of " + dpkgArchiveEntry);
|
| Line 287... |
Line 293... |
| 287 |
mLogger.warn("run deleting " + dpkgArchiveEntryFile.getName());
|
293 |
mLogger.warn("run deleting " + dpkgArchiveEntryFile.getName());
|
| 288 |
mLogger.fatal("run calling deleteDirectory on " + dpkgArchiveEntryFile);
|
294 |
mLogger.fatal("run calling deleteDirectory on " + dpkgArchiveEntryFile);
|
| 289 |
deleteDirectory(dpkgArchiveEntryFile);
|
295 |
deleteDirectory(dpkgArchiveEntryFile);
|
| 290 |
}
|
296 |
}
|
| 291 |
}
|
297 |
}
|
| 292 |
else
|
- |
|
| 293 |
{
|
- |
|
| 294 |
String dplyArchiveEntry = new String(Package.mGbeDply + fs + mReportingPackageName + fs + mReportingPackageVersion);
|
- |
|
| 295 |
File dplyArchiveEntryFile = new File(dplyArchiveEntry);
|
- |
|
| 296 |
mLogger.info("run checking existence of " + dplyArchiveEntry);
|
- |
|
| 297 |
|
- |
|
| 298 |
if ( dplyArchiveEntryFile.exists() )
|
- |
|
| 299 |
{
|
- |
|
| 300 |
if ( dplyArchiveEntryFile.isDirectory() )
|
- |
|
| 301 |
{
|
- |
|
| 302 |
mLogger.warn("run deleting " + dplyArchiveEntryFile.getName());
|
- |
|
| 303 |
mLogger.fatal("run calling deleteDirectory on " + dplyArchiveEntryFile);
|
- |
|
| 304 |
deleteDirectory(dplyArchiveEntryFile);
|
- |
|
| 305 |
}
|
298 |
|
| 306 |
}
|
- |
|
| 307 |
}
|
- |
|
| 308 |
|
- |
|
| 309 |
Integer rtagId = new Integer(mRtagId);
|
299 |
Integer rtagId = new Integer(mRtagId);
|
| 310 |
|
300 |
|
| 311 |
if ( !buildErrorOccurred )
|
301 |
if ( !buildErrorOccurred )
|
| 312 |
{
|
302 |
{
|
| 313 |
mLogger.fatal("an error occurred publishing to ClearCase or Release Manager");
|
303 |
mLogger.fatal("an error occurred publishing to Version Control or Release Manager");
|
| 314 |
// force exclusion by default
|
304 |
// force exclusion by default
|
| 315 |
int testBuildInstruction = 0;
|
305 |
int testBuildInstruction = 0;
|
| 316 |
try
|
306 |
try
|
| 317 |
{
|
307 |
{
|
| 318 |
testBuildInstruction = Integer.parseInt( mReportingTestBuild );
|
308 |
testBuildInstruction = Integer.parseInt( mReportingTestBuild );
|
| Line 320... |
Line 310... |
| 320 |
catch( NumberFormatException nfe )
|
310 |
catch( NumberFormatException nfe )
|
| 321 |
{
|
311 |
{
|
| 322 |
}
|
312 |
}
|
| 323 |
mLogger.fatal("run calling excludeFromBuild");
|
313 |
mLogger.fatal("run calling excludeFromBuild");
|
| 324 |
mReleaseManager.excludeFromBuild(mReportingPackageVersionId, null, rtagId.toString(), null, rootCause, null, false, testBuildInstruction);
|
314 |
mReleaseManager.excludeFromBuild(mReportingPackageVersionId, null, rtagId.toString(), null, rootCause, null, false, testBuildInstruction);
|
| 325 |
throw new Exception("an error occurred publishing to ClearCase or Release Manager");
|
315 |
throw new Exception("an error occurred publishing to Version Control or Release Manager");
|
| 326 |
}
|
316 |
}
|
| 327 |
|
317 |
|
| 328 |
// DEVI 55364
|
318 |
// DEVI 55364
|
| 329 |
// Package has not been built on all configured platforms
|
319 |
// Package has not been built on all configured platforms
|
| 330 |
// Under normal circumstances, this root cause will be masked by a previously reported error
|
320 |
// Under normal circumstances, this root cause will be masked by a previously reported error
|
| Line 366... |
Line 356... |
| 366 |
throw new ExitException();
|
356 |
throw new ExitException();
|
| 367 |
}
|
357 |
}
|
| 368 |
|
358 |
|
| 369 |
// generate build files
|
359 |
// generate build files
|
| 370 |
mLogger.warn("run generating build files");
|
360 |
mLogger.warn("run generating build files");
|
| 371 |
mLogger.fatal("run calling planRelease");
|
361 |
mLogger.fatal("run calling planRelease");
|
| 372 |
rippleEngine.planRelease();
|
362 |
rippleEngine.planRelease();
|
| 373 |
mLogger.fatal("run calling reportChange");
|
363 |
mLogger.fatal("run calling reportChange");
|
| 374 |
rippleEngine.reportChange();
|
364 |
rippleEngine.reportChange();
|
| 375 |
|
365 |
|
| 376 |
// get the build file from the ripple engine
|
366 |
// get the build file from the ripple engine
|
| 377 |
rippleEngine.getFirstBuildFileContent(buildFileContent, addendum);
|
367 |
rippleEngine.getFirstBuildFileContent(buildFileContent, addendum);
|
| 378 |
|
368 |
|
| 379 |
if ( addendum.value.compareTo("non generic") == 0 )
|
369 |
if ( addendum.value.compareTo("non generic") == 0 )
|
| 380 |
{
|
370 |
{
|
| Line 391... |
Line 381... |
| 391 |
mLogger.fatal("run calling publishBuildFile on dummy");
|
381 |
mLogger.fatal("run calling publishBuildFile on dummy");
|
| 392 |
mReleaseManager.publishBuildFile(mRtagId, mDummyBuildFileContent);
|
382 |
mReleaseManager.publishBuildFile(mRtagId, mDummyBuildFileContent);
|
| 393 |
}
|
383 |
}
|
| 394 |
}
|
384 |
}
|
| 395 |
mLogger.info("run generated build files");
|
385 |
mLogger.info("run generated build files");
|
| - |
|
386 |
// Start of a build cycle. Set new log file to capture entire build log
|
| - |
|
387 |
flagStartBuildCycle();
|
| - |
|
388 |
|
| 396 |
|
389 |
|
| 397 |
if ( mGbeGatherMetricsOnly != null )
|
390 |
if ( mGbeGatherMetricsOnly != null )
|
| 398 |
{
|
391 |
{
|
| 399 |
// set view up early for metrics gathering to ensure build file is fully written before letting the slave loose
|
392 |
// set view up early for metrics gathering to ensure build file is fully written before letting the slave loose
|
| 400 |
mLogger.fatal("run calling setViewUp");
|
393 |
mLogger.fatal("run calling setViewUp");
|