HelperContext hc = HelperProvider.getDefaultContext();
CustomerFactory factory = CustomerFactory.INSTANCE;
factory.register(hc);
Customer customer = factory.createCustomer();
Account account = factory.createAccount();
customer.setAccount(account);
DataObject customerDO = (DataObject) customer;
DataGraph dg = SDOUtil.createDataGraph();
SDOUtil.setRootObject(dg, customerDO);
dg.getChangeSummary().beginLogging();