Help coderanch get a
new server
by contributing to the fundraiser

Brian Knight

Greenhorn
+ Follow
since Jun 02, 2003
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Brian Knight

Hi Guys,

I have an swing application that uses JDO as it's persistence layer. The application has a centralized server and the clients run at remote locations over a 512mbs ADSL line. As you have probabley guessed we are experiencing performance related problems which relate to data retrieval and the number of sql statements that are being executed.

One solution I am considering is to use the value object pattern to access the data, and to remove all database access from the client. Is this a good idea? I have done some tests and the performance increase is huge, but I just want to know what other peoples opinions are on using this method. I know this method has other advantages as well, beyond the performance gain, so it is quite attractive.

The other solution (which is going to happen anyway, as our JDO vendor no longer supports the product) is to move from JDO to Hibernate, but I am not sure that this alone will solve all of the performance problems. Again, anyone have experience in this field.

Any help would be greatly appreciated as I would hate to go down the wrong track only to find I have made the wrong decision!

Regards,
Brian
17 years ago
When you synchronize on an object, all other methods that are not marked as synchronized will still be able to run, however any threads trying to run synchronized methods will have to wait for the lock to be released. Synchronizing on an object doesn't lock the object in the way you are thinking. It means that the currently executing thread obtains that objects lock and other threads that need to execute the code have to wait for that lock to be released, before they can try to obtain the lock. If the code is not synchronized, the threads don't need to obtain the lock so the code executes
Hi,

Firstly my apologies if this is the incorrect forum for this post. I have an application that mantains a reference to a remote object. The remote object implements the Unreferenced interface and performs clean up when the client no longer references it. As a result when the client exits the application I set the reference to my remote object to null, and call System.gc(), which causes the Unreferenced method to be called on the remote object. This works fine if I set the reference to null from within windowClosing(), but if I put the same code in a shutdownhook, then it does not work. Is this because System.gc() will not run from within the shutdown hook? Is there any way to force this behaviour?

Thanks
Brian
Hi Guys,

I need to write a couple of applications that will run on a device running Pocket PC 2002/2003. I have no experience writing applications for handhelds, and was wondering if anyone could point me to a tutorial, or some code samples etc. Also does the code written for handhelds differ to that written for cellphones? I would assume this to be the case? Do you still use MIDlets? Any help would be greatly appreciated.

Thanks
Brian
20 years ago
Does the text on your button actually have a 'b' in it? Setting the mnemonic to enter won't work, as you should rather register a keyboard action if this is the key you wish to use, or look at setDefaultCapable() on JButton (Key stroke would then depend on your current look and feel). If you wish to use mnemonics the char you set as the mnemonic should be contained in the text of you button for it to work properly (and for it to make sense to the user).
20 years ago
If all you are doing is trying to change what is displayed on the frame, you are doing it in the wrong way. You should rather create a bunch of panels that contain the screen layouts that you want and use the CardLayout on your frame to change what is displayed.
What you are actually doing currently, is creating a brand new frame when the user clicks the button, instead of just changing what is displayed on the current frame.
20 years ago
A cell renderer is used to render the cell in the table, i.e. this is what actually paints what you see in the table.
The cell editor on the other hand is used to actually edit the contents of the cell. So you could write a cell editor that knows how to edit the the value in a particular cell and then a painter that nows how to paint it, maybe with an icon or something. This enables you to write editors and painters for you own custom classes so that they can be displayed in the table etc.
Hope that helps
20 years ago
Hi,
Does anyone out there know how to stop a jtree showing it's leaf nodes. I want to create a menu system, similar to a file explorer, but I don't want the tree to display the child nodes, instead I want these to be displayed in a seperate panel.
I have done some searching in the code, and have not been able to come up with anything so any help would be appreciated.
Thanks in advance
Brian
20 years ago
Hi Guys,
I have a tabbed pane, which is not focusable, and none of the components on the panels that are on the tabbed pane are focusable. My problem is that now none of the mnemonics on the tabs work, does anyone know a solution to this? I
Thanks
Brian
20 years ago
Hi Guys,
We are considering using Jasper Reports for our current project, and was wondering if any of you know any good visual editors for Jasper. I need something that an end user would be able to work with.
I have looked at iReport and Jasper Design, and although both are really impressive, they still seem a bit buggy.
Any help would be greatly appreciated.
Brian
Hi Richard,
Thanks for the advice. I want to be a software developer the reason I added that is that most of the postings I have seen on jobserve etc require investment banking experience
Thanks again
Brian
21 years ago
Hi Guys,
I am a Sun Certified Java Developer with 4 years commercial Java development experience.
I am currently living in the UK and am really struggling to find work, and I was wondering if anyone could tell me what salary I should ask for when asked.
I don't have a degree in IT (only business) and I have no investment banking experience. I would really like to know an asking rate for both permanent and contract.
Thanks in advance
Brian
21 years ago
Hi Guys,
I keep getting the following error try to access entity beans in jboss.
"IllegalStateException: removing bean lock and it has tx set!"

I am using a postgres database and the error occurs whenever I call a method i.e. getName() on my entity bean. It happens with both cmp and bmp beans. I am using jboss 3.2.2 with tomcat.
Any help would really be appreciated
Thanks
Brian
21 years ago