try
{
ProjectReference project;
VersionedReference versioned;
ArtifactReference artifact;
BidirectionalRepositoryLayout resourceLayout;
try
{
resourceLayout = layoutFactory.getLayoutForPath( resource );
}
catch ( LayoutException e )
{
/* invalid request - eat it */
return;
}
try
{
artifact = resourceLayout.toArtifactReference( resource );
if ( artifact != null )
{
connectors.fetchFromProxies( managedRepository, artifact );
request.getRequest().setPathInfo( layout.toPath( artifact ) );
return;
}
}
catch ( LayoutException e )
{
/* eat it */
}
try
{
versioned = resourceLayout.toVersionedReference( resource );
if ( versioned != null )
{
connectors.fetchFromProxies( managedRepository, versioned );
request.getRequest().setPathInfo( layout.toPath( versioned ) );
return;
}
}
catch ( LayoutException e )
{
/* eat it */
}
try
{
project = resourceLayout.toProjectReference( resource );
if ( project != null )
{
connectors.fetchFromProxies( managedRepository, project );
request.getRequest().setPathInfo( layout.toPath( project ) );
return;