﻿<?xml version="1.0" encoding="UTF-8"?>
<!--
  Shared authorization client. Every business microservice adds this as a
  dependency to get:
    * @authz SpEL bean      -> @PreAuthorize("@authz.has('ASSET.CREATE')")
    * @EnableMethodSecurity turned on
    * Redis-cached fetch of permissions from UserService over the gateway
    * Pub/sub listener on 'iam.cache.invalidate' so writes elsewhere
      evict this MS's local view

  Build & publish:
    mvn -q install  (then every MS depends on com.workeye.teamsfm:authz-client:0.0.1)
-->
<project xmlns="http://maven.apache.org/POM/4.0.0"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <groupId>com.workeye.teamsfm</groupId>
    <artifactId>authz-client</artifactId>
    <version>0.0.1-SNAPSHOT</version>
    <packaging>jar</packaging>
    <name>authz-client</name>

    <properties>
        <java.version>21</java.version>
        <maven.compiler.source>21</maven.compiler.source>
        <maven.compiler.target>21</maven.compiler.target>
        <spring-boot.version>3.4.2</spring-boot.version>
    </properties>

    <dependencies>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-security</artifactId>
            <version>${spring-boot.version}</version>
        </dependency>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-oauth2-resource-server</artifactId>
            <version>${spring-boot.version}</version>
        </dependency>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-cache</artifactId>
            <version>${spring-boot.version}</version>
        </dependency>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-data-redis</artifactId>
            <version>${spring-boot.version}</version>
            <optional>true</optional>
        </dependency>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-web</artifactId>
            <version>6.2.1</version>
        </dependency>
        <dependency>
            <groupId>jakarta.servlet</groupId>
            <artifactId>jakarta.servlet-api</artifactId>
            <version>6.0.0</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.projectlombok</groupId>
            <artifactId>lombok</artifactId>
            <version>1.18.34</version>
            <scope>provided</scope>
        </dependency>
    </dependencies>

    <distributionManagement>
    <repository>
      <id>gitea</id>
      <url>https://gitea.eworkeye.com/api/packages/4linesinfotech/maven</url>
    </repository>
    <snapshotRepository>
      <id>gitea</id>
      <url>https://gitea.eworkeye.com/api/packages/4linesinfotech/maven</url>
    </snapshotRepository>
  </distributionManagement>
</project>
