You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by ja...@apache.org on 2007/05/09 02:15:11 UTC
svn commit: r536384 - in /ofbiz/trunk/framework/webtools:
webapp/webtools/WEB-INF/controller.xml
webapp/webtools/entity/minervaObjects.ftl webapp/webtools/main.ftl
widget/EntityScreens.xml
Author: jaz
Date: Tue May 8 17:15:10 2007
New Revision: 536384
URL: http://svn.apache.org/viewvc?view=rev&rev=536384
Log:
added new screen to show minerva connection pool data
Added:
ofbiz/trunk/framework/webtools/webapp/webtools/entity/minervaObjects.ftl (with props)
Modified:
ofbiz/trunk/framework/webtools/webapp/webtools/WEB-INF/controller.xml
ofbiz/trunk/framework/webtools/webapp/webtools/main.ftl
ofbiz/trunk/framework/webtools/widget/EntityScreens.xml
Modified: ofbiz/trunk/framework/webtools/webapp/webtools/WEB-INF/controller.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/webtools/webapp/webtools/WEB-INF/controller.xml?view=diff&rev=536384&r1=536383&r2=536384
==============================================================================
--- ofbiz/trunk/framework/webtools/webapp/webtools/WEB-INF/controller.xml (original)
+++ ofbiz/trunk/framework/webtools/webapp/webtools/WEB-INF/controller.xml Tue May 8 17:15:10 2007
@@ -154,6 +154,11 @@
<response name="success" type="view" value="sitemap"/>
</request-map>
+ <request-map uri="minervainfo">
+ <security https="true" auth="true"/>
+ <response name="success" type="view" value="minervaobjects"/>
+ </request-map>
+
<request-map uri="entitymaint">
<security https="true" auth="true"/>
<response name="success" type="view" value="entitymaint"/>
@@ -609,7 +614,8 @@
<view-map name="EntityImportReaders" page="component://webtools/widget/EntityScreens.xml#EntityImportReaders" type="screen"/>
<view-map name="ViewComponents" page="component://webtools/widget/MiscScreens.xml#ViewComponents" type="screen"/>
-
+ <view-map name="minervaobjects" page="component://webtools/widget/EntityScreens.xml#minervaobjects" type="screen"/>
+
<!-- cert views -->
<view-map name="viewbrowsercerts" type="screen" page="component://webtools/widget/CommonScreens.xml#browsercerts"/>
<!-- end of view mappings -->
Added: ofbiz/trunk/framework/webtools/webapp/webtools/entity/minervaObjects.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/webtools/webapp/webtools/entity/minervaObjects.ftl?view=auto&rev=536384
==============================================================================
--- ofbiz/trunk/framework/webtools/webapp/webtools/entity/minervaObjects.ftl (added)
+++ ofbiz/trunk/framework/webtools/webapp/webtools/entity/minervaObjects.ftl Tue May 8 17:15:10 2007
@@ -0,0 +1,63 @@
+<#--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<h1>Minerva Connection Objects</h1>
+<br/>
+
+<div class="button-bar">
+ <a href="<@o...@ofbizUrl>" class="smallSubmit">Refresh</a>
+</div>
+
+<#assign groups = delegator.getModelGroupReader().getGroupNames()?if_exists/>
+<table class="basic-table light-grid hover-bar" cellspacing="0">
+ <tr class="header-row">
+ <td>Helper Name</td>
+ <td>Pool</td>
+ <td>Thread</td>
+ <td>Object</td>
+ <td>Created</td>
+ <td>Last Used</td>
+ <td>In Use</td>
+ </tr>
+ <#assign alt_row = false>
+ <#if (groups?has_content)>
+ <#list groups as group>
+ <#assign helper = delegator.getGroupHelperName(group)?if_exists/>
+ <#if (helper?has_content)>
+ <#assign pooledObjs = Static["org.ofbiz.entity.transaction.MinervaConnectionFactory"].getPooledData(helper)?if_exists/>
+ <#assign pool = Static["org.ofbiz.entity.transaction.MinervaConnectionFactory"].getPoolName(helper)?if_exists/>
+ <#if (pooledObjs?has_content)>
+ <#list pooledObjs as obj>
+ <tr<#if alt_row> class="alternate-row"</#if>>
+ <td>${helper}</td>
+ <td>${pool}</td>
+ <td>${(obj.getThread().getName())?default("n/a")}</td>
+ <td>${(obj.getObject().toString())?default("n/a")}</td>
+ <td>${obj.getCreationDate()?datetime?default("n/a")?string}</td>
+ <td>${obj.getLastUsedDate()?datetime?default("n/a")?string}</td>
+ <td>${obj.isInUse()?default(false)?string}</td>
+ </tr>
+ <#assign alt_row = !alt_row>
+ </#list>
+ </#if>
+ </#if>
+ </#list>
+ <#else>
+ <tr><td colspan="6">No helpers found.</td></tr>
+ </#if>
+</table>
\ No newline at end of file
Propchange: ofbiz/trunk/framework/webtools/webapp/webtools/entity/minervaObjects.ftl
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: ofbiz/trunk/framework/webtools/webapp/webtools/entity/minervaObjects.ftl
------------------------------------------------------------------------------
svn:keywords = "Date Rev Author URL Id"
Propchange: ofbiz/trunk/framework/webtools/webapp/webtools/entity/minervaObjects.ftl
------------------------------------------------------------------------------
svn:mime-type = text/plain
Modified: ofbiz/trunk/framework/webtools/webapp/webtools/main.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/webtools/webapp/webtools/main.ftl?view=diff&rev=536384&r1=536383&r2=536384
==============================================================================
--- ofbiz/trunk/framework/webtools/webapp/webtools/main.ftl (original)
+++ ofbiz/trunk/framework/webtools/webapp/webtools/main.ftl Tue May 8 17:15:10 2007
@@ -75,6 +75,7 @@
<li><a href="<@o...@ofbizUrl>">${uiLabelMap.WebtoolsEntitySyncStatus}</a></li>
<li><a href="<@o...@ofbizUrl>" target="_blank">${uiLabelMap.WebtoolsInduceModelXMLFromDatabase}</a></li>
<li><a href="<@o...@ofbizUrl>">${uiLabelMap.WebtoolsCheckUpdateDatabase}</a></li>
+ <li><a href="<@o...@ofbizUrl>">Minerva Connection Info</a></li>
<#-- want to leave these out because they are only working so-so, and cause people more problems that they solve, IMHO
<li><a href="<@o...@ofbizUrl>" target="_blank">Edit Entity Definitions</a></li>
<li><a href="<@o...@ofbizUrl>" target="_blank">Generate Entity Model XML (all in one)</a></li>
Modified: ofbiz/trunk/framework/webtools/widget/EntityScreens.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/webtools/widget/EntityScreens.xml?view=diff&rev=536384&r1=536383&r2=536384
==============================================================================
--- ofbiz/trunk/framework/webtools/widget/EntityScreens.xml (original)
+++ ofbiz/trunk/framework/webtools/widget/EntityScreens.xml Tue May 8 17:15:10 2007
@@ -382,7 +382,25 @@
</section>
</screen>
-
+ <screen name="minervaobjects">
+ <section>
+ <actions>
+ <set field="headerItem" value="main"/>
+ <set field="title" value="Minerva Connection Objects"/>
+ </actions>
+ <widgets>
+ <decorator-screen name="CommonWebtoolsDecorator" location="${parameters.mainDecoratorLocation}">
+ <decorator-section name="body">
+ <platform-specific>
+ <html>
+ <html-template location="component://webtools/webapp/webtools/entity/minervaObjects.ftl"/>
+ </html>
+ </platform-specific>
+ </decorator-section>
+ </decorator-screen>
+ </widgets>
+ </section>
+ </screen>
</screens>