java - Child module CHILD_MODULE_NAME of POM_LOCATION>pom.xml does not exist - Stack Overflow

admin2025-04-17  5

MOTIVATION
I am trying to use openhtmltopdf with pdfbox3 project.

MILESTONES
I have updated some codes, and pom.xml of the parent, core and pdfbox projects in openhtmltopdf as below.
.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf

PROBLEM

  • When i try to compile projects: "core" can be successfully compiled. But pdfbox [has core as dependency], and parent [has core and pdfbox as childeren modules] gives error.
  • Please find the relevent output and pom.xml files, below:

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core > compilation output]

BUILD SUCCESS

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox > compilation output]

BUILD FAILURE
Failed to execute goal on project com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox: Could not collect dependencies for project com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox:jar:1.0.11-SNAPSHOT
Failed to read artifact descriptor for com.tugalsan:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core:jar:1.0.11-SNAPSHOT
    Caused by: The following artifacts could not be resolved: com.tugalsan:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent:pom:1.0.11-SNAPSHOT (absent): Could not find artifact com.tugalsan:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent:pom:1.0.11-SNAPSHOT

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent > compilation output]

Scanning for projects...
[ERROR] Some problems were encountered while processing the POMs:
Child module C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core of C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml does not exist @ 
Child module C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox of C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml does not exist @ 
 @ 
