This forum is now a read-only archive. All commenting, posting, registration services have been turned off. Those needing community support and/or wanting to ask questions should refer to the Tag/Forum map, and to http://spring.io/questions for a curated list of stackoverflow tags that Pivotal engineers, and the community, monitor.

Memory Issue

Dec 10th, 2009, 02:32 AM

Hello guys,

Im having this weird problem. We've developed a system that is behaving really awkwardly.
On our local it runs like a precious gem (it runs fine), but when we upload it in a server (my manager told me it's a very powerful linux server),
it has a memory issue. First minute after successfully starting tomcat (5.5), we can test the system, but after sometimes, it hang up.

Im just wondering why this is the case. We have developed 3 projects previously and all are running fine on the same server whenever uploaded.
The only differences I can think of (the only difference apparent to me), is the transactional part of my applicationContext.xml.

As you can see, in my previous projects, when I declaritively make my services transactional, I will only specify the package name, and all
transactional services are stored there. In this project, our lead asked us to group services based on logic, so it turned out a lot of packages and classes.
So when i declaratively make my services transactional, i had a lot <aop:advisor>. Just wanna confirm if this really is the one causing the memory issue?
But it's working fine on our local machine (VISTA). Sorry if the question seems stupid but im running out of idea.

<!--=================================================================
JOTM Transaction Manager.
A TransactionManager is necessary for suspending and resuming
transactions, as this not supported by the UserTransaction interface.
==================================================================-->
<bean id="jotmTransactionManager" class="org.objectweb.jotm.Current" />

If you need to use a load of advisors you might want to consider using @Transactional instead.

Troubleshooting these kind of issues is kind of tricky, in production in general there is more load, there is more data, there is a complexer topology. So comparing your local environment with production is in general not a good indicator.

If you need to use a load of advisors you might want to consider using @Transactional instead.

Troubleshooting these kind of issues is kind of tricky, in production in general there is more load, there is more data, there is a complexer topology. So comparing your local environment with production is in general not a good indicator.

@ur first question: as far as our network/system admin is telling me, yes it is. I really have no direct access to the server, just uploading it remotely via vpn and ftp. but ill recheck it for sure. just want to know if my messy aop:advisor config is the culprit or has something to do with it at least, so that i can fix it as early as now. but im having a hard time debugging it since i cant replicate this same issue on my local machine.

@ur second point: i guess you are right about the server having more load. but im just wondering why my past projects with similar configuration (minus this aop:advisor) run pretty well. ill be rechecking the logs and stacktrace again. thanks so much.