Understanding Packages (3% Weighting) Flashcards

Given a scenario, analyze and explain the use cases and considerations when using managed vs unmanaged packages

1
Q

When using the package development model, which metadata changes do you need to track manually?

A) Changes to components not yet supported by source tracking

B) Only the changes made via the Setup UI

C) All metadata changes for the release

D) None. All the changes are tracked automatically

A

A) Changes to components not yet supported by source tracking

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is the key benefit of a scratch org?

A) It never expires

B) You can share its definition file with others

C) It’s an exact copy of your production org

D) Your source is automatically pushed to your VCS

A

B) You can share its definition file with others

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is the source of truth for package development?

A) Sandbox

B) Version control system

C) Production org

D) Salesforce DX project

A

B) Version control system

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What are the advantages of package development?

A) Ability to build development orgs directly from source

B) All code and customizations are intermingled in the source repo

C) Agile release models allow more frequent, independent releases

D) A and B

E) A and C

A

E) A and C

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

How does Salesforce DX define a package?

A) All the code in your production org

B) The metadata in your sandbox

C) A group of code and customizations you want to release together

D) The set of all changes that you want to deploy in a monthly release

A

C) A group of code and customizations you want to release together

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What use cases are ideal for shifting to a modular package-based approach?

A) You’re developing a distinct application

B) Your production org isn’t complex and you make minimal changes month over month

C) You want multiple development teams to work independently and deploy changes on their own release cycles

D) Your sales automation customizations can’t be tested independently of the rest of the org data

E) A and C

A

E) A and C

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

In what scenario do you need to be careful when creating projects?

A) When a project is a distinct application

B) When your team is ready to build and deliver in a separate release cycle

C) When your team works on multiple projects

D) When projects share metadata components

A

D) When projects share metadata components

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Who are unlocked packages primarily designed for?

A) Salesforce partners who want to publish on AppExchange

B) Customers who develop and deploy in-house business apps

C) Development teams who want to distribute Lightning components on App Exchange

D) A and C

A

B) Customers who develop and deploy in-house business apps

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is the Package Development model?

A) Using change sets to deploy updated metadata to the production org

B) Promoting the org as the source of truth

C) An iterative process where you organize your metadata into packages

D) A process that requires you to track all your metadata changes in a spreadsheet

A

C) An iterative process where you organize your metadata into packages

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

How do you deploy metadata in this new model to sandboxes for user acceptance testing?

A) Run force:source:push from the Salesforce CLI

B) Use the ANT Migration Tool to deploy the metadata

C) Install the package version in the org

D) Use change sets to move the metadata between orgs

E) B and D

A

C) Install the package version in the org

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Which of the following about unlocked packages is true?

A) They have a strict set of manageability rules

B) They can be installed in only scratch orgs and sandboxes

C) They provide flexibility to make changes directly in the org

D) They don’t support dependencies between packages

A

C) They provide flexibility to make changes directly in the org

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Use Dev Hub to:

A) Manage sandbox and production orgs through the command line

B) Create and manage your scratch orgs

C) Move configurations from your sandbox to your scratch org

D) Create a scratch org for another team member

A

B) Create and manage your scratch orgs

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

How do you list all available CLI commands

A) sfdx force:commands:view

B) sfdx force:list:help

C) sfdx force:doc:commands:list

D) sfdx force:doc:commands:view

E) sfdx force:commands:doc:display

A

C) sfdx force:doc:commands:list

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What’s the CLI command to create a new Apex class called NewClass in the force-app folder?

A) sfdx force:apex:class:create -n NewClass -d force-app/main/apex/classes

B) sfdx force:apex:class:create -n NewClass -d force-app/main/default/classes

C) sfdx force:apex:class:create -n NewClass -f force-app/main/default/apex

D) sfdx force:apex:class:create -n NewClass -f force-app/main/default/classes

A

B) sfdx force:apex:class:create -n NewClass -d force-app/main/default/classes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What’s the CLI command to create a new Aura component called ListView in the force-app folder?

A) sfdx force:lightning:component:create -n ListView -f force-app/main/default/aura

B) sfdx force:lightning:component:create -n ListView -d force-app/main/aura

C) sfdx force:lightning:component:create -n ListView -f force-app/main/default/lightning

D) sfdx force:lightning:component:create -n ListView -d force-app/main/default/aura

A

D) sfdx force:lightning:component:create -n ListView -d force-app/main/default/aura

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What’s the CLI command to synchronize changes in your local project to a scratch org with the alias MyScratchOrg?

A) sfdx force:org:push -a MyScratchOrg

B) sfdx force:source:push -a MyScratchOrg

C) sfdx force:source:push -u MyScratchOrg

D) sfdx force:source:sync -u MyScratchOrg

A

C) sfdx force:source:push -u MyScratchOrg

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

What’s the CLI command to assign a permission set called MyPermSet to provide access to objects in an org with the alias MyTP?

A) sfdx force:permset:assign -n MyPermSet

B) sfdx force:user:permset:assign -n MyPermSet -u MyTP

C) sfdx force:org:permset:assign -n MyPermSet -a MyTP

D) sfdx force:user:permset:assign -n MyPermSet -a MyTP

A

B) sfdx force:user:permset:assign -n MyPermSet -u MyTP

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

What are some benefits on Package Development? (8 answers will be provided ;)

A
  1. Follows best practices regarding the software development life cycle
  2. Encapsulates all the changes you are tracking between life cycle stages
  3. Makes it easier to accommodate new feature requests
  4. Provides an improved audit history
  5. Organizes source
  6. Promotes iterative and modular development
  7. Supports inter dependencies among unlocked packages
  8. Supports continuous integration and continuous delivery because the packaging CLI commands enable each step in the deployment pipeline to be fully automated
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

If you are migrating metadata from your org to an unlocked package, should you create your unlocked packages with or without a namespace (and why)?

A

WITHOUT a namespace. That way, when the metadata is moved from an unpackaged state to an unlocked package, the API name of the metadata elements doesn’t change

20
Q

When would you use the App-Based model to untangle your metadata into packages?

A

App-Based is used to identify metadata that represents an app. This approach is similar to creating a package for the “DreamHouse” app with the exception that the metadata already exists in your org

21
Q

When would you use the Customizations-based model to untangle your metadata into packages?

A

Organize unpackaged metadata for customizations and functionality changes in your product org, such as customizations to Sales Cloud, Service Cloud, or an AppExchange App

22
Q

When would you us the Shared Library model to untangle your metadata into packages?

A

When interdependencies exist, use a common Salesforce DX package to organize a set of Apex classes or commonly used custom objects. Other packages that you construct can depend on this common package.

23
Q

What are the steps to create an unmanaged package (as a starting point to move to package development) (6 steps are provided)?

A
  1. Select a small set of unpackaged, self-contained metadata from your prod org
  2. Create an unmanaged package to isolate the metadata you’ve identified
  3. Retrieve the source from your unmanaged package using force:mdapi:retrieve
  4. Set up a Salesforce DX project and a git repository to mange the package metadata.
  5. Convert the source to Salesforce DX format by running force:mdapi:convert
  6. Push the metadata to a scratch org using force:source:push
  7. Create an unlocked package using the –nonamespace flag
  8. Test and deploy the unlocked package
  9. Once the unlocked package has passed all CI runs and UAT on sandboxes, promote the package version
  10. Install the unlocked package in the production org.
24
Q

What should you do when you’re starting to organize your metadata into packages?

A) Put all your metadata into one unlocked package

B) Identify a set of related metadata that represents a functional unit

C) Convert your source to Salesforce DX format using force:source:convert

D) Create a package with a namespace to make sure API names don’t change

E) B and C

A

B) Identify a set of related metadata that represents a functional unit

25
Q

What can unlocked package depend on?

A) Another unlocked package

B) An AppExchange app

C) A change set created in the org

D) A and B

A

D) A and B

26
Q

If you are customizing Sales Cloud so that it shares some functionality with Service Cloud, which model would you select?

A) App-based and Shared Library

B) Customizations-based

C) Shared Library

D) App- based and Customizations-based

E) Customizations-based and Shared Library

A

E) Customizations-based and Shared Library

27
Q

What are unmanaged packages?

A

Unmanaged packages are typically used to distribute open-source projects or application templates to provide developers with the basic building blocks for an application. Once the components are installed from an unmanaged package, the components cna be edited in the organization they are installed in.

The developer who created and uploaded the unmanaged package has no control over the installed components, and can’t change or upgrade them.

28
Q

