Skip to content

Commit 925ac9c

Browse files
author
Jochen Damzog
committed
Adding user resource for v3
1 parent 267f9c3 commit 925ac9c

File tree

3 files changed

+10
-4
lines changed

3 files changed

+10
-4
lines changed

cloudfoundry-client-reactor/src/main/java/org/cloudfoundry/reactor/client/_ReactorCloudFoundryClient.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@
7373
import org.cloudfoundry.client.v3.spaces.SpacesV3;
7474
import org.cloudfoundry.client.v3.stacks.StacksV3;
7575
import org.cloudfoundry.client.v3.tasks.Tasks;
76+
import org.cloudfoundry.client.v3.users.UsersV3;
7677
import org.cloudfoundry.reactor.ConnectionContext;
7778
import org.cloudfoundry.reactor.TokenProvider;
7879
import org.cloudfoundry.reactor.client.v2.applications.ReactorApplicationsV2;
@@ -131,6 +132,7 @@
131132
import org.cloudfoundry.reactor.client.v3.spaces.ReactorSpacesV3;
132133
import org.cloudfoundry.reactor.client.v3.stacks.ReactorStacksV3;
133134
import org.cloudfoundry.reactor.client.v3.tasks.ReactorTasks;
135+
import org.cloudfoundry.reactor.client.v3.users.ReactorUsersV3;
134136
import org.immutables.value.Value;
135137
import reactor.core.publisher.Mono;
136138

@@ -491,6 +493,12 @@ public Users users() {
491493
return new ReactorUsers(getConnectionContext(), getRootV2(), getTokenProvider(), getRequestTags());
492494
}
493495

496+
@Override
497+
@Value.Derived
498+
public UsersV3 usersV3() {
499+
return new ReactorUsersV3(getConnectionContext(), getRootV3(), getTokenProvider(), getRequestTags());
500+
}
501+
494502
/**
495503
* The connection context
496504
*/

cloudfoundry-client/src/main/java/org/cloudfoundry/client/v3/users/User.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,12 +29,14 @@ public abstract class User extends Resource {
2929
* The username
3030
*/
3131
@JsonProperty("username")
32+
@Nullable
3233
public abstract String getUsername();
3334

3435
/**
3536
* The presentation name
3637
*/
3738
@JsonProperty("presentation_name")
39+
@Nullable
3840
public abstract String getPresentationName();
3941

4042
/**

integration-test/src/test/java/org/cloudfoundry/client/v3/UsersTest.java

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,6 @@ public final class UsersTest extends AbstractIntegrationTest {
3737
@Autowired
3838
private CloudFoundryClient cloudFoundryClient;
3939

40-
public UsersTest(CloudFoundryClient cloudFoundryClient) {
41-
this.cloudFoundryClient = cloudFoundryClient;
42-
}
43-
4440
private static Mono<CreateUserResponse> createUser(
4541
CloudFoundryClient cloudFoundryClient, String userId) {
4642
return cloudFoundryClient

0 commit comments

Comments
 (0)