package fr.epsi.i4.bookmark;

import java.net.URI;
import java.util.Objects;

import org.glassfish.jersey.server.ApplicationHandler;
import org.glassfish.jersey.simple.SimpleContainerFactory;

import fr.epsi.i4.bookmark.web.BookmarkApplication;

public class Main {

	public static void main(String[] args) throws Exception {
		String port = Objects.toString(System.getenv("PORT"), "8080");
	    SimpleContainerFactory.create(new URI("http://localhost:" + port), new ApplicationHandler(new BookmarkApplication()));
	}

}

@@ -69,16 +69,81 @@
 Objects;
+%0Aimport java.util.logging.Level;%0Aimport java.util.logging.Logger;
 %0A%0Aimport
@@ -449,16 +449,106 @@
 8080%22);%0A
+%09%09Logger.getLogger(%22bookmarks%22).log(Level.INFO, %22Starting web services on port %22 + port);%0A
 %09    Sim
@@ -594,17 +594,36 @@
 p://
-localhost
+rest-bookmarks.herokuapp.com
 :%22 +

add log on startup