• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

B&S: Passed 373/400

 
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all, just did a random check and surprised to see that my assignment had been graded within less than a week. Here's my break down of score:

General Considerations (maximum = 100): 90
Documentation (maximum = 70): 70
O-O Design (maximum = 30): 30
GUI (maximum = 40): 40
Locking (maximum = 80): 80
Data store (maximum = 40): 40
Network server (maximum = 40): 23

Lost marks for network server:
I used a socket solution using ServerSocket and defined a custom protocol, wonder what wrong, guess using RMI is a safer bet.

Locking:
For record locking, i used a lock for each record, thanks to the hand-over-hand locking technique in Andrew's book.

This assignment took me a total of 6+ months to complete, working on this after work really drains me, but the process of completing this assignment is a rewarding one!

Thanks to all the help and advices offered in this forum.
[ June 17, 2008: Message edited by: Zeng Wei Chu ]
 
Bartender
Posts: 2292
3
Eclipse IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There you go man, congrats!
 
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Great score. Congrats
 
Author
Posts: 587
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
 
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
nicely done!

Can you briefly describe your gui too? It would be nice to know what route to choose. 40 out of 40 is very rare.
 
Ranch Hand
Posts: 10198
3
Mac PPC Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Congrats!
 
Zeng Wei Chu
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks all, here are some information regarding my GUI design:

Use MVC Design Pattern:
There are 2 GUIs to be prepared (Client and Server) and for both I have adopted the MVC design pattern. Although it seems to be a bit of overkill for the server GUI, which is actually quite simple, I have chosen to use MVC also for the sake of consistency.

Search Function
I had a search panel on the top of my GUI just below the menu bar. I used comboboxes for both names & locations. In between the comboboxes I have two radio buttons which allows the user to chose the AND or OR condition. I guess this is pretty much the same as what most would implement. In addition, I have a menu item to allow the user to manually sync the combo boxes with the database.

GUI Testing
GUI testing can be time consuming as there are many things to look out for:
1) Do you allow user to operate on your GUI without the need to use the mouse? Do add key mnenomics to your GUI and try to perform actions on your GUI totally without your mouse.

2) Add tooltip to buttons. Try to keep button names short and use tooltip to reveal more information to the user.

3) Use layouts carefully and test maximizing on your frames and dialogs. Make sure that after maximizing your GUI components are still organized to the way you want. In addition, allocate sufficient width and height to your frames and dialogs. Test running your GUI in different platforms if possible.

4) Think of yourself as the end-user, and how would you like to operate the GUI so that it best fulfill your job purposes. For my booking of contractor, i adopted a step by step approach to guide the user through the booking process.

5) Remember to thread processes which can take potentially long time to finish execution. The booking process is one example, since user had to wait for record to be unlocked if it happened to be locked by another user. This is to ensure that the GUI does not "freeze".

User Guide
I provided offline user guide in the form of html files.


Hope these information helps! I ended spending more time on the GUI module than anything else.
 
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Congratulations!
 
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

There are 2 GUIs to be prepared (Client and Server)...


A GUI for the server? That had never crossed my mind!

I'd always assumed that the a non-interactive console application for the server would be adequate...

Matthew
 
Ranch Hand
Posts: 54
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Congratulations! zengwei.

I have a question about the search function. How did you define your search?

Like "Fred", did you return all matches start with "Fred", such as "Fred" and "Freddy"?

Did you return records with "Fred" in middle, e.g. "Afred"?

How about case sensitive?

Thanks!

In my assignment, it says:

public void delete(int recNo) throws RecordNotFoundException;
// Returns an array of record numbers that match the specified
// criteria. Field n in the database file is described by
// criteria[n]. A null value in criteria[n] matches any field
// value. A non-null value in criteria[n] matches any field
// value that begins with criteria[n]. (For example, "Fred"
// matches "Fred" or "Freddy".)
[ June 26, 2008: Message edited by: Nova Chen ]
 
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello Zeng

Congrats...


There are 2 GUIs to be prepared (Client and Server)...



Please explain this in greater detail.
Regards

Anirban
SCJP(1.4)
[ June 27, 2008: Message edited by: Anirban Das Gupta ]
 
Zeng Wei Chu
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all, I indicated that two GUIs need to be prepared because its one of my requirements to provide a GUI for the user entering of configuration. Since there is server configuration to be saved, I provided a GUI solely for the entering of server configuration.

Sorry if i confused you all.

I have a question about the search function. How did you define your search?

Like "Fred", did you return all matches start with "Fred", such as "Fred" and "Freddy"?

Did you return records with "Fred" in middle, e.g. "Afred"?

How about case sensitive?



Nova, my database find method returns all matches which starts with the specified criteria, for e.g., "Fred" return all matches start with "Fred", such as "Fred" and "Freddy. I do not return matches in between. It is better to follow the description of the interface methods closely, the keyword is starts with.

My find method is not case sensitive.

Regards,
Zegwei
 
Ranch Hand
Posts: 3389
Mac MySQL Database Tomcat Server
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Congratulations Zeng Wei Chu
 
Jimmy Chen
Ranch Hand
Posts: 54
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks very much!

Another question . How do you deal with RandomAccessFile? Do you just use one RAF for all access or created one RAF in each method?

like discussed in this post
[ June 27, 2008: Message edited by: Nova Chen ]
 
Zeng Wei Chu
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Yuchen,

I used a single static RAF as it seems logical to have one RAF to represent the single database as a shared resource. Hence multiple users will be accessing a single database (RAF) whereby concurrent access to the database had to be controlled.

Regards,
Zengwei
 
Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Nova Chen:
How about case sensitive?



The documentation don't imply anything about this issue. I guess it's a matter of documenting your choice here.
 
Jimmy Chen
Ranch Hand
Posts: 54
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Zeng Wei Chu:
Hi Yuchen,

I used a single static RAF as it seems logical to have one RAF to represent the single database as a shared resource. Hence multiple users will be accessing a single database (RAF) whereby concurrent access to the database had to be controlled.

Regards,
Zengwei



Thanks a lot!
 
Jimmy Chen
Ranch Hand
Posts: 54
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Jo�o Batista:


The documentation don't imply anything about this issue. I guess it's a matter of documenting your choice here.



got it! thanks!
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic