Which one of the statements describes a service aggregator pattern?
-
A
It is implemented in each service separately and uses a streaming service
-
B
It involves implementing a separate service that makes multiple calls to other backend services
-
C
It uses a queue on both sides of the service communication
-
D
It involves sending events through a message broker
Reveal answer details
Close answer details
Correct answerB
Explanationthis pattern isolates an operation that makes calls to multiple back-end microservices, centralizing its logic into a specialized microservice.
You have two microservices, A and B running in production. Service A relies on APIs from service B. You want to test changes to service A without deploying all of its dependencies, which includes service B. Which approach should you take to test service A?
-
A
Test against production APIs.
-
B
-
C
There is no need to explicitly test APIs.
-
D
Test the APIs in private environments.
Reveal answer details
Close answer details
Correct answerB
ExplanationTesting using API mocks Developers are frequently tasked with writing code that integrates with other system components via APIs. Unfortunately, it might not always be desirable or even possible to actually access those systems during development. There could be security, performance or maintenance issues that make them unavailable ? or they might simply not have been developed yet. This is where mocking comes in: instead of developing code with actual external dependencies in place, a mock of those dependencies is created and used instead. Depending on your development needs this mock is made "intelligent" enough to allow you to make the calls you need and get similar results back as you would from the actual component, thus enabling development to move forward without being hindered by eventual unavailability of external systems you depend on
You are implementing logging in your services that will be running in Oracle Cloud Infrastructure Container Engine for Kubernetes. Which statement describes the appropriate logging approach?
-
A
Each service logs to its own log file.
-
B
All services log to an external logging system.
-
C
All services log to standard output only.
-
D
All services log to a shared log file.
Reveal answer details
Close answer details
Correct answerC
ExplanationApplication and systems logs can help you understand what is happening inside your cluster. The logs are particularly useful for debugging problems and monitoring cluster activity. Most modern applications have some kind of logging mechanism; as such, most container engines are likewise designed to support some kind of logging. The easiest and most embraced logging method for containerized applications is to write to the standard output and standard error streams. https://kubernetes.io/docs/concepts/cluster-administration/logging/ https://blogs.oracle.com/developers/5-best-practices-for-kubernetes-security
Question 4
Multiple choice
Which two "Action Type" options are NOT available in an Oracle Cloud Infrastructure (OCI) Events rule definition?
-
A
-
B
-
C
-
D
-
E
Reveal answer details
Close answer details
Correct answersD, E
Explanationhttps://docs.cloud.oracle.com/en-us/iaas/Content/Events/Concepts/eventsoverview.htm ACTIONS Event Rules must also specify an action to trigger when the filter finds a matching event. Actions are responses you define for event matches. You set up select Oracle Cloud Infrastructure services that the Events service has established as actions. The resources for these services act as destinations for matching events. When the filter in the rule finds a match, the Events service delivers the matching event to one or more of the destinations you identified in the rule. The destination service that receives the event then processes the event in whatever manner you defined. This delivery provides the automation in your environment. You can only deliver events to certain Oracle Cloud Infrastructure services with a rule. Use the following services to create actions: Notifications Streaming Functions
Which header is NOT required when signing GET requests to Oracle Cloud Infrastructure APIs?
-
A
-
B
-
C
-
D
Reveal answer details
Close answer details
Correct answerC
ExplanationFor GET and DELETE requests (when there's no content in the request body), the signing string must include at least these headers: (request-target) (as described in draft-cavage-http-signatures-08) host date or x-date (if both are included, Oracle uses x-date) https://docs.cloud.oracle.com/en-us/iaas/Content/API/Concepts/signingrequests.htm
You are deploying an API via Oracle Cloud Infrastructure (OCI) API Gateway and you want to implement request policies to control access Which is NOT available in OCI API Gateway?
-
A
Limiting the number of requests sent to backend services
-
B
Enabling CORS (Cross-Origin Resource Sharing) support
-
C
Providing authentication and authorization
-
D
Controlling access to OCI resources
Reveal answer details
Close answer details
Correct answerD
ExplanationIn the API Gateway service, there are two types of policy: - a request policy describes actions to be performed on an incoming request from a caller before it is sent to a back end - a response policy describes actions to be performed on a response returned from a back end before it is sent to a caller You can use request policies to: - limit the number of requests sent to back-end services - enable CORS (Cross-Origin Resource Sharing) support - provide authentication and authorization
What is one of the differences between a microservice and a serverless function?
-
A
Microservices are used for long running operations and serverless functions for short running operations.
-
B
Microservices always use a data store and serverless functions never use a data store.
-
C
Microservices are stateless and serverless functions are stateful.
-
D
Microservices are triggered by events and serverless functions are not.
Reveal answer details
Close answer details
Correct answerA
Explanationmicroservice is larger and can do more than a function. A function is a relatively small bit of code that performs only one action in response to an event. In many cases, microservices can be decomposed into a number of smaller stateless functions. The difference between microservices and functions is not simply the size. Functions are stateless, and they require no knowledge about or configuration of the underlying server--hence, the term serverless. https://developer.oracle.com/java/fn-project-introduction.html
With the volume of communication that can happen between different components in cloud-native applications, it is vital to not only test functionality, but also service resiliency. Which statement is true with regards to service resiliency?
-
A
Resiliency is about recovering from failures without downtime or data loss.
-
B
A goal of resiliency is not to bring a service to a functioning state after a failure.
-
C
Resiliency testing can be only done in a test environment.
-
D
Resiliency is about avoiding failures.
Reveal answer details
Close answer details
Correct answerD
ExplanationResiliency and Availability Resiliency and availability refers to the ability of a system to continue operating, despite the failure or sub-optimal performance of some of its components. In the case of Oracle Functions: The control plane is a set of components that manages function definitions. The data plane is a set of components that executes functions in response to invocation requests. For resiliency and high availability, both the control plane and data plane components are distributed across different availability domains and fault domains in a region. If one of the domains ceases to be available, the components in the remaining domains take over to ensure that function definition management and execution are not disrupted. When functions are invoked, they run in the subnets specified for the application to which the functions belong. For resiliency and high availability, best practice is to specify a regional subnet for an application (or alternatively, multiple AD-specific subnets in different availability domains). If an availability domain specified for an application ceases to be available, Oracle Functions runs functions in an alternative availability domain.
As a cloud-native developer, you have written a web service for your company. You have used Oracle Cloud Infrastructure (OCI) API Gateway service to expose the HTTP backend. However, your security team has suggested that your web service should handle Distributed Denial-of-Service (DDoS) attack. You are time-constrained and you need to make sure that this is implemented as soon as possible. What should you do in this scenario?
-
A
Use OCI virtual cloud network (VCN) segregation to control DDoS.
-
B
Use a third party service integration to implement a DDoS attack mitigation,
-
C
Use OCI API Gateway service and configure rate limiting.
-
D
Re-write your web service and implement rate limiting.
Reveal answer details
Close answer details
Correct answerC
ExplanationHaving created an API gateway and deployed one or more APIs on it, you'll typically want to limit the rate at which front-end clients can make requests to back-end services. For example, to: - maintain high availability and fair use of resources by protecting back ends from being overwhelmed by too many requests - prevent denial-of-service attacks - constrain costs of resource consumption - restrict usage of APIs by your customers' users in order to monetize APIs You apply a rate limit globally to all routes in an API deployment specification. If a request is denied because the rate limit has been exceeded, the response header specifies when the request can be retried. You can add a rate-limiting request policy to an API deployment specification by: using the Console editing a JSON file
Question 10
Multiple choice
You have created a repository in Oracle Cloud Infrastructure Registry in the us-ashburn-1 (iad) region in your tenancy with a namespace called "heyci. Which three are valid tags for an image named "myapp"?
-
A
iad.ocir.io/heyoci/myproject/myapp:0.0.1
-
B
us-ashburn-l.ocirJo/heyoci/myapp:0.0.2-beta
-
C
us-ashburn-l.ocir.io/heyoci/myproject/myapp:0.0.2-beta
-
D
us-ashburn-l.ocir.io/myproject/heyoci/myapp:latest
-
E
iad.ocir.io/myproject/heyoci/myapprlatest
-
F
iad.ocir.io/heyoci/myapp:0.0.2-beta
-
G
iad.ocir.io/heyoci/myapp:latest
Reveal answer details
Close answer details
Correct answersA, F, G
ExplanationGive a tag to the image that you're going to push to Oracle Cloud Infrastructure Registry by entering: docker tag <image-identifier> <target-tag> where: <image-identifier> uniquely identifies the image, either using the image's id (for example, 8e0506e14874), or the image's name and tag separated by a colon (for example, acme-web-app:latest). <target-tag> is in the format <region-key>.ocir.io/<tenancy-namespace>/<repo-name>/<image- name>:<tag> where: <region-key> is the key for the Oracle Cloud Infrastructure Registry region you're using. For example, iad. See Availability by Region. ocir.io is the Oracle Cloud Infrastructure Registry name. <tenancy-namespace> is the auto-generated Object Storage namespace string of the tenancy that owns the repository to which you want to push the image (as shown on the Tenancy Information page). For example, the namespace of the acme-dev tenancy might be ansh81vru1zp. Note that for some older tenancies, the namespace string might be the same as the tenancy name in all lower-case letters (for example, acme-dev). Note also that your user must have access to the tenancy. <repo-name> (if specified) is the name of a repository to which you want to push the image (for example, project01). Note that specifying a repository is optional (see About Repositories). <image-name> is the name you want to give the image in Oracle Cloud Infrastructure Registry (for example, acme-web-app). <tag> is an image tag you want to give the image in Oracle Cloud Infrastructure Registry (for example, version2.0.test). For example, for convenience you might want to group together multiple versions of the acme-web-app image in the acme-dev tenancy in the Ashburn region into a repository called project 01. You do this by including the name of the repository in the image name when you push the image, in the format <region- key>.ocir.io/<tenancy-namespace>/<repo-name>/<image-name>:<tag>. For example, iad.ocir.io/ ansh81vru1zp/project01/acme-web-app:4.6.3. Subsequently, when you use the docker push command, the presence of the repository in the image's name ensures the image is pushed to the intended repository. If you push an image and include the name of a repository that doesn't already exist, a new private repository is created automatically. For example, if you enter a command like docker push iad.ocir.io/ansh81vru1zp/project02/acme-web-app:7.5.2 and the project02 repository doesn't exist, a private repository called project02 is created automatically. If you push an image and don't include a repository name, the image's name is used as the name of the repository. For example, if you enter a command like docker push iad.ocir.io/ansh81vru1zp/acme-web-app:7.5.2 that doesn't contain a repository name, the image's name (acme-web-app) is used as the name of a private repository. https://docs.cloud.oracle.com/en-us/iaas/Content/Registry/Concepts/registrywhatisarepository.htm
Question 11
Single choice
You encounter an unexpected error when invoking the Oracle Function named "myfunction" in application "myapp". Which can you use to get more information on the error?
-
A
fn --debug invoke myapp myfunction
-
B
DEBOG=l fn invoke myapp myfunction
-
C
fn --verbose invoke myapp myfunction
-
D
Call Oracle support with your error message
Reveal answer details
Close answer details
Correct answerB
ExplanationTroubleshooting Oracle Functions If you encounter an unexpected error when using an Fn Project CLI command, you can find out more about the problem by starting the command with the string DEBUG=1 and running the command again. For example: $ DEBUG=1 fn invoke helloworld-app helloworld-func Note that DEBUG=1 must appear before the command, and that DEBUG must be in upper case.
|