• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

NX: Home Contractor Assignment

 
Jamie Orme
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All
Regarding the home contractor assignment -
I have read some posts that appear to contradict each other. Basically, do we need to implement the create()/delete() methods from the DB interface? From looking at the spec from it appears that we dont have to, but I just want to be certain! Does anyone know of anyone who has passed without doing so?
Many Thanks
Jamie
 
Ta Ri Ki Sun
Ranch Hand
Posts: 442
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
dont know anyone who's already passed but I'll be submitting my assignment in the next few days, well probably after the weekend, and it will not implement those methods, I'll keep you guys posted with results but I cant possibly imagine failing for that reason, who knows tho, perhaps the assessor feels differently, I'm still sticking to that decision tho, and I've noted it in my choices document
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is still a question that is up in the air. In my Beta version which was the Home Contractor assignment, I implemented the methods, even though the client will never call those methods.
Mark
 
Jeff Wisard
Ranch Hand
Posts: 89
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How did you implement those methods? It seems to me that you need to lock the entire database to do a create or delete to ensure that another thread is not modifiying the record your deleting or trying to create a record at the same time as this thread.
My take on that is that the DBAccess interface provides a lockRecord method...which implies that it should only lock a single record. There is no lockDatabase method on the interface. I therefore made the assumption that locking the entire database is not a requirement of the contractors problem. Which then implies that creating or deleting records is not yet supported by the requirements...that is the physical requirements of the DBAccess interface.
Did you implement a way to lock the entire database? If so, how? Or am I off base here?
 
Max Habibi
town drunk
( and author)
Sheriff
Posts: 4118
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
IMO, you don't need to worry it. Take a literal interpretation of the requirements, and you'll be ok.
M
 
Thomas Kijftenbelt
Ranch Hand
Posts: 73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
my create / delete methods just throw an exception:

in this way the methods are implemented
greetings,
TK
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic