@Test public void testCreateWithExpiredSession() throws NoSuchFieldException, UnexpectedErrorFault_Exception, IllegalAccessException, InterruptedException, ApiException { logout(); Thread.sleep(1000); List<Metadata> mdList = new ArrayList<Metadata>(); StaticResource metadata = new StaticResource(); mdList.add(metadata); metadata.setFullName("testStaticResource"); metadata.setCacheControl(StaticResourceCacheControl.PUBLIC); metadata.setContent("Foobar".getBytes()); metadata.setContentType("text/plain"); try { mdconn.create(mdList); fail(); } catch (ApiException e) { assertInvalidSession(e); } }
@Override @Nonnull public synchronized List<AsyncResult> create(@Nonnull List<Metadata> metadataList) throws ApiException { return convertStubAsyncResultList(new CreateOp().execute(metadataList)); }
MetadataConnectionImpl extends AbstractSalesforceConnection implements MetadataConnection { @Override @Nonnull public synchronized List<AsyncResult> create(@Nonnull List<Metadata> metadataList) throws ApiException { return convertStubAsyncResultList(new CreateOp().execute(metadataList)); } }
MetadataConnectionImpl extends AbstractSalesforceConnection implements MetadataConnection { @Override @Nonnull public synchronized List<AsyncResult> create(@Nonnull List<Metadata> metadataList) throws ApiException { return convertStubAsyncResultList(new CreateOp().execute(metadataList)); } MetadataConnectionImpl(@Nonnull CallSemaphore semaphore, @Nonnull ConnectionBundleImpl bundle,
            MetricRegistry metricRegistry); }
MetadataConnectionImpl extends AbstractSalesforceConnection implements MetadataConnection { @Override @Nonnull public synchronized List<AsyncResult> create(@Nonnull List<Metadata> metadataList) throws ApiException { return convertStubAsyncResultList(new CreateOp().execute(metadataList)); } MetadataConnectionImpl(@Nonnull CallSemaphore semaphore, @Nonnull ConnectionBundleImpl bundle,
            MetricRegistry metricRegistry); @Override @Nonnull WaitForAsyncResult waitForAsyncResults(@Nonnull List<AsyncResult> results, long maxMillisToWait); @Override @Nonnull synchronized List<AsyncResult> checkStatus(@Nonnull List<Id> idsToCheck); @Override @Nonnull synchronized List<AsyncResult> create(@Nonnull List<Metadata> metadataList); @Override @Nonnull synchronized List<AsyncResult> delete(@Nonnull List<Metadata> metadataList); @Override @Nonnull synchronized List<AsyncResult> update(@Nonnull List<UpdateMetadata> metadataList); @Override @Nonnull synchronized List<FileProperties> listMetadata(@Nonnull List<ListMetadataQuery> queries); @Override @Nonnull synchronized AsyncResult retrieve(@Nonnull RetrieveRequest retrieveRequest); @Override @Nonnull synchronized RetrieveResult getRetrieveResult(@Nonnull Id id); @Override @Nonnull synchronized DescribeMetadataResult describeMetadata(); @Override @Nonnull synchronized DescribeMetadataResult describeMetadata(double apiVersion); }
MetadataConnectionImpl extends AbstractSalesforceConnection implements MetadataConnection { @Override @Nonnull public synchronized List<AsyncResult> create(@Nonnull List<Metadata> metadataList) throws ApiException { return convertStubAsyncResultList(new CreateOp().execute(metadataList)); } MetadataConnectionImpl(@Nonnull CallSemaphore semaphore, @Nonnull ConnectionBundleImpl bundle,
            MetricRegistry metricRegistry); @Override @Nonnull WaitForAsyncResult waitForAsyncResults(@Nonnull List<AsyncResult> results, long maxMillisToWait); @Override @Nonnull synchronized List<AsyncResult> checkStatus(@Nonnull List<Id> idsToCheck); @Override @Nonnull synchronized List<AsyncResult> create(@Nonnull List<Metadata> metadataList); @Override @Nonnull synchronized List<AsyncResult> delete(@Nonnull List<Metadata> metadataList); @Override @Nonnull synchronized List<AsyncResult> update(@Nonnull List<UpdateMetadata> metadataList); @Override @Nonnull synchronized List<FileProperties> listMetadata(@Nonnull List<ListMetadataQuery> queries); @Override @Nonnull synchronized AsyncResult retrieve(@Nonnull RetrieveRequest retrieveRequest); @Override @Nonnull synchronized RetrieveResult getRetrieveResult(@Nonnull Id id); @Override @Nonnull synchronized DescribeMetadataResult describeMetadata(); @Override @Nonnull synchronized DescribeMetadataResult describeMetadata(double apiVersion);  }