code: @Activated
  	public void configure() {
  		String persistenceUnit = configuration.get("persistenceUnit");
  		
  		if (persistenceUnit == null) {
  			PersistenceXMLProcessor processor = new PersistenceXMLProcessor();
  			processor.process();
  			List<String> persistenceUnits = processor.persistenceUnits();
  			
  			if (persistenceUnits.isEmpty()) {
  				logger.error("Cannot access to the database service in this application; " +
  						"No 'persistence-unit' is specified in 'persistence.xml'");
  				return;
  			}
  			
  			persistenceUnit = persistenceUnits.get(0);
  		}
  		
  		factory = Persistence.createEntityManagerFactory(persistenceUnit);
  	}
docs: Configures the persistence units to be connected and makes the
  {@code EntityManagerFactory} instance corresponding to the persistence
  unit the current application connects to.
  If the persistence unit is specified in the configuration with the
  'persistenceUnit' key, this class uses it to establish the connection.
  Otherwise, this class uses the first-detected persistence unit (Index 0
  of the persistence unit list in the 'persistence.xml'.
  
  <b>Note: </b>In the future, the implementation will be improved for
  multitenant applications. The persistence unit set on the current thread
  via something like "Namespaces API" will be used for the
  {@code EntityManagerFactory} creation.