Em Aiy

Ranch Hand
+ Follow
since May 11, 2006
Merit badge: grant badges
For More
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 Em Aiy

We recently upgraded from Weblogic 10 to Weblogic 12 and in that process, we upgraded few libraries. earlier, I was facing following error

After little bit of digging, I figure out that the error is due to old jersey.contribs version. Which then i upgraded from version 1.12 to 1.16 and now i am facing following error

Can someone suggest what to do ?

I am using maven to build, jersey for webservices and on Weblogic 12>
10 years ago
I have a webservice which is accepting a POST method with XML. It is working fine then at some random occasion, it fails to communicate to the server throwing IOException with message `The target server failed to respond`. The subsequent calls work fine.

It happens mostly, when i make some calls and then leave my application idle for like 10-15 min. the first call which i make after that returns this error.

I tried couple of things ...

I setup the retry handler like

but this retey never got called. (yes i am using right instanceof clause). While debugging this class never being called.

I even tried setting up but no use. Can someone suggest what can i do now?

Besides figuring out why i am getting exception, one of the important concern i have is why isn't the retryhandler working here?
Our app is currently logging using Log4j at application level. There are at least 8 EAR files, which are deployed when the server runs. All 8 EAR's are logging into File1.log file. I want to separate 1 ear. For example, 7 EAR files should conitnue logging in File1.log file however, the 8th one say ABCD.EAR should log into ABCD.LOG file.

I am able to log things based on class heirarchi. But there are number of classes, who doesn't fall under specific hierarchy but still fall under ABCD.EAR. How can i configure my log4j.xml based on EAR. My current settings for ABCD loggins are

this currently logging all log information for the classes falls under project.abcd, but there are other classes which are in abcd.ear but not being logged.
13 years ago
I am receiving a valid XML from server. lets say



Could someone guide me what would be possible reason? I am unable to debugg from where should i start.
the **nestedChild** is optional. so whenever JAXB parse the xml, it parse it in a way that if my xml doesn't have nestedChild, it shows 1 (empty object). if it has one nestedChild it shows 2, one valid and the other is empty. the transformation of valid child is okay, and obviously when the system try to convert empty object it throws exception ..

its jaxb v 1.3
13 years ago
thanks for your guidance. I wrote the following code which works fine. Sharing it for others

13 years ago
I have strings like

the first 8 characters of this string will remain same however the last letter could change for next release of the software. is there anyway that i can do pattern matching in JUnit rather putting a loop for assertEquals and going through all the possible combinations?

13 years ago
Thanks. Thats helpful.

But my question was not focused for "J2EE" patterns. My question is more focused towards "designing" a solution for a given problem. How to solve/present that?
I am expecting an interview call. The interviewer told me that they will be asking J2EE design questions. I am not sure what kind a these question would be. I would highly appreciate if someone can guide me to such questions - Or i would highly appreciate if someone can come up with some basic scenario and give the design tips for that .

Thanks in advance.
I need quick answer to a simple thing in AOP.

If i have a code deployed at client side and i have written new aspects, which i want in the client side software. do i have to "recompile" complete software with "original" code and new "AOP" code? (with aop compiler)?

I am trying to load a dll in java using the following code

The project is placed in and i have placed the dll on D:\. I then gave following VM argument in eclipse configuration

But when i run i get *UnsatisifiedLinkerError*. After googling a bit, I used

but again getting the same problem, could someone can help?

Paul Clapham wrote:Okay, so if I encountered the string "two billion" then that would be a number? Or are you only interested in numbers rendered as digits? Is there a limit on the number of digits or would a string of 87 digits be a number?

And what about i (the square root of minus one)? Or e (the root of the natural logarithms)? Or pi?

I have to detect only digits .. no the words which means a number.

one million - should not be detected
1,000,000 - should be detected
14 years ago

Garrett Rowe wrote:There's no built-in methods that do what you're asking for. There are a few algorithms I could think of to start. Obviously, there some ambiguity in the rules you've given thus far. would DEAD or FADE be parsed as a number or a w

actually i was about to write some code to to check whether some word is number or not so i thought better search around rather than reinventing the wheel.

I was confuse since the number like 88000 (is easy to detect) but then i would have to tackle these cases as well
88,000 (coma separated)
88,000.00 (proper decimal notation)

so thats why i was asking this question.

Talking about rules. I would say again lets say the rules are "basic". Like you are reading a newspaper and there are chances that few numebrs can be there in news and you have to detect those. now you can imagine what kind a number could ever be appear in news papers + "the hexadecimal notation"
14 years ago

fred rosenberger wrote:First, you have to define in English what determines if a set of characters is a number or not. What, EXACTLY is allowed, and what EXACTLY is NOT allowed. Just writing down 3 or 4 examples may be enough for your brain, but there are a LOT of implicit assumptions there.

Once you decide what the rules are, then you can start coding them. But until you define what the rules are, writing any code is pointless.

lets say the rules are numeric values in any format i.e 88,000 or 88000 or 88,000.00
the hexadecimal numbers
the floating point with "power" sign or suffix

I can write the code to iterate through every character of a word to determine what i want .. I wanted to ask is there any built in support in java? i.e some methods like isNumber()
14 years ago
I am parsing some sentence which would be having english sentences with numbers like 87,000 or 8.302 or 45.43e3 or 54BA3E

how can i check whether a word is english word or its a number?
14 years ago
what do you mean "pause". That is the biggest thing confusing me? do i need to write in file through some thread or should i write in same thread? is the pause method is InputStream specific .. or i have to do it ?
14 years ago