org.rhq.plugins.postgres
Class PostgresUserComponent

java.lang.Object
  extended by org.rhq.plugins.postgres.PostgresUserComponent
All Implemented Interfaces:
AvailabilityFacet, ConfigurationFacet, DeleteResourceFacet, ResourceComponent<PostgresServerComponent>, MeasurementFacet, DatabaseComponent<PostgresServerComponent>

public class PostgresUserComponent
extends java.lang.Object
implements DatabaseComponent<PostgresServerComponent>, MeasurementFacet, ConfigurationFacet, DeleteResourceFacet

Author:
Greg Hinkle

Nested Class Summary
static class PostgresUserComponent.UpdateType
           
 
Constructor Summary
PostgresUserComponent()
           
 
Method Summary
 void deleteResource()
           
 AvailabilityType getAvailability()
           
 java.sql.Connection getConnection()
           
 java.lang.String getUserName()
           
static java.lang.String getUserSQL(Configuration config, PostgresUserComponent.UpdateType type)
           
 void getValues(MeasurementReport report, java.util.Set<MeasurementScheduleRequest> metrics)
           
 Configuration loadResourceConfiguration()
           
 void removeConnection()
           
 void start(ResourceContext<PostgresServerComponent> resourceContext)
           
 void stop()
           
 void updateResourceConfiguration(ConfigurationUpdateReport report)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PostgresUserComponent

public PostgresUserComponent()
Method Detail

start

public void start(ResourceContext<PostgresServerComponent> resourceContext)
Specified by:
start in interface ResourceComponent<PostgresServerComponent>

stop

public void stop()
Specified by:
stop in interface ResourceComponent<PostgresServerComponent>

getUserName

public java.lang.String getUserName()

getAvailability

public AvailabilityType getAvailability()
Specified by:
getAvailability in interface AvailabilityFacet

getConnection

public java.sql.Connection getConnection()
Specified by:
getConnection in interface DatabaseComponent<PostgresServerComponent>

removeConnection

public void removeConnection()
Specified by:
removeConnection in interface DatabaseComponent<PostgresServerComponent>

getValues

public void getValues(MeasurementReport report,
                      java.util.Set<MeasurementScheduleRequest> metrics)
               throws java.lang.Exception
Specified by:
getValues in interface MeasurementFacet
Throws:
java.lang.Exception

loadResourceConfiguration

public Configuration loadResourceConfiguration()
                                        throws java.lang.Exception
Specified by:
loadResourceConfiguration in interface ConfigurationFacet
Throws:
java.lang.Exception

updateResourceConfiguration

public void updateResourceConfiguration(ConfigurationUpdateReport report)
Specified by:
updateResourceConfiguration in interface ConfigurationFacet

getUserSQL

public static java.lang.String getUserSQL(Configuration config,
                                          PostgresUserComponent.UpdateType type)

deleteResource

public void deleteResource()
                    throws java.lang.Exception
Specified by:
deleteResource in interface DeleteResourceFacet
Throws:
java.lang.Exception


Copyright © 2008-2009 Red Hat, Inc.. All Rights Reserved.