[Performance Tuning] - Trying to increase performance, doesn't seem to be CPU or DB
by jamicide
Hello
I am trying to maximize the performance/thoroughput of my JBossAS.
Currently my server processes approximately 60 external requests per second. At this rate CPU usage is at ~50% usage, memory is at ~35% and the load on the DB machine is similar.
I have tried fiddling with various parameters of the system, namely the JMS threadpool size (all requests are placed on the JMS queue) and the JMS connection pool size. The modifications I make only seem to have a minor effect on the system's performance, and even setting the pool settings to very high values doesn't result in a much different operation. The system loads never goes higher than what I mentioned above.
Are there settings which I could change in addition (or in place of) those I mentioned to get the desired results? Is there potentially another bottleneck (local secondary storage, network, etc.) that could cause this?
Any help is greatly appreciated.
Server specs:
jboss-4.2.2.GA
Dual-Quad Core System, 4G ram
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4166292#4166292
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4166292
17 years, 9 months
[Beginners Corner] - set a rolled-back txn back to active
by gan.gary
have Java/HIbernate apps. When run in Eclipse/JAR file with this, it works fine.
public void saveToDatabase() throws Exception
| {
| Transaction txReporting = null;
| try{
| txReporting = sesReporting.beginTransaction();
| ...
| txReporting.commit();
| } catch (Exception e) {
| if (txReporting != null) {
| // Something went wrong; discard all partial changes
| txReporting.rollback();
| // nested try-catch loop to catch all errors
| try{
| // for logging purpose
| txReporting = sesReporting.beginTransaction();
| ...
| txReporting.commit();
| } catch (Exception ex) {
| throw ex;
| }
| }
| throw e;
| }
| }
But when I throw this into JBoss, I hit:
anonymous wrote : 2008-07-23 17:46:04,291 DEBUG [org.hibernate.util.JDBCExceptionReporter] Cannot open connection [???]
| org.jboss.util.NestedSQLException: Transaction is not active: tx=TransactionImple < ac, BasicAction: acc550a:c94:4886fda0:41 status: ActionStatus.ABORT_ONLY >; - nested throwable: (javax.resource.ResourceException: Transaction is not active: tx=TransactionImple < ac, BasicAction: acc550a:c94:4886fda0:41 status: ActionStatus.ABORT_ONLY >)
| ...
| Caused by: javax.resource.ResourceException: Transaction is not active: tx=TransactionImple < ac, BasicAction: acc550a:c94:4886fda0:41 status: ActionStatus.ABORT_ONLY >
| at org.jboss.resource.connectionmanager.TxConnectionManager.getManagedConnection(TxConnectionManager.java:304)
| at org.jboss.resource.connectionmanager.BaseConnectionManager2.allocateConnection(BaseConnectionManager2.java:396)
| at org.jboss.resource.connectionmanager.BaseConnectionManager2$ConnectionManagerProxy.allocateConnection(BaseConnectionManager2.java:842)
| at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:88)
| ... 53 more
| 2008-07-23 17:46:04,307 WARN [org.hibernate.util.JDBCExceptionReporter] SQL Error: 0, SQLState: null
| 2008-07-23 17:46:04,307 ERROR [org.hibernate.util.JDBCExceptionReporter] Transaction is not active: tx=TransactionImple < ac, BasicAction: acc550a:c94:4886fda0:41 status: ActionStatus.ABORT_ONLY >; - nested throwable: (javax.resource.ResourceException: Transaction is not active: tx=TransactionImple < ac, BasicAction: acc550a:c94:4886fda0:41 status: ActionStatus.ABORT_ONLY >)
| 2008-07-23 17:46:04,307 ERROR [STDERR] org.hibernate.exception.GenericJDBCException: Cannot open connection
anyone?
is this called "multiple one-phase" : http://wiki.jboss.org/wiki/Multiple1PC ?
I thought using 2 separate transactions is required MSDTC (change <local-tx-datasource> to <xa-datasource>. )?
when i do this in between code:
txReporting.rollback();
| if(txReporting.wasRolledBack())
| System.out.printf("txReporting.wasRolledBack \n");
| if(txReporting.isActive())
| System.out.printf("txReporting.isActive \n");
It never show "txReporting.isActive" after txn.rolledback. But there's no option/method to set it to active?
anyone?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4166281#4166281
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4166281
17 years, 9 months