Use factory for node creation.