Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <%@taglib prefix="sql" uri="http://java.sun.com/jsp/jstl/sql"%>
- <%--
- Document : my_jsp
- Created on : 12.10.2017, 0:08:05
- Author : Denys
- --%>
- <%@page contentType="text/html" pageEncoding="UTF-8"%>
- <!DOCTYPE html>
- <html>
- <head>
- <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
- <title>JSP Page</title>
- </head>
- <body>
- <sql:query var="names" dataSource="jdbc/IFPWAFCAD">
- SELECT * FROM my_table_2
- </sql:query>
- </body>
- </html>
- <?xml version="1.0" encoding="UTF-8"?>
- <web-app version="3.1" xmlns="http://xmlns.jcp.org/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd">
- <session-config>
- <session-timeout>
- 30
- </session-timeout>
- </session-config>
- <welcome-file-list>
- <welcome-file>my_jsp.jsp</welcome-file>
- </welcome-file-list>
- <resource-ref>
- <res-ref-name>jdbc/IFPWAFCAD</res-ref-name>
- <res-type>javax.sql.ConnectionPoolDataSource</res-type>
- <res-auth>Container</res-auth>
- <res-sharing-scope>Shareable</res-sharing-scope>
- </resource-ref>
- </web-app>
- <?xml version="1.0" encoding="UTF-8"?>
- <!DOCTYPE resources PUBLIC "-//GlassFish.org//DTD GlassFish Application Server 3.1 Resource Definitions//EN" "http://glassfish.org/dtds/glassfish-resources_1_5.dtd">
- <resources>
- <jdbc-resource enabled="true" jndi-name="jdbc/IFPWAFCAD" object-type="user" pool-name="IfpwafcadPool">
- <description/>
- </jdbc-resource>
- <jdbc-connection-pool allow-non-component-callers="false" associate-with-thread="false" connection-creation-retry-attempts="0" connection-creation-retry-interval-in-seconds="10" connection-leak-reclaim="false" connection-leak-timeout-in-seconds="0" connection-validation-method="auto-commit" datasource-classname="com.mysql.jdbc.jdbc2.optional.MysqlDataSource" fail-all-connections="false" idle-timeout-in-seconds="300" is-connection-validation-required="false" is-isolation-level-guaranteed="true" lazy-connection-association="false" lazy-connection-enlistment="false" match-connections="false" max-connection-usage-count="0" max-pool-size="32" max-wait-time-in-millis="60000" name="IfpwafcadPool" non-transactional-connections="false" pool-resize-quantity="2" res-type="javax.sql.ConnectionPoolDataSource" statement-timeout-in-seconds="-1" steady-pool-size="8" validate-atmost-once-period-in-seconds="0" wrap-jdbc-objects="false">
- <property name="URL" value="jdbc:mysql://localhost:3306/my_database_2?zeroDateTimeBehavior=convertToNull"/>
- <property name="User" value="root"/>
- <property name="Password" value="denys30071996"/>
- </jdbc-connection-pool>
- </resources>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement