`
mengdejun
  • 浏览: 408040 次
  • 性别: Icon_minigender_1
  • 来自: 深圳
社区版块
存档分类
最新评论

Easyconnectionpool2.0

 
阅读更多
  1. packagecom.mdj.dmdatabase.develop;
  2. importjava.io.PrintWriter;
  3. importjava.io.Serializable;
  4. importjava.io.UnsupportedEncodingException;
  5. importjava.sql.Connection;
  6. importjava.sql.ResultSet;
  7. importjava.sql.SQLException;
  8. importjava.util.List;
  9. importjava.util.Map;
  10. importjava.util.Vector;
  11. importjavax.sql.DataSource;
  12. /**
  13. *@seeConnectionpoolEasyconnectionPool
  14. *@author武汉软件工程职业学院<br>
  15. *孟德军<br>
  16. *2009-01-01<br>
  17. *封装了Dbutils工具<br>
  18. *的部分细节
  19. *@version2.0
  20. */
  21. publicinterfaceDmDataSourceextendsDataSource,Serializable{
  22. /**
  23. *@see#resultset存放数据库的表信息.
  24. */
  25. ResultSetresultset=null;
  26. /**
  27. *@see#con数据库连接
  28. */
  29. Connectioncon=null;
  30. /**
  31. *@see#pool连接池容器.可自行选择。
  32. */
  33. Vector<Connection>pool=null;
  34. /**
  35. *@see#driverclass数据库驱动类
  36. */
  37. Stringdriverclass=null;
  38. /**
  39. *@see#uername数据库用户名
  40. */
  41. Stringuername=null;
  42. /**
  43. *@see#password数据库密码
  44. */
  45. Stringpassword=null;
  46. /**
  47. *@see#url连接数据库url
  48. */
  49. Stringurl=null;
  50. /**
  51. *@see#filepath配置文件路径.
  52. */
  53. Stringfilepath=null;
  54. /**
  55. *@see#logpath日志文件路径.
  56. */
  57. Stringlogpath=null;
  58. /**
  59. *@see#maxwaittime允许等待时间
  60. */
  61. intmaxwaittime=0;
  62. /**
  63. *@see#delaytime延迟时间
  64. */
  65. intdelaytime=0;
  66. /**
  67. *@see#maxconnection最大连接
  68. */
  69. intmaxconnection=0;
  70. /**
  71. *@see#minconnection最小连接
  72. */
  73. intminconnection=0;
  74. /**
  75. *@see#poolsize连接池大小.
  76. */
  77. intpoolsize=0;
  78. publicvoidcloseConnectionPool()throwsSQLException;
  79. /**
  80. *@paramusername数据库用户名<br>password数据库密码
  81. *@deprecated建议使用getconnection()
  82. *@see#getConnection()参见
  83. */
  84. publicConnectiongetConnection(Stringusername,Stringpassword)
  85. throwsSQLException;
  86. /**
  87. *@see#getConnection()无用户名和密码,以在配置文件中配置。
  88. */
  89. publicConnectiongetConnection()throwsSQLException;
  90. publicPrintWritergetLogWriter()throwsSQLException;
  91. publicintgetLoginTimeout()throwsSQLException;
  92. publicvoidreleaseConnection(Connectioncon);
  93. publicvoidsetLogWriter(PrintWriterout)throwsSQLException;
  94. publicvoidsetLoginTimeout(intseconds)throwsSQLException;
  95. publicMapmapexecuteQuery(Stringsql)throwsSQLException;
  96. publicListlistexecuteQuery(Stringsql,Classbeanclass)
  97. throwsSQLException;
  98. publicResultSetgetTables(Stringcatalog,Stringschemapattern,
  99. Stringtablenamepattern,String[]types)throwsSQLException;
  100. publicintgetJDBCMajorVersion()throwsSQLException;
  101. publicintgeneralUpdate(Stringsql)throwsSQLException;
  102. publicResultSetgeneralQuery(Stringsql)throwsSQLException;
  103. publicStringtoChinese(Stringstr,StringoldcharsetName,
  104. StringnewcharsetName)throwsUnsupportedEncodingException;
  105. }
  1. packagecom.mdj.dmdatabase.DmDriverManager;
  2. importjava.io.File;
  3. importjava.io.FileInputStream;
  4. importjava.io.FileNotFoundException;
  5. importjava.io.FileWriter;
  6. importjava.io.IOException;
  7. importjava.io.InputStream;
  8. importjava.io.PrintWriter;
  9. importjava.io.UnsupportedEncodingException;
  10. importjava.sql.Connection;
  11. importjava.sql.DatabaseMetaData;
  12. importjava.sql.DriverManager;
  13. importjava.sql.PreparedStatement;
  14. importjava.sql.ResultSet;
  15. importjava.sql.SQLException;
  16. importjava.sql.Statement;
  17. importjava.util.Date;
  18. importjava.util.List;
  19. importjava.util.Map;
  20. importjava.util.Properties;
  21. importjava.util.Timer;
  22. importjava.util.TimerTask;
  23. importjava.util.Vector;
  24. importjavax.xml.parsers.DocumentBuilder;
  25. importjavax.xml.parsers.DocumentBuilderFactory;
  26. importjavax.xml.parsers.ParserConfigurationException;
  27. importorg.apache.commons.dbutils.DbUtils;
  28. importorg.apache.commons.dbutils.QueryRunner;
  29. importorg.apache.commons.dbutils.handlers.BeanListHandler;
  30. importorg.apache.commons.dbutils.handlers.MapListHandler;
  31. importorg.w3c.dom.Document;
  32. importorg.w3c.dom.Element;
  33. importorg.w3c.dom.NodeList;
  34. importorg.xml.sax.SAXException;
  35. importcom.mdj.dmdatabase.pool.Dmconnection;
  36. /**
  37. *@seeConnectionpoolEasyconnectionPool
  38. *@author<hr><pbgcolor="#9acd32">武汉软件工程职业学院</p>
  39. *孟德军<br>
  40. *2009-01-03<br>
  41. *封装了Dbutils<br>
  42. *工具的部分细节
  43. *
  44. *@version2.0
  45. */
  46. publicclassDatabaseManagerextendsDmconnection{
  47. /**
  48. *
  49. */
  50. privatestaticfinallongserialVersionUID=1L;
  51. /**
  52. *@see#databasemetaData数据源.
  53. */
  54. privateDatabaseMetaDatadatabasemetaData;
  55. /**
  56. *@see#resultset存放数据库的表信息.
  57. */
  58. privateResultSetresultset=null;
  59. /**
  60. *@see#map存放mapexecuteQuery查询结果
  61. */
  62. privateMapmap=null;
  63. /**
  64. *@see#list存放listexecuteQuery查询结果
  65. */
  66. privateListlist=null;
  67. /**
  68. *@see#con数据库连接
  69. */
  70. privateConnectioncon=null;
  71. /**
  72. *@see#pool连接池容器.可自行选择。
  73. */
  74. privateVector<Connection>pool=null;
  75. /**
  76. *@see#driverclass数据库驱动类
  77. */
  78. privateStringdriverclass="dm.jdbc.driver.DmDriver";
  79. /**
  80. *@see#uername数据库用户名
  81. */
  82. privateStringusername="SYSDBA";
  83. /**
  84. *@see#password数据库密码
  85. */
  86. privateStringpassword="123456";
  87. /**
  88. *@see#url连接数据库url
  89. */
  90. privateStringurl="jdbc:dm://localhost:12345/guest";
  91. /**
  92. *@see#filepath配置文件路径.
  93. */
  94. privatestaticStringfilepath=null;
  95. /**
  96. *@see#logpath日志文件路径.
  97. */
  98. privateStringlogpath="..//server.log";
  99. /**
  100. *@see#maxwaittime允许等待时间
  101. */
  102. privateintmaxwaittime=10;
  103. /**
  104. *@see#delaytime延迟时间
  105. */
  106. privateintdelaytime=10;
  107. /**
  108. *@see#maxconnection最大连接
  109. */
  110. privateintmaxconnection=10;
  111. /**
  112. *@see#minconnection最小连接
  113. */
  114. privateintminconnection=5;
  115. /**
  116. *@see#poolsize连接池大小.
  117. */
  118. privateintpoolsize=10;
  119. /**
  120. *@see#manager本类实例.
  121. */
  122. privatestaticDatabaseManagermanager=null;
  123. /**
  124. *@see#timer扫描连接池.
  125. */
  126. privateTimertimer;
  127. privatePrintWriterwriter;
  128. privatebooleanloading=false;
  129. /**
  130. *@see#addConnection()为连接池添加连接
  131. *@throwsClassNotFoundException
  132. */
  133. privateDatabaseManager(){
  134. try{
  135. init();
  136. Filefile=newFile(logpath);
  137. writer=newPrintWriter(newFileWriter(file.getAbsolutePath(),
  138. true),true);
  139. addConnection();
  140. }catch(IOExceptione){
  141. e.printStackTrace();
  142. }
  143. }
  144. privatevoidinit(){
  145. if(loading==false){
  146. config(filepath);
  147. }else{
  148. readconfig(filepath);
  149. }
  150. pool=newVector<Connection>(maxconnection);
  151. timer=newTimer(true);
  152. }
  153. staticpublicsynchronizedDatabaseManagergetinstance(Stringpath){
  154. //必须先初始化变量filepath,然后在创建变量.
  155. DatabaseManager.filepath=path;
  156. if(manager==null){
  157. manager=newDatabaseManager();
  158. }
  159. returnmanager;
  160. }
  161. privatevoidaddConnection(){
  162. serverlog("serverstart");
  163. for(inti=0;i<maxconnection;i++){
  164. try{
  165. Class.forName(driverclass);
  166. DriverManager.setLogWriter(writer);
  167. DriverManager.setLoginTimeout(maxwaittime);
  168. con=DriverManager.getConnection(url,username,password);
  169. pool.add(con);
  170. }catch(ClassNotFoundExceptione){
  171. //TODOAuto-generatedcatchblock
  172. serverlog(e.getMessage());
  173. }catch(SQLExceptione){
  174. //TODOAuto-generatedcatchblock
  175. serverlog(e.getMessage());
  176. }
  177. }
  178. }
  179. /**
  180. *@see#releaseConnection(Connection)释放连接,返还连接池.
  181. *@returncon当前连接.
  182. *
  183. */
  184. publicsynchronizedConnectiongetConnection()throwsSQLException{
  185. if(pool.size()>0){
  186. con=pool.get(0);
  187. pool.remove(0);
  188. scaner();
  189. returncon;
  190. }else{
  191. returncon;
  192. }
  193. }
  194. /**
  195. *@see#releaseConnection(Connection)释放连接,返还连接池.
  196. *@returncon当前连接.
  197. *
  198. */
  199. publicsynchronizedConnectiongetConnection(Stringusername,
  200. Stringpassword){
  201. if(pool.size()>0){
  202. con=pool.get(0);
  203. pool.remove(0);
  204. returncon;
  205. }else{
  206. returncon;
  207. }
  208. }
  209. publicsynchronizedvoidreleaseConnection(Connectioncon){
  210. pool.add(con);
  211. }
  212. /**
  213. *@return无返回值
  214. *@see#closeConnectionPool()关闭连接,清空连接池.
  215. *@throwsSQLException
  216. */
  217. publicvoidcloseConnectionPool()throwsSQLException{
  218. for(inti=0;i<pool.size();i++){
  219. pool.get(i).close();
  220. pool.clear();
  221. timer.cancel();
  222. }
  223. }
  224. /**
  225. *@see#scaner()扫描连接池.
  226. */
  227. privatevoidscaner(){
  228. TimerTasktask=newTimerTask(){
  229. @Override
  230. publicvoidrun(){
  231. //TODOAuto-generatedmethodstub
  232. if(manager.pool.size()<maxconnection){
  233. while(manager.pool.size()<maxconnection){
  234. addConnection();
  235. }
  236. }
  237. }
  238. };
  239. timer.schedule(task,10000,10000);
  240. }
  241. /**
  242. *@see#config(String)读取配置文件.<br>
  243. *初始化数据库连接数据.
  244. *@since<hr>http://blog.csdn.net/mak0000<a
  245. *href="http://blog.csdn.net/mak0000">更多信息</a>
  246. *@throwspath
  247. *为配置文件路径,文件路径错误会抛出FileNotFoundException异常
  248. */
  249. /**
  250. *@see#config(String)读取配置文件.
  251. */
  252. privatevoidconfig(Stringpath){
  253. loading=true;
  254. DocumentBuilderFactoryfactory=DocumentBuilderFactory.newInstance();
  255. try{
  256. DocumentBuilderbuilder=factory.newDocumentBuilder();
  257. Documentdocument=builder.parse(DatabaseManager.filepath);
  258. NodeListnodelist=document.getElementsByTagName("dbmsdriver");
  259. for(inti=0;i<nodelist.getLength();i++){
  260. Elementelement=(Element)nodelist.item(i);
  261. driverclass=element.getElementsByTagName("driverclass").item(
  262. 0).getFirstChild().getNodeValue();
  263. url=element.getElementsByTagName("url").item(0)
  264. .getFirstChild().getNodeValue();
  265. username=element.getElementsByTagName("username").item(0)
  266. .getFirstChild().getNodeValue();
  267. password=element.getElementsByTagName("password").item(0)
  268. .getFirstChild().getNodeValue();
  269. maxconnection=Integer
  270. .parseInt(element.getElementsByTagName("maxconnection")
  271. .item(0).getFirstChild().getNodeValue());
  272. minconnection=Integer
  273. .parseInt(element.getElementsByTagName("minconnection")
  274. .item(0).getFirstChild().getNodeValue());
  275. logpath=element.getElementsByTagName("logpath").item(0)
  276. .getFirstChild().getNodeValue();
  277. maxwaittime=Integer.parseInt(element.getElementsByTagName(
  278. "maxwaittime").item(0).getFirstChild().getNodeValue());
  279. delaytime=Integer.parseInt(element.getElementsByTagName(
  280. "delaytime").item(0).getFirstChild().getNodeValue());
  281. }
  282. }catch(ParserConfigurationExceptione){
  283. //TODOAuto-generatedcatchblock
  284. e.printStackTrace();
  285. serverlog(newDate()+":/t"+e.getMessage()+"/n");
  286. }catch(SAXExceptione){
  287. e.printStackTrace();
  288. serverlog(newDate()+":/t"+e.getMessage()+"/n");
  289. }catch(IOExceptione){
  290. e.printStackTrace();
  291. serverlog(newDate()+":/t"+e.getMessage()+"/n");
  292. }
  293. }
  294. /**
  295. *@deprecated该方法为候选方法.
  296. *@parampath
  297. *配置文件路径.
  298. */
  299. publicvoidreadconfig(Stringpath){
  300. loading=false;
  301. Propertiesproperties=newProperties();
  302. try{
  303. InputStreamin=newFileInputStream(DatabaseManager.filepath);
  304. properties.load(in);
  305. driverclass=properties.getProperty("driverclass");
  306. url=properties.getProperty("url");
  307. username=properties.getProperty("username");
  308. password=properties.getProperty("password");
  309. maxconnection=Integer.parseInt(properties
  310. .getProperty("maxconnection"));
  311. minconnection=Integer.parseInt(properties
  312. .getProperty("minconnection"));
  313. delaytime=Integer.parseInt(properties.getProperty("delaytime"));
  314. logpath=properties.getProperty("logpath");
  315. in.close();
  316. }catch(FileNotFoundExceptione){
  317. e.printStackTrace();
  318. }catch(IOExceptione){
  319. e.printStackTrace();
  320. }
  321. }
  322. /**
  323. *@see#serverlog(String)日志.
  324. *@parammsg
  325. *异常及日常信息.
  326. *@since<ahref="http://www.w3.org/xmlschema">建议将变量以配置文件形式存放,<br>
  327. *以方便使用,例如xml,properties<br>
  328. *文件.</a>
  329. */
  330. privatevoidserverlog(Stringmsg){
  331. writer.println(newDate()+":"+msg);
  332. writer.close();
  333. }
  334. /**
  335. *@see#setLogWriter(PrintWriter)setdelaytime
  336. *@throwsSQLException
  337. */
  338. publicvoidsetLoginTimeout(intseconds)throwsSQLException{
  339. this.maxwaittime=seconds;
  340. }
  341. /**
  342. *@see#getLoginTimeout()getdelaytime.
  343. *@throwsSQLException
  344. */
  345. publicintgetLoginTimeout()throwsSQLException{
  346. returnmaxwaittime;
  347. }
  348. /**
  349. *@see#setLogWriter(PrintWriter)setlogwriter.
  350. *@throwsSQLException
  351. */
  352. publicvoidsetLogWriter(PrintWriterout)throwsSQLException{
  353. this.writer=out;
  354. }
  355. /**
  356. *@see#getLogWriter()getlogwriter
  357. *@throwsSQLException
  358. */
  359. publicPrintWritergetLogWriter()throwsSQLException{
  360. returnwriter;
  361. }
  362. /**
  363. *@see#listexecuteQuery(String,Class)putthevarinlist,listincludesobjectsbean
  364. *@sinceBook.class<br>
  365. *Bookbook=(Book)result.get(i);<br>
  366. *book.getid();
  367. */
  368. @Override
  369. publicListlistexecuteQuery(Stringsql,Classbeanclass)
  370. throwsSQLException{
  371. con=getConnection();
  372. DbUtils.loadDriver(driverclass);
  373. //buildaqueryrunnerinstance.
  374. QueryRunnerqueryrunner=newQueryRunner();
  375. list=(List)queryrunner.query(con,sql,
  376. newBeanListHandler(beanclass));
  377. releaseConnection(con);
  378. returnlist;
  379. }
  380. /**
  381. *@see#mapexecuteQuery(String)map形式存放数据.listincludesmap
  382. */
  383. @Override
  384. publicMapmapexecuteQuery(Stringsql)throwsSQLException{
  385. //TODOAuto-generatedmethodstub
  386. con=getConnection();
  387. DbUtils.loadDriver(driverclass);
  388. QueryRunnerqueryrunner=newQueryRunner();
  389. list=(List)queryrunner.query(con,sql,newMapListHandler());
  390. releaseConnection(con);
  391. for(inti=0;i<list.size();i++){
  392. map=(Map)list.get(i);
  393. }
  394. returnmap;
  395. }
  396. /**
  397. *@see#getTables(String,String,String,String[])获取数据库表结构.
  398. *@paramcatalog
  399. *,schemaPattern,tableNamePattern,types
  400. *
  401. */
  402. publicResultSetgetTables(Stringcatalog,StringschemaPattern,
  403. StringtableNamePattern,String[]types)throwsSQLException{
  404. con=getConnection();
  405. databasemetaData=con.getMetaData();
  406. resultset=databasemetaData.getTables(catalog,schemaPattern,
  407. tableNamePattern,types);
  408. releaseConnection(con);
  409. returnresultset;
  410. }
  411. /**
  412. *@see#getJDBCMajorVersion()jdbc主版本号.
  413. */
  414. @Override
  415. publicintgetJDBCMajorVersion()throwsSQLException{
  416. //TODOAuto-generatedmethodstub
  417. con=getConnection();
  418. databasemetaData=con.getMetaData();
  419. intversion=databasemetaData.getJDBCMajorVersion();
  420. releaseConnection(con);
  421. returnversion;
  422. }
  423. /**
  424. *@see#getJDBCMinorVersion()jdbc次版本号.
  425. */
  426. @Override
  427. publicintgetJDBCMinorVersion()throwsSQLException{
  428. //TODOAuto-generatedmethodstub
  429. con=getConnection();
  430. databasemetaData=con.getMetaData();
  431. intversion=databasemetaData.getJDBCMinorVersion();
  432. releaseConnection(con);
  433. returnversion;
  434. }
  435. @Override
  436. /*
  437. *@see#getMaxConnections()数据库支持的同时建立连接的对象数目.
  438. */
  439. publicintgetMaxConnections()throwsSQLException{
  440. con=getConnection();
  441. databasemetaData=con.getMetaData();
  442. intmaxconnection=databasemetaData.getMaxConnections();
  443. releaseConnection(con);
  444. returnmaxconnection;
  445. }
  446. /**
  447. *@see#getMaxStatements()数据库支持同时打开statement的数目.
  448. */
  449. @Override
  450. publicintgetMaxStatements()throwsSQLException{
  451. //TODOAuto-generatedmethodstub
  452. con=getConnection();
  453. databasemetaData=con.getMetaData();
  454. intminconnection=databasemetaData.getMaxStatements();
  455. releaseConnection(con);
  456. returnminconnection;
  457. }
  458. /**
  459. *@see#generalUpdate(String)更新.
  460. */
  461. publicintgeneralUpdate(Stringsql){
  462. intresult=0;
  463. Statementstatement;
  464. try{
  465. con=getConnection();
  466. statement=con.createStatement(ResultSet.TYPE_SCROLL_INSENSITIVE,
  467. ResultSet.CONCUR_UPDATABLE);
  468. result=statement.executeUpdate(sql);
  469. statement.close();
  470. releaseConnection(con);
  471. }catch(SQLExceptione){
  472. //TODOAuto-generatedcatchblock
  473. serverlog(e.getSQLState()+"/t"+e.getMessage());
  474. }
  475. returnresult;
  476. }
  477. publicResultSetgeneralQuery(Stringsql){
  478. ResultSetresult=null;
  479. Statementstatement;
  480. try{
  481. con=getConnection();
  482. statement=con.createStatement();
  483. result=statement.executeQuery(sql);
  484. result.close();
  485. statement.close();
  486. releaseConnection(con);
  487. }catch(SQLExceptione){
  488. serverlog(e.getSQLState()+"/t"+e.getMessage());
  489. }
  490. returnresult;
  491. }
  492. publicStringtoChinese(Stringstr,StringoldcharsetName,
  493. StringnewcharsetName){
  494. Stringchinesestr=null;
  495. if(str.equals(null)||str==""){
  496. chinesestr="";
  497. }else{
  498. try{
  499. chinesestr=newString(str.getBytes(oldcharsetName),
  500. newcharsetName);
  501. }catch(UnsupportedEncodingExceptione){
  502. serverlog("/t"+e.getMessage());
  503. }
  504. }
  505. returnchinesestr;
  506. }
  507. }

  1. packagecom.mdj.dmdatabase.test;
  2. importjava.io.IOException;
  3. importjava.sql.Connection;
  4. importjava.sql.SQLException;
  5. importjava.util.List;
  6. importjava.util.Map;
  7. importcom.mdj.dmdatabase.DmDriverManager.DatabaseManager;
  8. importcom.mdj.dmdatabase.javabean.Guest;
  9. /**
  10. *@since<ahref="http://blog.csdn.net/mak0000">Connectionpool
  11. *EasyconnectionPool</a>
  12. *@author武汉软件工程职业学院<br>
  13. *孟德军<br>
  14. *2009-01-01<br>
  15. *封装了Dbutils工具<br>
  16. *的部分细节
  17. *@version2.0
  18. *
  19. */
  20. publicclassTest{
  21. /**
  22. *@see#managerDatabaseManager类的实例.
  23. */
  24. privateDatabaseManagermanager;
  25. /**
  26. *@see#con<pbgcolor="#9acd32">java.sql.ConnectionconConnection实例</p>
  27. */
  28. privateConnectioncon=null;
  29. publicTest(Stringpath)throwsIOException,SQLException{
  30. manager=DatabaseManager.getinstance(path);
  31. //con=manager.getConnection();
  32. /**
  33. *此处书写代码.查询数据无需用connection接收
  34. */
  35. /*inta=manager.generalUpdate("insertintoguestbook(author,title,ip,updatetime,content)values('王红梅','你过得怎么样','192.168.18.1','2009-01-04','你过得怎么样')");
  36. System.out.println(a);*/
  37. Mapmap=manager.mapexecuteQuery("select*fromguestbook");
  38. for(inti=0;i<map.size();i++){
  39. System.out.println(map.get("author")+""+map.get("title")+""
  40. +map.get("ip")+map.get("updatetime")+""
  41. +map.get("content"));
  42. }
  43. Listlist=manager.listexecuteQuery("select*fromguestbook",
  44. Guest.class);
  45. Guestguestbook=null;
  46. for(inti=0;i<list.size();i++){
  47. guestbook=(Guest)list.get(i);
  48. System.out
  49. .println(guestbook.getAuthor()+"/t"
  50. +guestbook.getTitle()+"/t"+guestbook.getIp()
  51. +"/t"+guestbook.getUpdatetime()+"/t"
  52. +guestbook.getContent());
  53. }
  54. manager.releaseConnection(con);manager.closeConnectionPool();
  55. }
  56. publicstaticvoidmain(String[]args){
  57. Stringpath=System.getProperty("user.dir")+"//src//sysconfig.xml";
  58. try{
  59. newTest(path);
  60. }catch(SQLExceptione){
  61. }catch(IOExceptione){
  62. e.printStackTrace();
  63. }
  64. }
  65. }
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics