aboutsummaryrefslogtreecommitdiffstats
path: root/archiva-database/src/main
diff options
context:
space:
mode:
authorJoakim Erdfelt <joakime@apache.org>2007-02-27 22:19:08 +0000
committerJoakim Erdfelt <joakime@apache.org>2007-02-27 22:19:08 +0000
commitdf9ebafaf947f4ee1d8d1519125214cdc235d6c2 (patch)
tree4627675cec2c37965a6898b4a21b70e2a2fe39e8 /archiva-database/src/main
parent08d67a9baccb1a0194b9fd1bb8b8b838743e537a (diff)
downloadarchiva-df9ebafaf947f4ee1d8d1519125214cdc235d6c2.tar.gz
archiva-df9ebafaf947f4ee1d8d1519125214cdc235d6c2.zip
Fixing broken code.
git-svn-id: https://svn.apache.org/repos/asf/maven/archiva/trunk@512450 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'archiva-database/src/main')
-rw-r--r--archiva-database/src/main/java/org/apache/maven/archiva/database/artifact/ArtifactPersistence.java12
1 files changed, 7 insertions, 5 deletions
diff --git a/archiva-database/src/main/java/org/apache/maven/archiva/database/artifact/ArtifactPersistence.java b/archiva-database/src/main/java/org/apache/maven/archiva/database/artifact/ArtifactPersistence.java
index 569e1d63f..d59cbf9cc 100644
--- a/archiva-database/src/main/java/org/apache/maven/archiva/database/artifact/ArtifactPersistence.java
+++ b/archiva-database/src/main/java/org/apache/maven/archiva/database/artifact/ArtifactPersistence.java
@@ -42,17 +42,20 @@ public class ArtifactPersistence
{
return new String[] { "ArtifactKeys" };
}
-
- private ArtifactKey toKey(Artifact artifact)
+
+ private ArtifactKey toKey( Artifact artifact )
{
ArtifactKey key = new ArtifactKey();
key.setGroupId( artifact.getGroupId() );
key.setArtifactId( artifact.getArtifactId() );
- key.set
+ key.setVersion( artifact.getVersion() );
+ key.setClassifier( artifact.getClassifier() );
+ key.setType( artifact.getType() );
return key;
}
- public void create( Artifact artifact ) throws ArchivaDatabaseException
+ public void create( Artifact artifact )
+ throws ArchivaDatabaseException
{
SqlMapClient sqlMap = ibatisHelper.getSqlMapClient();
@@ -62,7 +65,6 @@ public class ArtifactPersistence
getLogger().info( "Adding artifact." );
sqlMap.update( "addArtifact", artifact );
-
sqlMap.commitTransaction();
}