You can also use:

  getEntityManager().createEntity(BasicEntitySpec.newInstance(RubyRepNode.class)
      .configure(flags)
      .configure(RubyRepNode.LEFT_DATABASE_URL, DependentConfiguration.attributeWhenReady(left, DatabaseNode.DB_URL))
      .configure(RubyRepNode.RIGHT_DATABASE_URL, DependentConfiguration.attributeWhenReady(right, DatabaseNode.DB_URL)))