// add a new reference code to the model: this should also trigger a reindex of the ProductShootingBrief
// due to the @ContainedIn dependency graph
session = Search.getFullTextSession( openSession() );
tx = session.beginTransaction();
model.getAdditionalReferenceCodes().add( new ProductReferenceCode( model, "NEWREF" ) );
session.update( model );
tx.commit();
session.close();
// check that the ProductShootingBrief has been reindexed correctly.
session = Search.getFullTextSession( openSession() );