Can you use unmanaged packages to migrate components from a sandbox to production?

A

No, use change sets

29
Q

What are managed packages?

A

Managed packages are typically used by Salesforce partners to distribute and sell applications to customers. These packages must be created from a Developer Edition organization. Using the AppExchange and the License Management Application (LMA), developers can sell and manage user-based licenses to the app

30
Q

UC has purchased a new application from a partner to enable advanced quoting. UC just hired a developer to help modify the application to meet their needs.

Which two package types should the architect recommend? (Choose 2)

A) Unmanaged package developed in a Partner Developer Edition org

B) Managed package developed in a Partner Developer Edition org

C) Unmanaged package developed in a Developer Edition org

D) Managed package developed in a Developer Edition org

A

A) Unmanaged package developed in a Partner Developer Edition org

C) Unmanaged package developed in a Developer Edition org

31
Q

What consideration should an Architect take into account when asked for a recommendation of Agile vs. Waterfall?
Choose one answer

A. Rapidly changing business requirements.

B. Project budget and timeframe.

C. Number of stakeholders involved.

D. Technical complexity of the project.

A

A. Rapidly changing business requirements.

32
Q

What is an unpackaged package in Salesforce?

A

Components that live natively in your organization, such as standard objects, go in the unpackaged package

33
Q

What is second-generation packaging?

A

Second-generation packing (2GP) allows customer and system integrators to create packages in a source-driven development environment

You can create and deploy packages in your own Salesforce org or develop and distribute packages to your customers.

34
Q

Can you install a no-namespace, unlocked package into any org with a namespace? (for example, a scratch org with a namespace or a first-generation packaging org)

A

No

35
Q

When you’re using an unlocked package for deployment and changes have been made in production only, what will happen when a new package version is installed?

A

Changes made directly in production has the risk of being overwritten if those changes were not communicated back to the development team to update the package source

36
Q

Is there a limit to the number of package versions I can create per day?

A

Yes, run sfdx force:limits:api:display (example shown is 50)

37
Q

For which packages can you specify package inheritance:

A) 2GP managed Packages

B) Unlocked Packages

C) A and B

A

A) 2GP managed Packages

38
Q

Can you change the release status of a package version via the command line?

A

No

39
Q

When would metadata that was removed in a new package version end up being deprecated (vs being deleted) when the package is installed?

A
  • For user-entered data in custom objects and fields are deprecated and not deleted. Admins can export such data if necessary
  • An object such as an Apex class is deprecated and not deleted if it is referenced in a Lightning component that is part of the package
40
Q

What do you need to do after installing an external data source from a managed or unmanaged package?

A

The subscriber must re-authenticate to the external system.

41
Q

Can you package certificates?

A

Certificates aren’t packageable. If you package an external data source that specifies a certificate, make sure that the subscriber org has a valid certificate with the same name

42
Q

If you add an external data source to a package, what else is automatically included in the package?

A

No other components

43
Q

If you add an external object to a package, what else is automatically included in the package?

A

List Views, Page layouts, Custom fields, the custom object component and the external data source

44
Q

If you delete a field from a managed package, will the data and metadata they have automatically be deleted from the subscriber org?

A

Not without specific action by the customer. The components are displayed in the Unused Components section of the Package Details

45
Q

With Spring ‘19, how can you move metadata from one unlocked package to another unlocked package, if you need to refactor your package?

A) Manually remove the installed metadata from the original package and then install the new package in your production org

B) Use a scratch org package to combine the packages

C) Change the configurations in the Package.xml to create the association before deploying it to the destination org

D) Deprecate the metadata in an unlocked package, move that metadata to a new package, and then install the new package in your production org

A

D) Deprecate the metadata in an unlocked package, move that metadata to a new package, and then install the new package in your production org

46
Q

Following the package development method, what are some ideal ways to organize a packaging strategy?

A) Organize the packages by feature

B) Organize the packages by date created

C) Organize the packages by app project

D) Organize the packages alphabetically

E) A and C

A

E) A and C

47
Q

Before you incorporate permission sets into packages, what do you need to do?

A) Review how the current metadata is packaged

B) Remove all profiles and permission sets from the org

C) Create a custom package and store all profiles and permission sets in it regardless of other metadata

D) Move all users onto one profile

A

A) Review how the current metadata is packaged