|
| 1 | +<?xml version="1.0" encoding="UTF-8"?> |
| 2 | +<!-- |
| 3 | + ~ Copyright 2023 Amazon.com, Inc. or its affiliates. |
| 4 | + ~ Licensed under the Apache License, Version 2.0 (the |
| 5 | + ~ "License"); you may not use this file except in compliance |
| 6 | + ~ with the License. You may obtain a copy of the License at |
| 7 | + ~ http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | + ~ Unless required by applicable law or agreed to in writing, software |
| 9 | + ~ distributed under the License is distributed on an "AS IS" BASIS, |
| 10 | + ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 11 | + ~ See the License for the specific language governing permissions and |
| 12 | + ~ limitations under the License. |
| 13 | + ~ |
| 14 | + --> |
| 15 | + |
| 16 | +<project xmlns="http://maven.apache.org/POM/4.0.0" |
| 17 | + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| 18 | + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> |
| 19 | + <modelVersion>4.0.0</modelVersion> |
| 20 | + |
| 21 | + <artifactId>powertools-lambda-metadata</artifactId> |
| 22 | + <packaging>jar</packaging> |
| 23 | + |
| 24 | + <parent> |
| 25 | + <artifactId>powertools-parent</artifactId> |
| 26 | + <groupId>software.amazon.lambda</groupId> |
| 27 | + <version>2.9.0</version> |
| 28 | + </parent> |
| 29 | + |
| 30 | + <name>Powertools for AWS Lambda (Java) - Lambda Metadata</name> |
| 31 | + <description> |
| 32 | + A utility for idiomatic access to the Lambda Metadata Endpoint (LMDS), providing |
| 33 | + automatic caching, thread-safe access, and SnapStart support for retrieving |
| 34 | + execution environment metadata like Availability Zone ID. |
| 35 | + </description> |
| 36 | + |
| 37 | + <dependencies> |
| 38 | + <!-- Internal --> |
| 39 | + <dependency> |
| 40 | + <groupId>software.amazon.lambda</groupId> |
| 41 | + <artifactId>powertools-common</artifactId> |
| 42 | + </dependency> |
| 43 | + |
| 44 | + <!-- JSON parsing --> |
| 45 | + <dependency> |
| 46 | + <groupId>com.fasterxml.jackson.core</groupId> |
| 47 | + <artifactId>jackson-databind</artifactId> |
| 48 | + </dependency> |
| 49 | + |
| 50 | + <!-- CRaC for SnapStart support --> |
| 51 | + <dependency> |
| 52 | + <groupId>org.crac</groupId> |
| 53 | + <artifactId>crac</artifactId> |
| 54 | + </dependency> |
| 55 | + |
| 56 | + <!-- Logging --> |
| 57 | + <dependency> |
| 58 | + <groupId>org.slf4j</groupId> |
| 59 | + <artifactId>slf4j-api</artifactId> |
| 60 | + </dependency> |
| 61 | + |
| 62 | + <!-- Test dependencies --> |
| 63 | + <dependency> |
| 64 | + <groupId>org.junit.jupiter</groupId> |
| 65 | + <artifactId>junit-jupiter-api</artifactId> |
| 66 | + <scope>test</scope> |
| 67 | + </dependency> |
| 68 | + <dependency> |
| 69 | + <groupId>org.junit.jupiter</groupId> |
| 70 | + <artifactId>junit-jupiter-engine</artifactId> |
| 71 | + <scope>test</scope> |
| 72 | + </dependency> |
| 73 | + <dependency> |
| 74 | + <groupId>org.junit-pioneer</groupId> |
| 75 | + <artifactId>junit-pioneer</artifactId> |
| 76 | + <scope>test</scope> |
| 77 | + </dependency> |
| 78 | + <dependency> |
| 79 | + <groupId>org.assertj</groupId> |
| 80 | + <artifactId>assertj-core</artifactId> |
| 81 | + <scope>test</scope> |
| 82 | + </dependency> |
| 83 | + <dependency> |
| 84 | + <groupId>org.mockito</groupId> |
| 85 | + <artifactId>mockito-core</artifactId> |
| 86 | + <scope>test</scope> |
| 87 | + </dependency> |
| 88 | + <dependency> |
| 89 | + <groupId>org.mockito</groupId> |
| 90 | + <artifactId>mockito-junit-jupiter</artifactId> |
| 91 | + <scope>test</scope> |
| 92 | + </dependency> |
| 93 | + <dependency> |
| 94 | + <groupId>org.slf4j</groupId> |
| 95 | + <artifactId>slf4j-simple</artifactId> |
| 96 | + <scope>test</scope> |
| 97 | + </dependency> |
| 98 | + <dependency> |
| 99 | + <groupId>org.wiremock</groupId> |
| 100 | + <artifactId>wiremock</artifactId> |
| 101 | + <scope>test</scope> |
| 102 | + </dependency> |
| 103 | + </dependencies> |
| 104 | + |
| 105 | + <build> |
| 106 | + <plugins> |
| 107 | + <plugin> |
| 108 | + <groupId>dev.aspectj</groupId> |
| 109 | + <artifactId>aspectj-maven-plugin</artifactId> |
| 110 | + <version>${aspectj-maven-plugin.version}</version> |
| 111 | + <configuration> |
| 112 | + <skip>true</skip> |
| 113 | + </configuration> |
| 114 | + </plugin> |
| 115 | + </plugins> |
| 116 | + </build> |
| 117 | + |
| 118 | + <profiles> |
| 119 | + <profile> |
| 120 | + <id>generate-classesloaded-file</id> |
| 121 | + <build> |
| 122 | + <plugins> |
| 123 | + <plugin> |
| 124 | + <groupId>org.apache.maven.plugins</groupId> |
| 125 | + <artifactId>maven-surefire-plugin</artifactId> |
| 126 | + <configuration> |
| 127 | + <argLine> |
| 128 | + -Xlog:class+load=info:classesloaded.txt |
| 129 | + --add-opens java.base/java.util=ALL-UNNAMED |
| 130 | + --add-opens java.base/java.lang=ALL-UNNAMED |
| 131 | + </argLine> |
| 132 | + </configuration> |
| 133 | + </plugin> |
| 134 | + </plugins> |
| 135 | + </build> |
| 136 | + </profile> |
| 137 | + <profile> |
| 138 | + <id>generate-graalvm-files</id> |
| 139 | + <dependencies> |
| 140 | + <dependency> |
| 141 | + <groupId>org.mockito</groupId> |
| 142 | + <artifactId>mockito-subclass</artifactId> |
| 143 | + <scope>test</scope> |
| 144 | + </dependency> |
| 145 | + </dependencies> |
| 146 | + <build> |
| 147 | + <plugins> |
| 148 | + <plugin> |
| 149 | + <groupId>org.apache.maven.plugins</groupId> |
| 150 | + <artifactId>maven-surefire-plugin</artifactId> |
| 151 | + <configuration> |
| 152 | + <argLine> |
| 153 | + -Dorg.graalvm.nativeimage.imagecode=agent |
| 154 | + -agentlib:native-image-agent=config-output-dir=src/main/resources/META-INF/native-image/software.amazon.lambda/powertools-lambda-metadata,experimental-class-define-support |
| 155 | + --add-opens java.base/java.util=ALL-UNNAMED |
| 156 | + --add-opens java.base/java.lang=ALL-UNNAMED |
| 157 | + </argLine> |
| 158 | + </configuration> |
| 159 | + </plugin> |
| 160 | + </plugins> |
| 161 | + </build> |
| 162 | + </profile> |
| 163 | + <profile> |
| 164 | + <id>graalvm-native</id> |
| 165 | + <dependencies> |
| 166 | + <dependency> |
| 167 | + <groupId>org.mockito</groupId> |
| 168 | + <artifactId>mockito-subclass</artifactId> |
| 169 | + <scope>test</scope> |
| 170 | + </dependency> |
| 171 | + </dependencies> |
| 172 | + <build> |
| 173 | + <plugins> |
| 174 | + <plugin> |
| 175 | + <groupId>org.graalvm.buildtools</groupId> |
| 176 | + <artifactId>native-maven-plugin</artifactId> |
| 177 | + <version>0.11.2</version> |
| 178 | + <extensions>true</extensions> |
| 179 | + <executions> |
| 180 | + <execution> |
| 181 | + <id>test-native</id> |
| 182 | + <goals> |
| 183 | + <goal>test</goal> |
| 184 | + </goals> |
| 185 | + <phase>test</phase> |
| 186 | + </execution> |
| 187 | + </executions> |
| 188 | + <configuration> |
| 189 | + <imageName>powertools-lambda-metadata</imageName> |
| 190 | + <buildArgs> |
| 191 | + <buildArg>--add-opens java.base/java.util=ALL-UNNAMED</buildArg> |
| 192 | + <buildArg>--add-opens java.base/java.lang=ALL-UNNAMED</buildArg> |
| 193 | + <buildArg>--no-fallback</buildArg> |
| 194 | + <buildArg>--verbose</buildArg> |
| 195 | + <buildArg>--native-image-info</buildArg> |
| 196 | + <buildArg>-H:+UnlockExperimentalVMOptions</buildArg> |
| 197 | + <buildArg>-H:+ReportExceptionStackTraces</buildArg> |
| 198 | + </buildArgs> |
| 199 | + </configuration> |
| 200 | + </plugin> |
| 201 | + </plugins> |
| 202 | + </build> |
| 203 | + </profile> |
| 204 | + </profiles> |
| 205 | +</project> |
0 commit comments