• 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
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

NX: Home Contractor Assignment

 
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
 
Ranch Hand
Posts: 442
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
 
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
 
Ranch Hand
Posts: 89
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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?
 
town drunk
( and author)
Posts: 4118
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
 
Ranch Hand
Posts: 73
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi,
my create / delete methods just throw an exception:

in this way the methods are implemented
greetings,
TK
 
It is no measure of health to be well adjusted to a profoundly sick society. -Krishnamurti Tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic