Win a copy of Five Lines of Code this week in the OO, Patterns, UML and Refactoring forum!

mohammad shadab

Ranch Hand
+ Follow
since Jul 09, 2013
mohammad likes ...
Eclipse IDE Oracle
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by mohammad shadab

mohammad shadab wrote:Batch entry 0 update service  set test_primary_claimid = null,test_submit_status=case when test_submit_status ilike 'k' then 'g' else service_submit_status  end, test_dualins_status=-1 from xyz where test_id=7777 and x7777=888 was aborted.  Call getNextException to see the cause.---error is here

If yes , Does it leverages automatically or we need to specify any thing explicitly ?
1 year ago
I do understand  tomcat connection pooling uses flyweight framework? is that valid?
2 years ago
Just think will program will execute on its best .
same output can be produced in 10 minutes by writing dirty code . And same output can be produced in 5 minutes using good code.

consider your memory consumption
consider time it takes to execute
consider any blackhole which can make your program to run for long time or for infinite time (example infinite loops)
know number of user will use program, let say you have 100 MB mory to run program and your program reads some data thru buffers and yiu set buffer size 5 MB so as soon as 20 user start using same program (20*5=100) you will run out of memory and program will halt, so know numver of user and custimize your things.
consider if you are i tracting with database , database has optimized queries.
consider your program does not run to fetch un necessary data from db.
consider you database not loaded with hell number of queries, try to group quries.
consider you do use connevtion pooling for db .

If you can tell which type of program you are talking about  then there is alot to speak.
2 years ago
Not sure you are using correct terms to explain your requirement, do you want to build an application which can be consumed by other apps to do money trabsactions or you want to build an app which can allow payments like how you can make payment on flipcart?
2 years ago
Why do you need path? why do you need client file path on server?
you submit your request you will be having file content on server along with file name, now its upto you to what path you want to save it.
any suggestion , i am feeling discussion os going away.
2 years ago
Hello all,

I want to make an ajax call after receive 10 seconds to see the session status on a page , But as i know on every call to server session will be refreshed and again tome out will be reset , What is the best policy to find remaining session's time without resetting it through ajax.

Is there any way to exclude a URL which should not reset session, And this url just responsible to get session information through ajax?

2 years ago
Hello ,

I am aware in java there is a method size limit 64k , I want to know is there any workaround for this problem . My JSP does not contain any static include . I am running with tomcat 8.5 version . It does well on lower versions of Tomcat.
I have tried changing web.xml available inside tomcat's conf directory , Following are the tags i havce used. Did java 8 change any thing in JVM or Tomcat Container got changed  any thing while translating JSP ? Because same code runs well with java 7 along with Tomcat 7.
3 years ago
Basically i am using dbcp connection pooling , And in order to see the statistics of my app i want to know following parameters any point from the dbcp pool :-

1) Number of active connections
2) number of idle connections

Any idea will be great.


I am trying to get the number of active connections using BasicDataSource object like following

Using above code , I am expecting following output

But always i do get zero as NumActive and NumIdle. Please suggest how can we get these .


I am using tomcat's DBCP pool setting , My resource tag in context file is as below

When i get the new connection i receive the object of javax.sql.DataSource , I want to see the number of active,idle,total pool size from the connection at some point .
I do not find any method of  javax.sql.DataSource class which can return me these things. Please suggest if any way to find these trhu program.


My tomcat is getting shutdown on its own without telling any reason or showing nay error message , I have researched and found there could be two reason
1) Memory getting exhausted (out of memory problem)  , to identify this i am using java settings to give me heap dump whenever this error occurs.
2) Some library is calling System.exit - I am not able to trace this call.

Please let me know if we can find out the class calling System.exit?

Thank You.
3 years ago