1
//$Id: HibernateServiceMBean.java 10860 2006-11-22 00:02:55Z steve.ebersole@jboss.com $
2
package org.hibernate.jmx;
4
import org.hibernate.HibernateException;
7
* Hibernate JMX Management API
8
* @see HibernateService
9
* @author John Urberg, Gavin King
11
public interface HibernateServiceMBean {
14
* The Hibernate mapping files (might be overridden by subclasses
15
* that want to specify the mapping files by some other mechanism)
18
public String getMapResources();
20
* Specify the Hibernate mapping files
23
public void setMapResources(String mappingFiles);
28
public void addMapResource(String mapResource);
32
* @param property the property name
33
* @param value the property value
35
public void setProperty(String property, String value);
39
* @param property the property name
40
* @return the property value
42
public String getProperty(String property);
45
* Display the properties
46
* @return a list of property names and values
48
public String getPropertyList();
51
* The JNDI name of the datasource to use in this <tt>SessionFactory</tt>
54
public String getDatasource();
56
* Set the JNDI name of the datasource to use in this <tt>SessionFactory</tt>
59
public void setDatasource(String datasource);
62
* Log into the database with this name
65
public String getUserName();
67
* Log into the database with this name
70
public void setUserName(String userName);
73
* Log into the database with this password
76
public String getPassword();
78
* Log into the database with this password
81
public void setPassword(String password);
84
* The JNDI name of the dialect class to use in this <tt>SessionFactory</tt>
87
public String getDialect();
89
* The name of the dialect class to use in this <tt>SessionFactory</tt>
90
* @param dialect fully qualified class name of <tt>Dialect</tt> subclass
91
* @see org.hibernate.dialect.Dialect
93
public void setDialect(String dialect);
96
* The JNDI name to bind to the <tt>SessionFactory</tt>
99
public String getJndiName();
101
* The JNDI name to bind to the <tt>SessionFactory</tt>
104
public void setJndiName(String jndiName);
107
* The fully qualified class name of the Hibernate <tt>TransactionFactory</tt> implementation
108
* @return the class name
109
* @see org.hibernate.transaction.TransactionFactory
111
public String getTransactionStrategy();
114
* Set the fully qualified class name of the Hibernate <tt>TransactionFactory</tt> implementation
115
* @param txnStrategy the class name
116
* @see org.hibernate.transaction.TransactionFactory
118
public void setTransactionStrategy(String txnStrategy);
121
* The JNDI name of the JTA UserTransaction object (used only be <tt>JTATransaction</tt>).
122
* @return the JNDI name
123
* @see org.hibernate.transaction.JTATransaction
125
public String getUserTransactionName();
127
* Set the JNDI name of the JTA UserTransaction object (used only by <tt>JTATransaction</tt>).
128
* @param utName the JNDI name
129
* @see org.hibernate.transaction.JTATransaction
131
public void setUserTransactionName(String utName);
134
* Get the strategy for obtaining the JTA <tt>TransactionManager</tt>
135
* @return the class name
136
* @see org.hibernate.transaction.TransactionManagerLookup
138
public String getTransactionManagerLookupStrategy();
140
* Set the strategy for obtaining the JTA <tt>TransactionManager</tt>
141
* @param lkpStrategy the class name
142
* @see org.hibernate.transaction.TransactionManagerLookup
144
public void setTransactionManagerLookupStrategy(String lkpStrategy);
147
* Is SQL logging enabled?
149
public String getShowSqlEnabled();
151
* Enable logging of SQL to console
153
public void setShowSqlEnabled(String showSql);
155
* Get the maximum outer join fetch depth
157
public String getMaximumFetchDepth();
159
* Set the maximum outer join fetch depth
161
public void setMaximumFetchDepth(String fetchDepth);
163
* Get the maximum JDBC batch size
165
public String getJdbcBatchSize();
167
* Set the maximum JDBC batch size
169
public void setJdbcBatchSize(String batchSize);
171
* Get the JDBC fetch size
173
public String getJdbcFetchSize();
175
* Set the JDBC fetch size
177
public void setJdbcFetchSize(String fetchSize);
179
* Get the query language substitutions
181
public String getQuerySubstitutions();
183
* Set the query language substitutions
185
public void setQuerySubstitutions(String querySubstitutions);
187
* Get the default schema
189
public String getDefaultSchema();
191
* Set the default schema
193
public void setDefaultSchema(String schema);
195
* Get the default catalog
197
public String getDefaultCatalog();
199
* Set the default catalog
201
public void setDefaultCatalog(String catalog);
203
* Is use of scrollable resultsets enabled?
205
public String getJdbcScrollableResultSetEnabled();
207
* Enable or disable the use of scrollable resultsets
209
public void setJdbcScrollableResultSetEnabled(String enabled);
211
* Is use of JDBC3 <tt>getGeneratedKeys()</tt> enabled?
213
public String getGetGeneratedKeysEnabled();
215
* Enable or disable the use <tt>getGeneratedKeys()</tt>
217
public void setGetGeneratedKeysEnabled(String enabled);
219
* Get the second-level cache provider class name
221
public String getCacheProviderClass();
223
* Set the second-level cache provider class name
225
public void setCacheProviderClass(String providerClassName);
227
* For cache providers which support this setting, get the
228
* provider's specific configuration resource.
230
public String getCacheProviderConfig();
232
* For cache providers which support this setting, specify the
233
* provider's specific configuration resource.
235
public void setCacheProviderConfig(String cacheProviderConfig);
237
* Is the query cache enabled?
239
public String getQueryCacheEnabled();
241
* Enable or disable the query cache
243
public void setQueryCacheEnabled(String enabled);
245
* Is the second-level cache enabled?
247
public String getSecondLevelCacheEnabled();
249
* Enable or disable the second-level cache
251
public void setSecondLevelCacheEnabled(String enabled);
253
* Get the cache region prefix
255
public String getCacheRegionPrefix();
257
* Set the cache region prefix
259
public void setCacheRegionPrefix(String prefix);
261
* Is the second-level cache optimized for miminal puts?
263
public String getMinimalPutsEnabled();
265
* Enable or disable optimization of second-level cache
268
public void setMinimalPutsEnabled(String enabled);
270
* Are SQL comments enabled?
272
public String getCommentsEnabled();
274
* Enable or disable the inclusion of comments in
277
public void setCommentsEnabled(String enabled);
279
* Is JDBC batch update for versioned entities enabled?
281
public String getBatchVersionedDataEnabled();
283
* Enable or disable the use of batch updates for
286
public void setBatchVersionedDataEnabled(String enabled);
289
* Enable automatic flushing of the Session when JTA transaction ends.
291
public void setFlushBeforeCompletionEnabled(String enabled);
293
* Is automatic Session flusing enabled?
295
public String getFlushBeforeCompletionEnabled();
298
* Enable automatic closing of Session when JTA transaction ends.
300
public void setAutoCloseSessionEnabled(String enabled);
302
* Is automatic Session closing enabled?
304
public String getAutoCloseSessionEnabled();
307
* Export the <tt>CREATE</tt> DDL to the database
308
* @throws HibernateException
310
public void createSchema() throws HibernateException;
312
* Export the <tt>DROP</tt> DDL to the database
313
* @throws HibernateException
315
public void dropSchema() throws HibernateException;
319
* Create the <tt>SessionFactory</tt> and bind to the jndi name on startup
321
public void start() throws HibernateException;
323
* Unbind the <tt>SessionFactory</tt> or stub from JNDI