Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Dynamically building web content using XML file(s)

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Hello All!

I was recently tasked with a project to design a monitoring web application for our "in-house" built web applications. There is a certain set of modules and parameters that we need to monitor: GSLB --> Web Tier --> App Tier --> Database.

Almost all (80%) of our applications share the same parameters that need to be monitored, but there are about a hundred of them. So here is what I'm thinking of doing....

1. Create an XML document for each application (An example layout is included at the end of this post) and save it in the Applications directory.
2. Setup a Spring project, and create code to dynamically go through the Applications directory and kick-off the monitoring logic for each <application/> item. Basically, the code will just traverse through all of the xml files (I might even create just 1 xml file with all of the <application/> items in it), read the "metadata" for each application, and start the backend processing, as well as display the data in a dynamically-generated web GUI (based on the XML structure and data).

Again, most of our applications (80%) have the same modules/parameters, therefore adding an application would only require us adding another <application/> element to the already-existing xml document (or adding an additional XML document). The code would do the rest...In regards to the rest 20% of applications, I would create a customize XML document with additional metadata (the code, in that case, would be able to handle the additional metadata).

So here are my questions:

1. What do you think of the idea itself? I'm sure that I'm not the only one who's thought of this, so are there any best-practices in this regard?
2. The reason I thought of using Spring is that it is XML-based (there are many reasons for me using Spring actually -- Security, ORM integration, etc), and it might facilitate my efforts. I'm thinking that even if reading through the Applications directory isn't such a good idea, I can somehow utilize Spring's dependency injection & AOS to create the appropriate solution. Have anybody tried this before and willing to share ideas, implementation approach, etc?
3. Other than Spring, what might help me accomplish this task?
4. Is this feasible (from a time and effort stand-point), or should I just do it the old-fashioned way?

Thanks in advance!
Vladimir

I'm including a sample XML document (very rough-draft) in this post:

<applications>
<application name="Remote Application">
<vip>somethingUNIQUE.mycompany.com</vip>
<sys-level>LAB</sys-level>
<lb-type>GTM</lb-type>
<farms>
<farm name="Farm 1" id="1">
<member-name>sslname.mycompany</member-name>
<ip-address>34.34.24.242</ip-address>
<application-servers>
<application-server name="Some Name1">
<ip-address>
34.983.238.32
</ip-address>
</application-server>
<application-server name="Some Name 2222">
<ip-address>
34.343.248.32
</ip-address>
</application-server>
<application-server name="Some Name 3425">
<ip-address>
34.343.248.32
</ip-address>
</application-server>
</application-servers>
<web-servers>
<web-server name="Some Name1">
<ip-address>
34.983.238.32
</ip-address>
</web-server>
<web-server name="Some Name 2222">
<ip-address>
34.343.248.32
</ip-address>
</web-server>
<web-server name="Some Name 3425">
<ip-address>
34.343.248.32
</ip-address>
</web-server>
</web-servers>
</farm>
<farm name="Farm 2" id="2">
<member-name>sslvpn01.downingtown</member-name>
<ip-address>34.34.24.250</ip-address>
<application-servers>
<application-server name="Some Name 3425">
<ip-address>
34.343.248.32
</ip-address>
</application-server>
</application-servers>
<web-servers>
<web-server name="Some Name1">
<ip-address>
34.983.238.32
</ip-address>
</web-server>
<web-server name="Some Name 3425">
<ip-address>
34.343.248.32
</ip-address>
</web-server>
</web-servers>
</farm>
</farms>
</application>
<application name="Tech Tools">
<vip>technicalUNIQUE.tools.mycompany.com</vip>
<sys-level>LAB</sys-level>
<lb-type>GTM</lb-type>
<farms>
<farm name="Farm 1" id="1">
<member-name>tools.tech</member-name>
<ip-address>34.34.24.214</ip-address>
<application-servers>
<application-server name="Some Name 2222">
<ip-address>
34.343.248.32
</ip-address>
</application-server>
<application-server name="Some Name 3425">
<ip-address>
34.343.248.32
</ip-address>
</application-server>
</application-servers>
<web-servers>
<web-server name="Some Name1">
<ip-address>
34.983.238.32
</ip-address>
</web-server>
<web-server name="Some Name 2222">
<ip-address>
34.343.248.32
</ip-address>
</web-server>
</web-servers>
</farm>
<farm name="Farm 2" id="2">
<member-name>tools.tech222</member-name>
<ip-address>34.34.24.415</ip-address>
<application-servers>
<application-server name="Some Name1">
<ip-address>
34.983.238.32
</ip-address>
</application-server>
<application-server name="Some Name 2222">
<ip-address>
34.343.248.32
</ip-address>
</application-server>
<application-server name="Some Name 3425">
<ip-address>
34.343.248.32
</ip-address>
</application-server>
</application-servers>
<web-servers>
<web-server name="Some Name1">
<ip-address>
34.983.238.32
</ip-address>
</web-server>
<web-server name="Some Name 2222">
<ip-address>
34.343.248.32
</ip-address>
</web-server>
<web-server name="Some Name 3425">
<ip-address>
34.343.248.32
</ip-address>
</web-server>
</web-servers>
</farm>
</farms>
</application>
</applications>
 
Marshal
Posts: 28193
95
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Well, nobody seems to have any opinion on this, taken as a question about XML. So let's see if anybody has an opinion on it as a question about Spring.

(Moving to the Spring forum.)
 
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Please do not cross post. Ask the question once in one forum.

Thanks, closing this thread

Mark
 
Consider Paul's rocket mass heater.
    Bookmark Topic Watch Topic
  • New Topic