Commit 3a50a704 authored by Matt Wise's avatar Matt Wise
Browse files

Merge branch 'feat/aws-impl' into 'master'

Fix failed cache import on startup of AWS service

See merge request !26
parents 7ff6b198 629f1d87
Pipeline #17582 passed with stages
in 35 minutes and 54 seconds
// Copyright © 2020 Amazon Web Services
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package org.opengroup.osdu.partition.provider.aws.service;
import org.opengroup.osdu.partition.model.PartitionInfo;
import org.opengroup.osdu.partition.provider.interfaces.IPartitionServiceCache;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Service;
import java.util.List;
/***
* We don't want to use cache. Implement a dummy service to always return a cache miss.
*/
@Service
@Qualifier("partitionListCache")
public class PartitionServiceDummyListCacheImpl implements IPartitionServiceCache<String, List<String>> {
public PartitionServiceDummyListCacheImpl() {
}
@Override
public void clearAll() {
return;
}
@Override
public void delete(String arg0) {
return;
}
@Override
public List<String> get(String arg0) {
return null;
}
@Override
public void put(String arg0, List<String> arg1) {
return;
}
}
......@@ -16,14 +16,16 @@ package org.opengroup.osdu.partition.provider.aws.service;
import org.opengroup.osdu.partition.model.PartitionInfo;
import org.opengroup.osdu.partition.provider.interfaces.IPartitionServiceCache;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Service;
/***
* We don't want to use cache. Implement a dummy service to always return a cache miss.
*/
@Service
public class PartitionServiceDummyCacheImpl implements IPartitionServiceCache<String, Object> {
public PartitionServiceDummyCacheImpl() {
@Qualifier("partitionServiceCache")
public class PartitionServiceDummyPartitionInfoCacheImpl implements IPartitionServiceCache<String, PartitionInfo> {
public PartitionServiceDummyPartitionInfoCacheImpl() {
}
......@@ -43,7 +45,7 @@ public class PartitionServiceDummyCacheImpl implements IPartitionServiceCache<St
}
@Override
public void put(String arg0, Object arg1) {
public void put(String arg0, PartitionInfo arg1) {
return;
}
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment