Subversion Repositories DevTools

Rev

Rev 900 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 900 Rev 908
Line 30... Line 30...
30
  /**root cause
30
  /**root cause
31
   * @attribute
31
   * @attribute
32
   */
32
   */
33
  private String mRootCause;
33
  private String mRootCause;
34
 
34
 
-
 
35
  /**test build instruction
-
 
36
   * @attribute
-
 
37
   */
-
 
38
  private int mTestBuildInstruction;
-
 
39
 
35
  /**in terms of the mChangeType Package field,
40
  /**in terms of the mChangeType Package field,
36
   * when true indicates the package has not changed, its dependencies potentially have
41
   * when true indicates the package has not changed, its dependencies potentially have
37
   * in terms of the mRippleField Package field,
42
   * in terms of the mRippleField Package field,
38
   * when true indicates the build number will be incremented
43
   * when true indicates the build number will be incremented
39
   * @attribute
44
   * @attribute
40
   */
45
   */
41
  private boolean mProcessed = false;
46
  private boolean mProcessed = false;
42
 
47
 
43
  /**constructor
48
  /**constructor
44
   */
49
   */
45
  public BuildExclusion(int identifier, int rootIdentifier, String rootCause)
50
  public BuildExclusion(int identifier, int rootIdentifier, String rootCause, int testBuildInstruction )
46
  {
51
  {
47
    mLogger.debug("BuildExclusion");
52
    mLogger.debug("BuildExclusion");
48
    mId = identifier;
53
    mId = identifier;
49
    mRootId = dealWithNullRootPvId(identifier, rootIdentifier);
54
    mRootId = dealWithNullRootPvId(identifier, rootIdentifier);
50
    mRootCause = rootCause;
55
    mRootCause = rootCause;
-
 
56
    mTestBuildInstruction = testBuildInstruction;
51
  }
57
  }
52
 
58
 
53
  /**sets mProcessed true
59
  /**sets mProcessed true
54
   */
60
   */
55
  void process()
61
  void process()
Line 120... Line 126...
120
    Integer r = rtag_id;
126
    Integer r = rtag_id;
121
    // a null version and log file is passed to oracle
127
    // a null version and log file is passed to oracle
122
    // the planned version is only needed to remove a planned version from the planned version table
128
    // the planned version is only needed to remove a planned version from the planned version table
123
    // the ripple engine does not get this far ie it excludes pvs before claiming a version
129
    // the ripple engine does not get this far ie it excludes pvs before claiming a version
124
    // this is the one instance where an existing build failure must be superceded in the database
130
    // this is the one instance where an existing build failure must be superceded in the database
125
    rm.excludeFromBuild(id.toString(), null, r.toString(), rootId == -1 ? null : rootId.toString(), mRootCause, null, false, true);
131
    rm.excludeFromBuild(id.toString(), null, r.toString(), rootId == -1 ? null : rootId.toString(), mRootCause, null, true, mTestBuildInstruction);
126
  }
132
  }
127
  
133
  
128
  /**runs exclude from build
134
  /**runs exclude from build
129
   */
135
   */
130
  void includeToBuild( ReleaseManager rm, int rtag_id ) throws SQLException, Exception
136
  void includeToBuild( ReleaseManager rm, int rtag_id ) throws SQLException, Exception
Line 207... Line 213...
207
    * does not trigger a storm of emails because a low level package has a build issue
213
    * does not trigger a storm of emails because a low level package has a build issue
208
    * limit the emails to the low level package
214
    * limit the emails to the low level package
209
    * i.e. only send email if the build exclusion has a null root pv id
215
    * i.e. only send email if the build exclusion has a null root pv id
210
    * and a non null root cause
216
    * and a non null root cause
211
   */
217
   */
212
    public void email(Vector<Package>packageCollection, String mailServer, String mailSender, String release)
218
    public void email(Vector<Package>packageCollection, String mailServer, String mailSender, String release, ReleaseManager releaseManager) throws SQLException, Exception
213
    {
219
    {
214
      mLogger.debug("email " + mId);
220
      mLogger.debug("email " + mId);
215
      if ( mRootId == -1 && mRootCause != null )
221
      if ( mRootId == -1 && mRootCause != null )
216
      {
222
      {
217
        // this is a direct build failure with a ripple engine induced root cause
223
        // this is a direct build failure with a ripple engine induced root cause
Line 256... Line 262...
256
            }
262
            }
257
            catch( Exception e )
263
            catch( Exception e )
258
            {
264
            {
259
            }
265
            }
260
          }
266
          }
-
 
267
          
-
 
268
          // having sent the build failure email, complete a test build if applicable
-
 
269
          // this ensures the test build instruction is not processed indefinitely
-
 
270
          // as there is no notion of excluding test builds
-
 
271
          pkg.completeTestBuild(mailServer, mailSender, releaseManager, release, false);
261
        }
272
        }
262
      }
273
      }
263
    }
274
    }
264
    
275
    
265
    /**
276
    /**