Page 1 of 1

About Question enthuware.ocpjp.ii.v11.2.3432 :

Posted: Mon Jul 08, 2019 10:41 pm
by imrankhurshid
in explantion on first option its mentioned that Since database package is not used by any other module, there is no need to export it from the service module. but in question it stats Classes in the service package use classes from the dto and the database package .so databse package is used by service module

Re: About Question enthuware.ocpjp.ii.v11.2.3432 :

Posted: Mon Jul 08, 2019 11:11 pm
by admin
Yes, database package is used by the service module. But database is not a separate module. It is part of the service module itself and so, it can be accessed by other classes of the service module. There is no need to export database package from the service module because it is not used by any other module.

Re: About Question enthuware.ocpjp.ii.v11.2.3432 :

Posted: Tue Aug 06, 2019 10:33 am
by sir_Anduin@yahoo.de
My idea was to make databse an automatic module. That way it can be required by the service module. This is why I chekced answer 3.
What is wrong with my attempt?

Re: About Question enthuware.ocpjp.ii.v11.2.3432 :

Posted: Tue Aug 06, 2019 11:02 am
by admin
Option 3 is incorrect because that would create 4 modules. The problem statement wants you to do it in three modules.

Re: About Question enthuware.ocpjp.ii.v11.2.3432 :

Posted: Thu Aug 22, 2019 11:03 am
by sir_Anduin@yahoo.de
module acme.provisioning.service {  
  exports com.acme.provisioning.service;  
  requires acme.provisioning.dto; }

why is the requires without "com."

Re: About Question enthuware.ocpjp.ii.v11.2.3432 :

Posted: Thu Aug 22, 2019 11:15 am
by admin
No reason. One can name the module anything. It doesn't have to start with com.

Re: About Question enthuware.ocpjp.ii.v11.2.3432 :

Posted: Mon Apr 12, 2021 10:54 pm
by alfredo.zuloaga
You said . But database is not a separate module. It is part of the service module itself and so

How do determine that, with this sentence ?
Classes in the database package use classes from the dto package.

because if module-info of database is
exports com.acme.provisioning.database
requires "DTO"

this option works as well

module acme.provisioning.service{
exports com.acme.provisioning.service;
requires com.acme.provisioning.database;
requires acme.provisioning.dto;
}

but if is this also
exports com.acme.provisioning.database
requires "DTO" transitive

you can
module acme.provisioning.service{   
 exports com.acme.provisioning.service;    requires acme.provisioning.dto; }

Re: About Question enthuware.ocpjp.ii.v11.2.3432 :

Posted: Mon Apr 12, 2021 11:21 pm
by admin
alfredo.zuloaga wrote:
Mon Apr 12, 2021 10:54 pm
You said . But database is not a separate module. It is part of the service module itself and so

How do determine that, with this sentence ?
Classes in the database package use classes from the dto package.
You determine that from the problem statement, which says, "You want to modularize the application into three modules - client, service, and dto."
Therefore, it is clear that no module is expected for database classes.

Re: About Question enthuware.ocpjp.ii.v11.2.3432 :

Posted: Wed Aug 25, 2021 7:51 am
by vts.vts
admin wrote:
Mon Apr 12, 2021 11:21 pm
You determine that from the problem statement, which says, "You want to modularize the application into three modules - client, service, and dto."
Therefore, it is clear that no module is expected for database classes.
I'm not the OP, but it's still not clear to me. How do I determine that the database package is in the service module and not in client or dto module?
It makes sense to put it to the service module because the service package is the only one using the database package, but it could be in any module.

Re: About Question enthuware.ocpjp.ii.v11.2.3432 :

Posted: Wed Aug 25, 2021 8:11 am
by admin
No, database classes cannot be in the client module because service classes don't depend on client, right? client classes depend on service.

Yes, database classes can be in the dto module but that possibility is not there among any of the options. So, only option 2 can be right.

Re: About Question enthuware.ocpjp.ii.v11.2.3432 :

Posted: Sun Oct 03, 2021 3:34 pm
by samba2
Was on the same path as user vts.vts. Would the exam misguide you similarly ?

Re: About Question enthuware.ocpjp.ii.v11.2.3432 :

Posted: Sun Oct 03, 2021 9:26 pm
by admin
There is no misguiding in this question. Please see the response above. Which part do you think is misguiding, please tell so that we can provide more clarification and improve the question.

Re: About Question enthuware.ocpjp.ii.v11.2.3432 :

Posted: Thu Oct 26, 2023 7:53 am
by AlienFS
I didn't pick your answer, because I expected the correct answer to have "requires com.acme.provisioning.dto". So I thought it was a trick question since you wrote "requires acme.provisioning.dto;".

Re: About Question enthuware.ocpjp.ii.v11.2.3432 :

Posted: Thu Oct 26, 2023 12:04 pm
by admin
You are right. com. is missing. Fixed.
thank you for your feedback!