The build could not read 1 project -> [Help 1]
  
  The project com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent:1.0.11-SNAPSHOT (C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml) has 2 errors
    Child module C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core of C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml does not exist
    Child module C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox of C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml does not exist

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core> pom.xml]

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns=".0.0" xmlns:xsi="; xsi:schemaLocation=".0.0 .0.0.xsd">

    <modelVersion>4.0.0</modelVersion>

    <parent>
        <groupId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf</groupId>
        <artifactId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent</artifactId>
        <version>1.0.11-SNAPSHOT</version>
    </parent>

    <artifactId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core</artifactId>
    <description>Open HTML to PDF is a CSS 2.1 renderer written in Java.  This artifact contains the core rendering and layout code.</description>

    <packaging>jar</packaging>

    <licenses>
        <license>
            <name>GNU Lesser General Public License (LGPL), version 2.1 or later</name>
            <url>.html</url>
        </license>
    </licenses>

    <distributionManagement>
        <snapshotRepository>
            <id>ossrh</id>
            <url>;/url>
        </snapshotRepository>
        <repository>
            <id>ossrh</id>
            <url>;/url>
        </repository>
    </distributionManagement>

    <profiles>
        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                                <configuration>
                                    <gpgArguments>
                                        <arg>--pinentry-mode</arg>
                                        <arg>loopback</arg>
                                    </gpgArguments>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>


    <dependencies>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>${open.junit4.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>com.tugalsan</groupId>
            <artifactId>com.tugalsan.api.unsafe</artifactId>
            <version>1.0-SNAPSHOT</version>
        </dependency>
    </dependencies>

    <build>
        <resources>
            <resource>
                <directory>src/main/resources</directory>
            </resource>
            <resource>
                <directory>../</directory>
                <targetPath>META-INF</targetPath>
                <includes>
                    <include>LICENSE*</include>
                </includes>
            </resource>
        </resources>

        <plugins>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <configuration>
                    <archive>
                        <manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
                    </archive> 
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.felix</groupId>
                <artifactId>maven-bundle-plugin</artifactId>
                <configuration>
                    <instructions>
                        <Export-Package>*</Export-Package>
                    </instructions>
                </configuration>

                <executions>
                    <execution>
                        <id>bundle-manifest</id>
                        <phase>process-classes</phase>
                        <goals>
                            <goal>manifest</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

        </plugins>
    </build>
</project>

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox> pom.xml]

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns=".0.0" xmlns:xsi="; xsi:schemaLocation=".0.0 .0.0.xsd">

    <modelVersion>4.0.0</modelVersion>

    <repositories>
        <repository>
            <id>ApacheSnapshot</id>
            <name>Apache Repository</name>
            <url>/</url>
            <snapshots>
                <enabled>false</enabled>
            </snapshots>
        </repository>
    </repositories>


    <parent>
        <groupId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf</groupId>
        <artifactId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent</artifactId>
        <version>1.0.11-SNAPSHOT</version>
    </parent>

    <artifactId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox</artifactId>
    <description>Openhtmltopdf is a CSS 2.1 renderer written in Java. This artifact supports PDF output with Apache PDF-BOX 2.</description>

    <packaging>jar</packaging>


    <licenses>
        <license>
            <name>GNU Lesser General Public License (LGPL), version 2.1 or later</name>
            <url>.html</url>
        </license>
    </licenses>

    <distributionManagement>
        <snapshotRepository>
            <id>ossrh</id>
            <url>;/url>
        </snapshotRepository>
        <repository>
            <id>ossrh</id>
            <url>;/url>
        </repository>
    </distributionManagement>

    <profiles>
        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                                <configuration>
                                    <gpgArguments>
                                        <arg>--pinentry-mode</arg>
                                        <arg>loopback</arg>
                                    </gpgArguments>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

    <dependencies>
        <!--<dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.13.2</version><!- - it was ${open.junit4.version} - ->
            <scope>test</scope>
        </dependency>-->
        <dependency>
            <groupId>org.apache.pdfbox</groupId>
            <artifactId>pdfbox</artifactId>
            <version>3.0.4</version><!-- it was 2.0.25 -->
        </dependency>
        <dependency>
            <groupId>org.apache.pdfbox</groupId>
            <artifactId>xmpbox</artifactId>
            <version>3.0.4</version><!-- it was 2.0.25 -->
        </dependency>
        <dependency>
            <groupId>de.rototor.pdfbox</groupId>
            <artifactId>graphics2d</artifactId>
            <version>3.0.2</version><!-- it was 0.34 -->
        </dependency>
        <dependency>
            <groupId>com.tugalsan</groupId>
            <artifactId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>com.tugalsan</groupId>
            <artifactId>com.tugalsan.api.unsafe</artifactId>
            <version>1.0-SNAPSHOT</version>
        </dependency>
    </dependencies>

    <build>
        <resources>
            <resource>
                <directory>../</directory>
                <targetPath>META-INF</targetPath>
                <includes>
                    <include>LICENSE*</include>
                </includes>
            </resource>
        </resources>

        <plugins>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <configuration>
                    <archive>
                        <manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
                    </archive> 
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.felix</groupId>
                <artifactId>maven-bundle-plugin</artifactId>
                <configuration>
                    <instructions>
                        <Export-Package>*</Export-Package>
                    </instructions>
                </configuration>

                <executions>
                    <execution>
                        <id>bundle-manifest</id>
                        <phase>process-classes</phase>
                        <goals>
                            <goal>manifest</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

        </plugins>

    </build>

    <!-- <properties>
        <pdfbox.version>2.0.25</pdfbox.version>
    </properties>-->

</project>

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent> pom.xml]

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns=".0.0" xmlns:xsi="; xsi:schemaLocation=".0.0 .0.0.xsd">

    <modelVersion>4.0.0</modelVersion>

    <groupId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf</groupId>
    <artifactId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent</artifactId>
    <version>1.0.11-SNAPSHOT</version>

    <packaging>pom</packaging>

    <description>Open-HTML-to-PDF is a HTML and CSS renderer written in Java.  It supports Java2D and PDF output. Open-HTML-to-PDF is a fork of Flying-saucer with additional features.</description>
    <url>;/url>

    <licenses>
        <license>
            <name>GNU Lesser General Public License (LGPL), version 2.1 or later</name>
            <url>.html</url>
        </license>
    </licenses>

    <!--<profiles>
        <profile>-->
            <modules>
                <module>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core</module>
                <!--<module>openhtmltopdf-slf4j</module>-->
                <!--<module>openhtmltopdf-examples</module>-->
                <module>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox</module>
                <!--<module>openhtmltopdf-rtl-support</module>-->
                <!--<module>openhtmltopdf-svg-support</module>-->
                <!--<module>openhtmltopdf-java2d</module>-->
                <!--<module>openhtmltopdf-objects</module>-->
                <!--<module>openhtmltopdf-mathml-support</module>-->
                <!--<module>openhtmltopdf-latex-support</module>-->
                <!--<module>openhtmltopdf-pdfa-testing</module>-->
                <!--<module>openhtmltopdf-templates</module>-->
            </modules>
        <!--</profile>
    </profiles>-->



    <scm>
        <connection>scm:git:git://github/danfickle/openhtmltopdf.git</connection>
        <developerConnection>scm:git:.git</developerConnection>
        <url>git://github/danfickle/openhtmltopdf.git</url>
        <tag>HEAD</tag>
    </scm>

    <distributionManagement>
        <snapshotRepository>
            <id>ossrh</id>
            <url>;/url>
        </snapshotRepository>
        <repository>
            <id>ossrh</id>
            <url>;/url>
        </repository>
    </distributionManagement>

    <developers>
        <developer>
            <id>danfickle</id>
            <name>Daniel Fickling</name>
            <email>[email protected]</email>
        </developer>
        <developer>
            <id>pdoubleya</id>
            <name>Patrick Wright</name>
            <email>[email protected]</email>
        </developer>
        <developer>
            <id>peter.brant</id>
            <name>Peter Brant</name>
            <email>[email protected]</email>
        </developer>
    </developers>

    <profiles>
        <profile>
            <id>doclint-java8-disable</id>
            <activation>
                <jdk>[1.8,)</jdk>
            </activation>
            <properties>
                <javadoc.opts>-Xdoclint:none</javadoc.opts>
            </properties>
        </profile>

        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                                <configuration>
                                    <!-- Prevent gpg from using pinentry programs. Fixes: gpg: signing 
                                    failed: Inappropriate ioctl for device -->
                                    <gpgArguments>
                                        <arg>--pinentry-mode</arg>
                                        <arg>loopback</arg>
                                    </gpgArguments>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-deploy-plugin</artifactId>
                    <version>3.1.3</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-gpg-plugin</artifactId>
                    <version>3.2.4</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-release-plugin</artifactId>
                    <version>3.0.1</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>3.13.0</version>
                    <configuration>
                        <compilerArgs>
                            <arg>-Xlint:deprecation</arg>
                        </compilerArgs>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-source-plugin</artifactId>
                    <version>3.3.1</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-javadoc-plugin</artifactId>
                    <version>3.6.3</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-jar-plugin</artifactId>
                    <version>3.4.2</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.felix</groupId>
                    <artifactId>maven-bundle-plugin</artifactId>
                    <version>5.1.2</version>
                </plugin>
            </plugins>
        </pluginManagement>
    
        <plugins>
            <plugin>
                <artifactId>maven-release-plugin</artifactId>
                <configuration>
                    <releaseProfiles>release</releaseProfiles>
                    <autoVersionSubmodules>true</autoVersionSubmodules>
                </configuration>
            </plugin>

            <plugin>
                <artifactId>maven-compiler-plugin</artifactId>
                <configuration>
                    <release>23</release>
                    <enablePreview>true</enablePreview>
                    <!--<compilerArgs>
                        <arg>- -add-modules</arg>
                        <arg>jdk.incubator.vector</arg>
                    </compilerArgs>-->
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <executions>
                    <execution>
                        <id>attach-sources</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <configuration>
                    <source>23</source>
                    <doclint>none</doclint>
                    <additionalparam>${javadoc.opts}</additionalparam>
                </configuration>
                <executions>
                    <execution>
                        <id>attach-javadocs</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

    <properties>
        <open.batik.version>1.18</open.batik.version>

        <!-- Please keep xmlgraphics-commons up to date with batik. -->
        <open.xmlgraphicsmons.version>2.10</open.xmlgraphicsmons.version>

        <!-- NOTE: Rhino is an optional dependency of Batik-Bridge. This version should match
        the version specified by Batik-Bridge. -->
        <open.rhino.version>1.8.0</open.rhino.version>

        <open.junit4.version>4.13.1</open.junit4.version>

        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    </properties>

</project>

UPDATE 1
After fixing below pom.xml, the error are as below

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox > pom.xml update]

<dependencies>
    ...
    <dependency>
<groupId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf</groupId>
<artifactId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core</artifactId>
<version>${project.version}</version>
    </dependencies>
    ...
</dependencies>

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core > compilation output]

BUILD SUCCESS

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox > compilation output]

BUILD FAILURE
Failed to execute goal on project com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox: Could not collect dependencies for project com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox:jar:1.0.11-SNAPSHOT
Failed to read artifact descriptor for com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core:jar:1.0.11-SNAPSHOT
    Caused by: The following artifacts could not be resolved: com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent:pom:1.0.11-SNAPSHOT (absent): Could not find artifact com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent:pom:1.0.11-SNAPSHOT

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent > compilation output]

Scanning for projects...
[ERROR] Some problems were encountered while processing the POMs:
Child module C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core of C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml does not exist @ 
Child module C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox of C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml does not exist @ 
 @ 
The build could not read 1 project -> [Help 1]
  
  The project com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent:1.0.11-SNAPSHOT (C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml) has 2 errors
    Child module C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core of C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml does not exist
    Child module C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox of C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml does not exist

MOTIVATION
I am trying to use openhtmltopdf with pdfbox3 project.
https://github.com/danfickle/openhtmltopdf

MILESTONES
I have updated some codes, and pom.xml of the parent, core and pdfbox projects in openhtmltopdf as below.
https://github.com/tugalsan/com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf

PROBLEM

  • When i try to compile projects: "core" can be successfully compiled. But pdfbox [has core as dependency], and parent [has core and pdfbox as childeren modules] gives error.
  • Please find the relevent output and pom.xml files, below:

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core > compilation output]

BUILD SUCCESS

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox > compilation output]

BUILD FAILURE
Failed to execute goal on project com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox: Could not collect dependencies for project com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox:jar:1.0.11-SNAPSHOT
Failed to read artifact descriptor for com.tugalsan:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core:jar:1.0.11-SNAPSHOT
    Caused by: The following artifacts could not be resolved: com.tugalsan:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent:pom:1.0.11-SNAPSHOT (absent): Could not find artifact com.tugalsan:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent:pom:1.0.11-SNAPSHOT

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent > compilation output]

Scanning for projects...
[ERROR] Some problems were encountered while processing the POMs:
Child module C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core of C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml does not exist @ 
Child module C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox of C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml does not exist @ 
 @ 
The build could not read 1 project -> [Help 1]
  
  The project com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent:1.0.11-SNAPSHOT (C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml) has 2 errors
    Child module C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core of C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml does not exist
    Child module C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox of C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml does not exist

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core> pom.xml]

<?xml version="1.0" encoding="UTF-8"?>
<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 http://maven.apache.org/xsd/maven-4.0.0.xsd">

    <modelVersion>4.0.0</modelVersion>

    <parent>
        <groupId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf</groupId>
        <artifactId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent</artifactId>
        <version>1.0.11-SNAPSHOT</version>
    </parent>

    <artifactId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core</artifactId>
    <description>Open HTML to PDF is a CSS 2.1 renderer written in Java.  This artifact contains the core rendering and layout code.</description>

    <packaging>jar</packaging>

    <licenses>
        <license>
            <name>GNU Lesser General Public License (LGPL), version 2.1 or later</name>
            <url>http://www.gnu.org/licenses/lgpl.html</url>
        </license>
    </licenses>

    <distributionManagement>
        <snapshotRepository>
            <id>ossrh</id>
            <url>https://oss.sonatype.org/content/repositories/snapshots</url>
        </snapshotRepository>
        <repository>
            <id>ossrh</id>
            <url>https://oss.sonatype.org/service/local/staging/deploy/maven2</url>
        </repository>
    </distributionManagement>

    <profiles>
        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                                <configuration>
                                    <gpgArguments>
                                        <arg>--pinentry-mode</arg>
                                        <arg>loopback</arg>
                                    </gpgArguments>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>


    <dependencies>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>${open.junit4.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>com.tugalsan</groupId>
            <artifactId>com.tugalsan.api.unsafe</artifactId>
            <version>1.0-SNAPSHOT</version>
        </dependency>
    </dependencies>

    <build>
        <resources>
            <resource>
                <directory>src/main/resources</directory>
            </resource>
            <resource>
                <directory>../</directory>
                <targetPath>META-INF</targetPath>
                <includes>
                    <include>LICENSE*</include>
                </includes>
            </resource>
        </resources>

        <plugins>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <configuration>
                    <archive>
                        <manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
                    </archive> 
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.felix</groupId>
                <artifactId>maven-bundle-plugin</artifactId>
                <configuration>
                    <instructions>
                        <Export-Package>*</Export-Package>
                    </instructions>
                </configuration>

                <executions>
                    <execution>
                        <id>bundle-manifest</id>
                        <phase>process-classes</phase>
                        <goals>
                            <goal>manifest</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

        </plugins>
    </build>
</project>

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox> pom.xml]

<?xml version="1.0" encoding="UTF-8"?>
<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 http://maven.apache.org/xsd/maven-4.0.0.xsd">

    <modelVersion>4.0.0</modelVersion>

    <repositories>
        <repository>
            <id>ApacheSnapshot</id>
            <name>Apache Repository</name>
            <url>https://repository.apache.org/content/groups/snapshots/</url>
            <snapshots>
                <enabled>false</enabled>
            </snapshots>
        </repository>
    </repositories>


    <parent>
        <groupId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf</groupId>
        <artifactId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent</artifactId>
        <version>1.0.11-SNAPSHOT</version>
    </parent>

    <artifactId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox</artifactId>
    <description>Openhtmltopdf is a CSS 2.1 renderer written in Java. This artifact supports PDF output with Apache PDF-BOX 2.</description>

    <packaging>jar</packaging>


    <licenses>
        <license>
            <name>GNU Lesser General Public License (LGPL), version 2.1 or later</name>
            <url>http://www.gnu.org/licenses/lgpl.html</url>
        </license>
    </licenses>

    <distributionManagement>
        <snapshotRepository>
            <id>ossrh</id>
            <url>https://oss.sonatype.org/content/repositories/snapshots</url>
        </snapshotRepository>
        <repository>
            <id>ossrh</id>
            <url>https://oss.sonatype.org/service/local/staging/deploy/maven2</url>
        </repository>
    </distributionManagement>

    <profiles>
        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                                <configuration>
                                    <gpgArguments>
                                        <arg>--pinentry-mode</arg>
                                        <arg>loopback</arg>
                                    </gpgArguments>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

    <dependencies>
        <!--<dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.13.2</version><!- - it was ${open.junit4.version} - ->
            <scope>test</scope>
        </dependency>-->
        <dependency>
            <groupId>org.apache.pdfbox</groupId>
            <artifactId>pdfbox</artifactId>
            <version>3.0.4</version><!-- it was 2.0.25 -->
        </dependency>
        <dependency>
            <groupId>org.apache.pdfbox</groupId>
            <artifactId>xmpbox</artifactId>
            <version>3.0.4</version><!-- it was 2.0.25 -->
        </dependency>
        <dependency>
            <groupId>de.rototor.pdfbox</groupId>
            <artifactId>graphics2d</artifactId>
            <version>3.0.2</version><!-- it was 0.34 -->
        </dependency>
        <dependency>
            <groupId>com.tugalsan</groupId>
            <artifactId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>com.tugalsan</groupId>
            <artifactId>com.tugalsan.api.unsafe</artifactId>
            <version>1.0-SNAPSHOT</version>
        </dependency>
    </dependencies>

    <build>
        <resources>
            <resource>
                <directory>../</directory>
                <targetPath>META-INF</targetPath>
                <includes>
                    <include>LICENSE*</include>
                </includes>
            </resource>
        </resources>

        <plugins>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <configuration>
                    <archive>
                        <manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
                    </archive> 
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.felix</groupId>
                <artifactId>maven-bundle-plugin</artifactId>
                <configuration>
                    <instructions>
                        <Export-Package>*</Export-Package>
                    </instructions>
                </configuration>

                <executions>
                    <execution>
                        <id>bundle-manifest</id>
                        <phase>process-classes</phase>
                        <goals>
                            <goal>manifest</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

        </plugins>

    </build>

    <!-- <properties>
        <pdfbox.version>2.0.25</pdfbox.version>
    </properties>-->

</project>

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent> pom.xml]

<?xml version="1.0" encoding="UTF-8"?>
<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 http://maven.apache.org/xsd/maven-4.0.0.xsd">

    <modelVersion>4.0.0</modelVersion>

    <groupId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf</groupId>
    <artifactId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent</artifactId>
    <version>1.0.11-SNAPSHOT</version>

    <packaging>pom</packaging>

    <description>Open-HTML-to-PDF is a HTML and CSS renderer written in Java.  It supports Java2D and PDF output. Open-HTML-to-PDF is a fork of Flying-saucer with additional features.</description>
    <url>https://github.com/danfickle/openhtmltopdf</url>

    <licenses>
        <license>
            <name>GNU Lesser General Public License (LGPL), version 2.1 or later</name>
            <url>http://www.gnu.org/licenses/lgpl.html</url>
        </license>
    </licenses>

    <!--<profiles>
        <profile>-->
            <modules>
                <module>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core</module>
                <!--<module>openhtmltopdf-slf4j</module>-->
                <!--<module>openhtmltopdf-examples</module>-->
                <module>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox</module>
                <!--<module>openhtmltopdf-rtl-support</module>-->
                <!--<module>openhtmltopdf-svg-support</module>-->
                <!--<module>openhtmltopdf-java2d</module>-->
                <!--<module>openhtmltopdf-objects</module>-->
                <!--<module>openhtmltopdf-mathml-support</module>-->
                <!--<module>openhtmltopdf-latex-support</module>-->
                <!--<module>openhtmltopdf-pdfa-testing</module>-->
                <!--<module>openhtmltopdf-templates</module>-->
            </modules>
        <!--</profile>
    </profiles>-->



    <scm>
        <connection>scm:git:git://github.com/danfickle/openhtmltopdf.git</connection>
        <developerConnection>scm:git:https://github.com/danfickle/openhtmltopdf.git</developerConnection>
        <url>git://github.com/danfickle/openhtmltopdf.git</url>
        <tag>HEAD</tag>
    </scm>

    <distributionManagement>
        <snapshotRepository>
            <id>ossrh</id>
            <url>https://oss.sonatype.org/content/repositories/snapshots</url>
        </snapshotRepository>
        <repository>
            <id>ossrh</id>
            <url>https://oss.sonatype.org/service/local/staging/deploy/maven2</url>
        </repository>
    </distributionManagement>

    <developers>
        <developer>
            <id>danfickle</id>
            <name>Daniel Fickling</name>
            <email>[email protected]</email>
        </developer>
        <developer>
            <id>pdoubleya</id>
            <name>Patrick Wright</name>
            <email>[email protected]</email>
        </developer>
        <developer>
            <id>peter.brant</id>
            <name>Peter Brant</name>
            <email>[email protected]</email>
        </developer>
    </developers>

    <profiles>
        <profile>
            <id>doclint-java8-disable</id>
            <activation>
                <jdk>[1.8,)</jdk>
            </activation>
            <properties>
                <javadoc.opts>-Xdoclint:none</javadoc.opts>
            </properties>
        </profile>

        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                                <configuration>
                                    <!-- Prevent gpg from using pinentry programs. Fixes: gpg: signing 
                                    failed: Inappropriate ioctl for device -->
                                    <gpgArguments>
                                        <arg>--pinentry-mode</arg>
                                        <arg>loopback</arg>
                                    </gpgArguments>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-deploy-plugin</artifactId>
                    <version>3.1.3</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-gpg-plugin</artifactId>
                    <version>3.2.4</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-release-plugin</artifactId>
                    <version>3.0.1</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>3.13.0</version>
                    <configuration>
                        <compilerArgs>
                            <arg>-Xlint:deprecation</arg>
                        </compilerArgs>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-source-plugin</artifactId>
                    <version>3.3.1</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-javadoc-plugin</artifactId>
                    <version>3.6.3</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-jar-plugin</artifactId>
                    <version>3.4.2</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.felix</groupId>
                    <artifactId>maven-bundle-plugin</artifactId>
                    <version>5.1.2</version>
                </plugin>
            </plugins>
        </pluginManagement>
    
        <plugins>
            <plugin>
                <artifactId>maven-release-plugin</artifactId>
                <configuration>
                    <releaseProfiles>release</releaseProfiles>
                    <autoVersionSubmodules>true</autoVersionSubmodules>
                </configuration>
            </plugin>

            <plugin>
                <artifactId>maven-compiler-plugin</artifactId>
                <configuration>
                    <release>23</release>
                    <enablePreview>true</enablePreview>
                    <!--<compilerArgs>
                        <arg>- -add-modules</arg>
                        <arg>jdk.incubator.vector</arg>
                    </compilerArgs>-->
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <executions>
                    <execution>
                        <id>attach-sources</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <configuration>
                    <source>23</source>
                    <doclint>none</doclint>
                    <additionalparam>${javadoc.opts}</additionalparam>
                </configuration>
                <executions>
                    <execution>
                        <id>attach-javadocs</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

    <properties>
        <open.batik.version>1.18</open.batik.version>

        <!-- Please keep xmlgraphics-commons up to date with batik. -->
        <open.xmlgraphics.commons.version>2.10</open.xmlgraphics.commons.version>

        <!-- NOTE: Rhino is an optional dependency of Batik-Bridge. This version should match
        the version specified by Batik-Bridge. -->
        <open.rhino.version>1.8.0</open.rhino.version>

        <open.junit4.version>4.13.1</open.junit4.version>

        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    </properties>

