5
ich ein Maven-Projekt in Eclipse erstellt und wenn ich versuche mvn im Projektverzeichnis laufen sauber installieren Sie es, diese Fehler gibt:Maven Kompilieren javax.ejb existiert nicht
[INFO] Compiling 3 source files to C:\Users\Florin\Documents\Facultate\Master\TM
IS\Anul1\Sem2\ORM\Teme\Lab1_5\shop-interfaces\target\classes
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] /C:/Users/Florin/Documents/Facultate/Master/TMIS/Anul1/Sem2/ORM/Teme/Lab
1_5/shop-interfaces/src/main/java/ro/unitbv/IShoppingCart.java:[5,17] package ja
vax.ejb does not exist
[ERROR] /C:/Users/Florin/Documents/Facultate/Master/TMIS/Anul1/Sem2/ORM/Teme/Lab
1_5/shop-interfaces/src/main/java/ro/unitbv/IShoppingCart.java:[7,2] cannot find
symbol
symbol: class Remote
[ERROR] /C:/Users/Florin/Documents/Facultate/Master/TMIS/Anul1/Sem2/ORM/Teme/Lab
1_5/shop-interfaces/src/main/java/ro/unitbv/ProductDao.java:[6,17] package javax
.ejb does not exist
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.
1:compile (default-compile) on project shop-interfaces: Compilation failure: Com
pilation failure:
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.
1:compile (default-compile) on project shop-interfaces: Compilation failure: Com
pilation failure:
[ERROR] /C:/Users/Florin/Documents/Facultate/Master/TMIS/Anul1/Sem2/ORM/Teme/Lab
1_5/shop-interfaces/src/main/java/ro/unitbv/IShoppingCart.java:[5,17] package ja
vax.ejb does not exist
...
ich, ob das Paket javax geprüft. ejb wird heruntergeladen und ist im Ordner .m2 vorhanden.
Edit: Meine pom-Datei ist:
<?xml version="1.0"?>
<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>ro.unitbv</groupId>
<artifactId>shop-interfaces</artifactId>
<version>1.0.0-SNAPSHOT</version>
<name>shop-interfaces</name>
<dependencies>
<dependency>
<groupId>javax</groupId>
<artifactId>javaee-api</artifactId>
<version>7.0</version>
<scope>povided</scope>
</dependency>
</dependencies>
</project>
Es ist wirklich wichtig, wenn das Paket heruntergeladen wurde und existiert in .m2/Repository es als eine Abhängigkeit in Ihrem Build (pom.xml-Datei) definiert werden soll sonst wird es nicht funktionieren. Abgesehen davon wäre es hilfreich, wenn Sie Ihre Pom-Datei zeigen. – khmarbaise
Ich habe die Pom-Datei hinzugefügt. –