in my each jsp page i have to write this code to connect with Mysql database
Class.forName("com.mysql.jdbc.Driver").newInstance();
String url ="jdbc:mysql://35.212.176.25/tri";
Connection con = DriverManager.getConnection(url,"root", "");
now i want to make this code in a separate jsp page and then only include this page in my current jsp page where ever necessary to connect with my Database like in PHP. Is it possible in Jsp . If yes pls tell me