</project>

UPDATE 1
After fixing below pom.xml, the error are as below

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox > pom.xml update]

<dependencies>
    ...
    <dependency>
<groupId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf</groupId>
<artifactId>com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core</artifactId>
<version>${project.version}</version>
    </dependencies>
    ...
</dependencies>

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core > compilation output]

BUILD SUCCESS

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox > compilation output]

BUILD FAILURE
Failed to execute goal on project com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox: Could not collect dependencies for project com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox:jar:1.0.11-SNAPSHOT
Failed to read artifact descriptor for com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core:jar:1.0.11-SNAPSHOT
    Caused by: The following artifacts could not be resolved: com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent:pom:1.0.11-SNAPSHOT (absent): Could not find artifact com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent:pom:1.0.11-SNAPSHOT

[com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent > compilation output]

Scanning for projects...
[ERROR] Some problems were encountered while processing the POMs:
Child module C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core of C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml does not exist @ 
Child module C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox of C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml does not exist @ 
 @ 
The build could not read 1 project -> [Help 1]
  
  The project com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf:com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.parent:1.0.11-SNAPSHOT (C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml) has 2 errors
    Child module C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core of C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml does not exist
    Child module C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox of C:\git\api\com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf\pom.xml does not exist
Share Improve this question edited Feb 1 at 11:52 Tugalsan Karabacak asked Feb 1 at 11:29 Tugalsan KarabacakTugalsan Karabacak 6739 silver badges21 bronze badges 3
  • I think I found it. When one changes child artifact id, he should also change the folder name with that, even though he uses modules. I will try tomorrow and return findings. – Tugalsan Karabacak Commented Feb 1 at 15:50
  • Is there a good reason why you repeat the groupId in your artifactId? – khmarbaise Commented Feb 1 at 18:59
  • I want artifact id same with module-info. So it won't be complicated for me – Tugalsan Karabacak Commented Feb 2 at 1:59
Add a comment  | 

1 Answer 1

Reset to default 0

I have learned that, even one uses module-info.java to name its modules, on multimodule pom projects, childeren module names and the foldernames of the childeren has to be same.

There,

  • As I have changed the name of the childeren project resides in openhtmltopdf-core\ folder to com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core, I had to change its directory to com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.core as well.
  • As I have changed the name of the childeren project resides in openhtmltopdf-pdfbox\ folder to com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox, I had to change its directory to com.tugalsan.api.file.pdf.pdfbox3.openhtmltopdf.pdfbox as well.

    P.S.: I do not know how multimodule project functions well. But I have learned that its groupId does not have to be different from my other projects. To simplify things I changed the groupIds to com.tugalsan; hence console message sizes shorten signifacantly.
转载请注明原文地址:http://anycun.com/QandA/1744830343a88210.html