Process Model Delta - java

I am using Eclipse IDE.
Sometimes, after I make some alterations to the code and try to run, I get "'Process Model Delta' has encountered a problem" error. If I try to run again, sometimes it runs (without giving any error again) or again gives the error and I have to restart Eclipse.
I am not pasting any piece of code here, because the code was perfectly fine in many situations when this error occurred.
Can anybody let me know the reason why this error occurs or what is the meaning of this error?
Thanks in advance!

I assume you're actually debug. It that's the case, the cause is in one of your breakpoints. See if it runs fine with breakpoints disabled. If that helps, try Debug view menu Java > Show System Threads.
Cheers,
Max

Related

Most debugging options greyed out in Eclipse

I've ran into a nasty NullPointerException in my code, it's nothing too bad, I should be able to fix it quite easily with some breakpoints and "Step Into".
The only problem is, almost all of the debugging options are greyed out for me in Eclipse, I've used them before and they worked fine, but now when I need them the most, they're not working!
I looked on the internet and tried some things like running eclipse with -clean, restarting, opening debug perspective, making sure skip breakpoints were disabled.. None of which worked unfortunately.
I'm guessing it's just me missing something really obvious but any help fixing this would be appreciated.
Well, It says "terminated", so your program must have ended execution.
That's why all the buttons are greyed out.
The exit value is 1, which indicates abnormal end to an execution of a program (program aborted without reaching the end). Try placing breakpoints earlier in the code to find out where it stops executing.
Your application already terminated. The debugging options are only enabled, when an actual debug application is running.

What does "Hot Swap error" with IntelliJ (in Java) mean?

I have no idea what a hot swap is and for the life of me cannot construct a google search that will find what it means in the context of my program. I was editing my class, the same way I do all the time, and when I went to run it I all of a sudden got a
Hot Swap failed: myClassName: schema not implemented
error.
Can anyone explain this to me in Layman's terms?
You are attempting to change your source code while the program (or IntelliJ's debugger) is still running. This is what the HotSwap feature does according to IntelliJ's KB.
Please make sure your program and/or debugger is stopped before re-launching the program and the issue should be resolved.

Why isn't PlayFramework recompiling my edited .java files properly?

I have been working with the Play! Framework for a few weeks now, and am really enjoying it. Occasionally I have an issue come up which is frustrating me. It starts when I encounter a compile error. I refresh, and see the (excellent) Play! error message. Here's a simple example.
I go to the appropriate file, fix the error, and reload the page. Then I get this compiler error:
Strangely, it shows the updated source code, with the bug fix, but it is throwing the same compiler error from the previous message. If I restart the Play! server, then everything compiles and I can go on as expected, but of course one of the great things about Play! is being able to edit .java source files and see those changes right away in the browser.
Would really appreciate a tip from anyone who's bumped into this before, or has a clue what is causing it! Thanks so much! I am running OSX 10.6.
EDIT
I have also tried manually deleting the tmp/ directory, where the .class files are stored. This does not help, and I get the same behavior, where the edited source code appears, but the old compiler error is still dsiplayed.
My best stab at this is that your clock is screwed up. Do you use time synchronization? Keep a terminal open running:
while true; do sleep 1; date; done
and check whether there is a correlation with clock changes and this behaviour.
FWIW, I've never witnessed this (also on MacOS 10.6)

Android SDK not compiling apps correctly

It seems that the Android SDK doesn't compile my android app correctly. After building an app, I sometimes get seemingly random exceptions. The error goes away if I comment out the offending code, rebuild, uncomment the code, then rebuild again.
For instance, this code gave me a NullPointerException:
playButton.setOnClickListener(new OnClickListener() {
public void onClick(View v) {
startActivityForResult(settings, PLAY_GAME);
}
});
There is nothing wrong this code! Yet adb logcat tells me it's the cause of an exception.
Commenting out this code, rebuilding, uncommenting and rebuilding, makes the error go away.
What is going on?
This is making developing for android particularly frustrating.
Update: As I pointed out before, these are seemingly random errors that go away once I uncomment/recompile/comment/recompile. So I can't reproduce the stacktrace. It was a NullPointerException if I remember correctly.
However, if it is indeed buggy programming, why is the app running fine now w/o ANY errors at all?
Whenever I make a significant change to the app (add a new resource, a new class, function, etc), old code that was working fine breaks. Why?
Update: Seriously guys, lay off on the hate. I feel like a stumbled on a Atheists vs Christian debate. Sorry to have insunated that android was at fault. Started a new question with the latest errors:
App Ran Fine, Now Breaking for Seemingly Unknown Reasons
Commenting out this code, rebuilding, uncommenting and rebuilding, makes the error go away.
This might seem to you like a bug in Android, but I suspect that the real problem is a threading / synchronization related bug in your code. For instance, playButton may be being used before it is initialized.
But we cannot really help you unless you show us the stack trace and identify the line(s) of code where the exception was thrown.
However, if it is indeed buggy programming, why is the app running fine now w/o ANY errors at all?
See above: it is most likely because you have a threading / synchronization issue. You need to be aware that different parts of an application with a GUI will run in different threads ... even if you didn't explicitly create those threads. There are rules you have to follow. If you don't follow those rules, bad things happen ... like exceptions that sometimes happen and sometimes don't happen, depending on which way the wind is blowing.
Could be that your PLAY_GAME activity is returning without a result, e.g., if you press the back button & it just stops without calling setResult().
No, as noted in several other places, sometimes the source and the bin get out of sync. I've noticed numerous times, specially when making changes to XML. The solution, for commandline users, is to remove the bin directory, and re-compile. Problem goes away.

Error whenever a java applet is loaded

For the past few months or so, I've been getting an error whenever I attempt to use a java applet.
I'm getting this error on every browser I use, and I get the error occasionally in linux, too.
The java applet loads for roughly 5 seconds or so, then it stops and I get two error messages, stating that an exception occurred (java.io.EOFException).
This seems to happen regardless of what website I'm using. Going to the website shows I'm running java 6 update 20, and I get no error. Googling the error turns up nothing useful - I'm not a java developer, so most of the results don't apply to me at all.
My question is this. What's causing this error, and what can I do to fix whatever issue is causing it?
Nevermind. I looked further, turns out I had to delete the trusted.certs file under ~/Application Data/Sun/Java/Deployment/Security (~/.java/deployment/security in linux). That solved the problem.

Categories