Introduction to Spring Boot & GraphQL API Development
A beginner's quiz on developing APIs using Spring Boot and GraphQL.
Questions in this quiz
15 questions on Introduction to Spring Boot & GraphQL API Development. Work through them here, then start the quiz to answer them and see your score.
1.What is Spring Boot primarily used for?
- ACreating standalone Java applications
- BDeveloping mobile applications
- CBuilding web servers
- DDesigning user interfaces
2.Which file is used to define dependencies in a Spring Boot project?
- Asettings.gradle
- Bbuild.xml
- Capplication.properties
- Dpom.xml
3.What is the default port for a Spring Boot application?
- A443
- B3000
- C80
- D8080
4.Which annotation is used to mark a class as a Spring Boot application?
- A@SpringBootApplication
- B@RestController
- C@Service
- D@Component
5.What is GraphQL primarily used for?
- AQuerying databases
- BDesigning web pages
- CQuerying APIs
- DBuilding REST APIs
6.In GraphQL, what is a 'query'?
- AA mutation operation
- BA write operation
- CA read operation
- DA delete operation
7.Which annotation is used to define a GraphQL query in Spring Boot?
- A@GraphQLField
- B@Query
- C@GraphQLQuery
- D@GraphQL
8.What is the purpose of the application.properties file in Spring Boot?
- ATo define API endpoints
- BTo manage database connections
- CTo write business logic
- DTo store application settings
9.Which dependency is essential for adding GraphQL support in a Spring Boot project?
- Aspring-boot-starter-security
- Bspring-boot-starter-data-jpa
- Cgraphql-spring-boot-starter
- Dspring-boot-starter-web
10.What is a 'mutation' in GraphQL?
- AA write operation
- BA query operation
- CA delete operation
- DA read operation
11.How do you start a Spring Boot application?
- ACompile the project
- BUse the 'start' command
- CRun the main method
- DDeploy to a server
12.Which tool is commonly used to test GraphQL APIs?
- AGraphiQL
- BJUnit
- CPostman
- DSwagger
13.What is the role of a 'resolver' in GraphQL?
- ATo resolve queries
- BTo serve static files
- CTo handle HTTP requests
- DTo manage database connections
14.Which annotation is used to handle HTTP GET requests in Spring Boot?
- A@RequestMapping
- B@GetMapping
- C@PutMapping
- D@PostMapping
15.What is the main advantage of using GraphQL over REST?
- AReduced data fetching
- BFaster server response
- CEasier to implement
- DSimpler authentication