[FAB-16849] Various updates for Java version of FabCar

- Update .gitignore
- Use builds on Sonatype, not Nexus
- Enable new discovery as localhost flag

Signed-off-by: Simon Stone <sstone1@uk.ibm.com>
Change-Id: Ia0904cedf953b5ecbf6aaf859245a9bb431d3f76
(cherry picked from commit 81aabf4c0b)
This commit is contained in:
Simon Stone 2019-10-16 17:09:54 +01:00
parent 9915995df7
commit b92ff73374
5 changed files with 20 additions and 6 deletions

View file

@ -2,4 +2,6 @@
/target/ /target/
.settings/ .settings/
.classpath .classpath
.project .project
wallet
!wallet/.gitkeep

View file

@ -19,16 +19,16 @@
</build> </build>
<repositories> <repositories>
<repository> <repository>
<id>hyperledger</id> <id>oss-sonatype</id>
<name>Hyperledger Nexus</name> <name>OSS Sonatype</name>
<url>https://nexus.hyperledger.org/content/repositories/snapshots</url> <url>https://oss.sonatype.org/content/repositories/snapshots</url>
</repository> </repository>
</repositories> </repositories>
<dependencies> <dependencies>
<dependency> <dependency>
<groupId>org.hyperledger.fabric-gateway-java</groupId> <groupId>org.hyperledger.fabric</groupId>
<artifactId>fabric-gateway-java</artifactId> <artifactId>fabric-gateway-java</artifactId>
<version>1.4.0-SNAPSHOT</version> <version>1.4.1-SNAPSHOT</version>
</dependency> </dependency>
<dependency> <dependency>
<groupId>org.junit.platform</groupId> <groupId>org.junit.platform</groupId>

View file

@ -14,6 +14,10 @@ import org.hyperledger.fabric.gateway.Wallet;
public class ClientApp { public class ClientApp {
static {
System.setProperty("org.hyperledger.fabric.sdk.service_discovery.as_localhost", "true");
}
public static void main(String[] args) throws Exception { public static void main(String[] args) throws Exception {
// Load a file system based wallet for managing identities. // Load a file system based wallet for managing identities.
Path walletPath = Paths.get("wallet"); Path walletPath = Paths.get("wallet");

View file

@ -17,6 +17,10 @@ import org.hyperledger.fabric_ca.sdk.HFCAClient;
public class EnrollAdmin { public class EnrollAdmin {
static {
System.setProperty("org.hyperledger.fabric.sdk.service_discovery.as_localhost", "true");
}
public static void main(String[] args) throws Exception { public static void main(String[] args) throws Exception {
// Create a CA client for interacting with the CA. // Create a CA client for interacting with the CA.

View file

@ -20,6 +20,10 @@ import org.hyperledger.fabric_ca.sdk.RegistrationRequest;
public class RegisterUser { public class RegisterUser {
static {
System.setProperty("org.hyperledger.fabric.sdk.service_discovery.as_localhost", "true");
}
public static void main(String[] args) throws Exception { public static void main(String[] args) throws Exception {
// Create a CA client for interacting with the CA. // Create a CA client for interacting with the CA.