jsp页面中的java代码为什么会执行两次?

请问jsp页面中的java代码为什么会执行两次,需要怎么修改?
之前几次运行出现过多次运行的结果全都只在一行出现,后来又好了(好像也没改什么)

img


<%@ page language="java" import="java.util.*" pageEncoding="ISO-8859-1"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<title>My JSP 'index.jsp' starting pagetitle>
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">    
<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
<meta http-equiv="description" content="This is my page">

This is my JSP page.
<% System.out.print(" Console Data Console Data"); System.out.print(" 1Console Data"); System.out.print(" 2Console Data"); %>

idea运行时会执行一次,tomcat执行时也会运行一次,所以有2次