|
所在平台: Udemy |
课程主页: https://www.udemy.com/course/build-restful-apis-using-kotlin-and-spring-boot/
课程评论:没有评论
课程名称:使用Kotlin和Spring Boot构建RESTFUL APIs 课程概述:Kotlin是一种现代、简洁且安全的编程语言,如今在JVM语言中极为流行。它与Java和其他语言兼容,提供了多种跨平台代码重用方式,促进高效编程。本课程将重点介绍如何利用Kotlin进行服务器端开发,使用Spring Boot框架。课程采用纯实践的方式,涵盖以下两个主题:对于Java开发者必要的Kotlin基础知识,以及使用Spring Boot和Kotlin构建RESTFUL APIs。 课程内容包括: 1. **课程入门**:了解课程目标及所需先决条件。 2. **Kotlin编程语言简介**:介绍Kotlin语言及其在企业开发中的优势。 3. **Kotlin基础**:探索Kotlin的基础知识,包括变量、基本类型、条件语句、循环等。 4. **Kotlin中的函数**:学习如何定义和使用函数,包括默认参数和命名参数。 5. **类、接口与继承**:详细讲解类、接口及其继承关系。 6. **处理空值**:学习如何在Kotlin中处理空值和空类型。 7. **集合、数组与Lambda表达式**:介绍Kotlin的集合和Lambda表达式的使用。 8. **异常处理**:讨论Kotlin中的异常处理技术。 9. **作用域函数**:学习Kotlin中的作用域函数及其用法。 10. **Kotlin与Spring Boot入门**:了解将要构建的应用概述并创建简单API。 11. **使用JUnit 5进行集成/单元测试**:学习使用JUnit 5编写测试用例。 12. **构建课程目录服务**:创建课程实体及相关API端点。 13. **控制器层单元测试**:编写控制器单元测试。 14. **使用Validator和ControllerAdvice进行Bean验证**:学习如何应用Bean验证和异常处理。 15. **使用Spring Data JPA编写自定义JPA查询并测试数据库层**:掌握自定义查询与数据库测试技巧。 16. **使用@RequestParam通过名称检索课程的GET端点**:掌握@RequestParam的使用。 17. **使用Spring Data JPA的实体关系**:讲解在JPA中表达实体关系的技巧。 18. **与Postgres数据库集成**:学习如何将Postgres数据库与服务集成。 19. **使用TestContainers进行集成测试**:配置TestContainers以进行集成测试。 20. **Java与Kotlin互操作性**:学习Java与Kotlin之间的互操作性。 课程结束时,学员将能够熟练使用Kotlin编程语言,并使用Spring Boot和Kotlin构建RESTFUL APIs。
Kotlin is the Modern, concise and safe programming language and is one of the popular JVM language in this day and age.It's also interoperable with Java and other languages, and provides many ways to reuse code between multiple platforms for productive programming.This course will focus on using Kotlin for Server-Side Development using SpringBoot framework. This is a pure hands-on oriented course which covers these two topics:Covers Kotlin Fundamentals thats necessary for Java DevelopersBuild RestFul APIs using SpringBoot and KotlinSection 1: Getting Started With the CourseThis section covers the course objectives and the prerequisites that are needed to make the most out of this course.Section 2: Getting Started with Kotlin Programming LanguageIn this section, I will introduce you to Kotlin Programming Language and why its a powerful language for enterprise development.Introduction to KotlinHow Kotlin Works with the JVM?Section 3: Kotlin FundamentalsIn this section, we will explore the fundamentals of Kotlin.val & var variables in KotlinBasic Types - Int, Long, Double, StringConditionals - If and when blockRanges , Loops while & do-Whilebreak, labels and returnSection 4: Functions in KotlinIn this section, we will learn about functions in Kotlin and different ways of declaring and using themDefining and Invoking Functions Default Value Parameters & Named ArgumentsTop-Level Functions and Top-level PropertiesSection 5: Classes, Interfaces and InheritanceIn this section, we will learn about classes, inheritance and interfaces in detail.Introduction to class - Creating a class and objectsPrimary ConstructorsSecondary Constructorsinitializer code using init blockData ClassesCustom Getters and Setters Inheritance - Extending ClassesInheritance - Override Functions, Variablesobject keyword for creating instance of the classcompanion object KeywordInterfacesInterfaces - Handling Conflicting FunctionsInterfaces - Defining and Overrding VariablesVisibility ModifiersType Checking, Casting and Smart CastEnum classSection 6: Nulls in KotlinIn this section, we will learn about handling nulls in KotlinNullable & Non-Nullable types in KotlinSafe Call(?) , Elvis Operator(?:) & Non Null Assertion(!!) to deal with Null ValuesInvoking or assigning a Nullable Type to a Non-Nullable TypeSection 7: Collections, Arrays & Lamda ExpressionsIn this section, I will introduce you to collections, arrays and lambda expressions in KotlinIntroduction to CollectionsIntroduction to Lamda ExpressionsLambdas and Higher Order FunctionsFilter Operations on Kotlin CollectionsMap Operations on Kotlin CollectionsFlatMap Operations in CollectionsWorking With HashMapsLazy Evaluation of Collections using SequencesNullability in CollectionsSection 8: Exceptions In KotlinIn this section, I will cover the exceptions in kotlin and the techniques to handle them.Handling Exceptions using try-catchSection 9: Scope FunctionsIn this section, I will introduce you all to scope functions in Kotlin and its usage.Introduction to Scope Functionsapply & also Scope Functionlet Scope Functionwith & run Scope FunctionSection 10: Getting Started with Kotlin and Spring BootIn this section, I will explain the overview of the app we are going to build and build a very simple API.Overview of the app & Project SetupBuild a Simple Endpoint - Greeting ControllerConstructor Injection in SpringSetting up different profiles in Spring BootSet up Logging in KotlinSection 11: Integration/Unit Testing using Junit 5In this section, I will code and explain about the techniques to write different types of test cases using spring boot and Kotlin.Introduction to Automated Tests & Setting up JUnit5Integration Test for ControllerUnit Test for Controller - Using the Mockk Mocking librarySection 12: Build the Course Catalog ServiceIn this section, we will build the Course Catalog Service to manage the CoursesSet up the Course Entity & CourseDTOCreate CourseRepository & Configure JPA in application.yml fileBuild the POST Endpoint for adding new Course Integration test for the POST endpoint using JUnit5Build the Get Endpoint to retrieve all CoursesIntegration test for the GET endpoint to retrieve all the coursesBuild the Update Endpoint to update a CourseIntegration test for the PUT endpoint using JUnit5Build the DELETE endpoint to delete a CourseSection 13: Unit Testing Controller layer (Web Tier)In this section, we will code and learn about how to write unit tests for the controllerSetting up the Unit Test for the CourseControllerUnit test for the Post Endpoint in CourseControllerUnit test for the GET Endpoint in CourseControllerUnit test for the PUT Endpoint in CourseControllerUnit test for the DELETE Endpoint in CourseControllerSection 14: Bean Validation using Validators and ControllerAdviceIn this section, we will code and learn the different techniques to apply bean validations and handle exceptions using the ControllerAdvice PatternName and Category as Mandatory using @NotBlank AnnotationImplement Custom Error Handling using ControllerAdvice patternHandle Global RuntimeException using ControllerAdvice PatternSection 15: Custom JPA queries using Spring Data JPA and DB Layer testing using @DataJpaTestIn this lecture, we will learn about the techniques to write custom JPA queries and the techniques to test the DB layer using the DataJpaTestRetrieve Courses By Name using JPA Query Creation FunctionRetrieve Courses By Name using Native SQL queryTesting Mutliple sets of Data using @Parameterized testSection 16: GET Endpoint to retrieve Courses By Name using @RequestParamIn this section, we will code and learn about the usage of RequestParam in the controller endpoint.Use existing GET endpoint to retrieve Courses by NameWrite Integration test to retrieve course by NameSection 17: Entity RelationShips using Spring Data JPAIn this section, I will explain the technique to express the relationships in JPA using Entity and Data classes in KotlinAdding Instructor Entity in to the Course Catalog ServiceAdding the relationship in the Entity ClassInstructor Controller to Manage Instructor DataUpdate CourseService to validate Instructor DataFix the CourseController Integration TestsFix the CourseController Unit TestsSection 18: Integrating with Postgres DBIn this section, we will code and learn to integrate the postgres DB in to the course catalog service.Setting up the Postgres DB and App to interact with PostgresTest the app with Postgres DBSection 19: Integration Testing using TestContainersIn this section, we will code and learn to integrate the testcontainers to run integration test.Setting Up TestContainers for the Integration TestConfigure @DataJpaTest with TestContainersSection 20: Java & Kotlin InteroperabilityIn this section, we will code and learn about the interoperability between Java and Kotlin.Invoking Kotlin Code from Java ClassInvoking Java Code from KotlinUseful JVM annotations in KotlinBy the end of this course, you will be comfortable writing code using the Koltin Programming language and Build RestFuL APIs using SpringBoot and Kotlin.