Skip to content

Commit 7a67944

Browse files
authored
Merge pull request #1 from evolv-ai/preparing-release-v0.5.1
preparing release of version 0.5.1
2 parents 382bf43 + dff3d5e commit 7a67944

File tree

2 files changed

+29
-24
lines changed

2 files changed

+29
-24
lines changed

README.md

Lines changed: 19 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,29 @@
55
**Participant:** The end user of the application, the individual who's actions are being recorded in the experiment.
66
**Allocation:** The set of configurations that have been given to the participant, the values that are being
77
experimented against.
8+
9+
10+
### Import the SDK
11+
12+
1. Import the Ascend SDK.
13+
14+
```xml
15+
<dependency>
16+
<groupId>ai.evolv</groupId>
17+
<artifactId>ascend-sdk</artifactId>
18+
<version>0.5.1</version>
19+
</dependency>
20+
```
821

922
### Client Initialization
1023

1124
1. Build an AscendConfig instance.
1225
```java
13-
AscendConfig config = AscendConfig.builder(<environment_id>).build();
26+
AscendConfig config = AscendConfig.builder(<environment_id>, <http_client>).build();
1427
```
28+
29+
*Note: The SDK uses a standard interface for the http backend see [HttpClient.](https://github.com/evolv-ai/ascend-java-sdk/blob/master/src/main/java/ai/evolv/HttpClient.java).
30+
When configuring the client you must specify what implementation of HttpClient to use (or implement your own).*
1531

1632
2. Initialize the AscendClient.
1733
```java
@@ -90,10 +106,10 @@ custom allocation store to the client when you build the AscendConfig.
90106

91107
1. Supply the allocation store to the client.
92108
```java
93-
AscendConfig config = AscendConfig.Builder(<environment_id>)
109+
AscendConfig config = AscendConfig.builder(<environment_id>, <http_client>)
94110
.setAscendAllocationStore(<custom_store>)
95111
.build();
96-
AscendClient client = AscendClient.init(config);
112+
AscendClient client = AscendClientFactory.init(config);
97113
```
98114

99115
### Optional Configurations

build.gradle

Lines changed: 10 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ plugins {
66

77
group = "ai.evolv"
88
archivesBaseName = "ascend-sdk"
9-
version = "0.5.0"
9+
version = "0.5.1"
1010

1111
sourceCompatibility = 1.8
1212

@@ -15,28 +15,17 @@ repositories {
1515
mavenCentral()
1616
}
1717

18-
ext.libraries = [:]
19-
20-
libraries.required = [
21-
'com.google.code.gson:gson:2.8.5',
22-
'org.slf4j:slf4j-api:1.7.26'
23-
]
24-
25-
libraries.optional = [
26-
'com.squareup.okhttp3:okhttp:3.14.0',
27-
'org.asynchttpclient:async-http-client:2.0.38'
28-
]
18+
dependencies {
19+
implementation 'com.google.code.gson:gson:2.8.5'
20+
implementation 'org.slf4j:slf4j-api:1.7.26'
2921

30-
libraries.test = [
31-
'log4j:log4j:1.2.17',
32-
'org.apache.logging.log4j:log4j-slf4j-impl:2.11.2',
33-
'org.mockito:mockito-core:2.1.0',
34-
'junit:junit:4.12'
35-
]
22+
compileOnly 'com.squareup.okhttp3:okhttp:3.14.0'
23+
compileOnly 'org.asynchttpclient:async-http-client:2.0.38'
3624

37-
dependencies {
38-
implementation libraries.required, libraries.optional, libraries.test
39-
testImplementation libraries.test
25+
testImplementation 'log4j:log4j:1.2.17'
26+
testImplementation 'org.apache.logging.log4j:log4j-slf4j-impl:2.11.2'
27+
testImplementation 'org.mockito:mockito-core:2.1.0'
28+
testImplementation 'junit:junit:4.12'
4029
}
4130

4231
task sourcesJar(type: Jar, dependsOn: classes) {

0 commit comments

Comments
 (0)