Score:0

Tenant with name projects/**/tenants/** not found using Google Cloud talent solution API

ci flag

Description:

Code:

String projectId = "*****";

String tenantId = "***-ay7tp";

        try (JobServiceClient jobServiceClient = JobServiceClient.create()) {

        // Construct the list jobs request
        ListJobsRequest.Builder requestBuilder = ListJobsRequest.newBuilder()
                .setParent("projects/" + projectId + "/tenants/" + tenantId).setFilter("status = \"OPEN\"")
                .setJobView(JobView.JOB_VIEW_FULL); // specify which fields to include in the response

        

        // Use the JobServiceClient to list the jobs
        ListJobsPagedResponse response1 = jobServiceClient.listJobs(requestBuilder.build());
        System.out.println(response1.toString());

        TenantName parent = TenantName.of(projectId, tenantId);
        ListJobsRequest request = ListJobsRequest.newBuilder().setParent(parent.toString())
                .setFilter("status = \"OPEN\"").build();

        // Print the details of the first 10 jobs in the response
        int count = 0;
        for (com.google.cloud.talent.v4.Job job : jobServiceClient.listJobs(request).iterateAll()) {
            System.out.println("Job title: " + job.getTitle());
            System.out.println("Job description: " + job.getDescription());
            System.out.println("Job posting date: " + job.getPostingPublishTime().toString());
            System.out.println("Job company name: " + job.getCompanyDisplayName());
            System.out.println("Job ID: " + job.getName().substring(job.getName().lastIndexOf("/") + 1));
            System.out.println("----------------------------------------");
            count++;
            if (count >= 10) {
                break;
            }
        }
    }

error:

NOT_FOUND: Tenant with name projects//tenants/ not found. Request ID for tracking: -*****-48e8-961e-:***********==

khushbu shah avatar
ci flag
com.google.api.gax.rpc.PermissionDeniedException: io.grpc.StatusRuntimeException: PERMISSION_DENIED: Tenant projects/**/tenants/** is not allowed to access company with id projects/shareproone/tenants/**/companies/**. Request ID for tracking: **==]
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.