• 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

mock question : load-on-startup

 
Ranch Hand
Posts: 361
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Which statements are correct about load-on-startup elements

1) It must be an integer
2) It can be negative
3) If it is 0 (zero) it will be loaded at deployment time
4) Serveral servlets can have the same value for this element
 
Ranch Hand
Posts: 101
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
"Hi N,
1, 2, and 4 are true for sure.
About three,
I feel like I should leave that up to you!

Then again, it's about three...
It leads to 0
And I must concur
That it is true, or not true.

Although I would like to say it is true,
But for this fact, it is not true." (Wish it was true, but a lie with 4, to be not true)

Esam
 
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Check out the errata for HFSJ.

It clearly says that all non-negative nos qualify for the load on startup.
That includes 0.

and definetely 0 means load on deployment.

Nishant
 
Ranch Hand
Posts: 445
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I say all the above are correct answers. Even with load-on-startup with 0 will be loaded at deployment time. only negative integers and empty elements will be free to load by container at any time.
 
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I am confused about what the load on startup values indicate.

What do 0 and negative values indicate?

I remember setting load on startup value to -1 in websphere for loading a servlet at startup. Is it a websphere specific feature?

- Gouri
 
See ya later boys, I think I'm in love. Oh wait, she's just a tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic