◐ Shell
reader mode source ↗
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
File filter
Conversations
Jump to
Diff view
Apply and reload
Show whitespace
Diff view
Apply and reload
4 changes: 2 additions & 2 deletions java/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ Automatically format the code to conform the style guide by:

```sh
# formats all code in the feast-java repository
mvn spotless:apply
```

> If you're using IntelliJ, you can import these [code style settings](https://github.com/google/styleguide/blob/gh-pages/intellij-java-google-style.xml)
Expand All @@ -66,7 +66,7 @@ Run all Unit tests:
make test-java
```

Run all Integration tests (note: this also runs GCS + S3 based tests which should fail):
```
make test-java-integration
```
Expand Down
5 changes: 4 additions & 1 deletion java/serving/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,7 @@ feast-serving.jar
/.nb-gradle/

## Feast Temporary Files ##
/temp/
27 changes: 20 additions & 7 deletions java/serving/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
~
-->
<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/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>

<parent>
Expand Down Expand Up @@ -121,6 +121,19 @@
<version>5.0.1</version>
</dependency>

<!-- TODO: SLF4J is being used via Lombok, but also jog4j - pick one -->
<dependency>
<groupId>org.slf4j</groupId>
Expand Up @@ -356,11 +369,11 @@
<version>2.7.4</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>io.lettuce</groupId>
<artifactId>lettuce-core</artifactId>
<version>6.0.2.RELEASE</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@

import com.amazonaws.services.s3.AmazonS3;
import com.amazonaws.services.s3.AmazonS3ClientBuilder;
import com.google.cloud.storage.Storage;
import com.google.cloud.storage.StorageOptions;
import com.google.inject.AbstractModule;
Expand All @@ -43,11 +46,27 @@ public AmazonS3 awsStorage(ApplicationProperties applicationProperties) {
.build();
}

@Provides
RegistryFile registryFile(
ApplicationProperties applicationProperties,
Provider<Storage> storageProvider,
Provider<AmazonS3> amazonS3Provider) {

String registryPath = applicationProperties.getFeast().getRegistry();
Optional<String> scheme = Optional.ofNullable(URI.create(registryPath).getScheme());
Expand All @@ -57,6 +76,8 @@ RegistryFile registryFile(
return new GSRegistryFile(storageProvider.get(), registryPath);
case "s3":
return new S3RegistryFile(amazonS3Provider.get(), registryPath);
case "":
case "file":
return new LocalRegistryFile(registryPath);
Expand Down
Loading
Toggle all file notes Toggle all file annotations