DevOps Classroomnotes 18/Sep/2022

Maven

  • Maven is one of most popular build and project management tool for Java and Java Based Languages
  • The Other build tools for java include Ant, Gradle.
  • Any Language has lot of built in functionalities which are provided by language or community, These are referred as dependencies.
  • We need to perform dependency management.
  • Maven used the approach of Convention over configuration.
  • Maven reads a file which is pom.xml where the following are defined
    • project metadata
    • dependencies
  • Refer Here
  • Maven projects have goals
    • compile => Compile java sources and generate class files in target folder
    • test => Execute tests and generate test report
    • package => Create a packaging format (jar, war) after generating classes and test execution
    • install => The package created in the target folder will be copied into .m2 folder for other projects in your system to reuse the code
    • deploy => The package created will be copied into configured remote repository for other users to reuse.
    • clean => remove target folder.
  • With this we can configure

    • archive the artifact
    • Generate Test Result Report.
  • Dependencies:

    • Java (Maven) => Refer Here
    • .net (Nuget)
    • Python (pip)
    • javascript (npm)
  • Package Repository:
    • local
    • central
      Preview
      Preview
  • Unit Tests:
  • Automated Tests using Test Automation Frameworks

    • Selenium
    • Postman
    • RPA
    • Jmeter
  • To change maven’s behavior i.e. where to download dependencies from and where to deploy dependencies to, http proxy etc create a file called as settings.xml in .m2 folder Refer Here
  • The tool configurations can be done from jenkins as well.

Exercises

  • Learn about Environment Variables, Local Variables in Linux and Windows (Command Prompt/Powershell)
  • Learn about YAML, JSON Refer Here
  • Create a Linux vm (free instance)
    • Install python, pip
    • Install nodejs, npm
    • Install dotnet core

Published
Categorized as Uncategorized Tagged

By continuous learner

devops & cloud enthusiastic learner

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Please turn AdBlock off
Animated Social Media Icons by Acurax Responsive Web Designing Company

Discover more from Direct DevOps from Quality Thought

Subscribe now to keep reading and get access to the full archive.

Continue reading

Visit Us On FacebookVisit Us On LinkedinVisit Us On Youtube