Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
import java.util.ArrayList;
import java.util.Collection;
import java.util.Collections;
import java.util.Date;
import java.util.HashSet;
import java.util.List;
import java.util.Map;
Expand Down Expand Up @@ -493,7 +494,12 @@ protected Boolean doStore( StoreKey k, ArtifactStore store, ChangeSummary summar
return false;
}

logger.debug( "Put {} to stores map", k );
logger.info( "Put {} to stores, {}", k, summary );
if ( summary != null )
{
store.setMetadata( ArtifactStore.METADATA_CHANGELOG,
String.format( "%s, %s", summary.getSummary(), new Date() ));
}
final ArtifactStore old = putArtifactStoreInternal( store.getKey(), store );

try
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@

import static java.util.Collections.emptyMap;
import static java.util.Collections.emptySet;
import static org.commonjava.indy.db.common.StoreUpdateAction.STORE;
import static org.commonjava.indy.model.core.StoreType.hosted;

@SuppressWarnings( "unchecked" )
Expand Down Expand Up @@ -415,6 +416,17 @@ protected Indy getIndyClient()
return this.client;
}

@Override
protected void postStore( final ArtifactStore store, final ArtifactStore original, final ChangeSummary summary,
final boolean exists, final boolean fireEvents, final EventMetadata eventMetadata )
throws IndyDataException
{
super.postStore( store, original, summary, exists, fireEvents, eventMetadata );
logger.info( "Remove from store cache, {}", store.getKey() );
BasicCacheHandle<StoreKey, ArtifactStore> cache = cacheProducer.getBasicCache( ARTIFACT_STORE );
cache.remove( store.getKey() );
}

private ArtifactStore computeIfAbsent( StoreKey key, Supplier<ArtifactStore> storeProvider, int expirationMins,
boolean forceQuery )
{
Expand Down
Loading