this.serverTimestamp = pConnection.getServerTimestamp().getTimestamp().getTime(); if ( log.isDebug() ) { BaseMessages.getString( PKG, "SalesforceInput.Log.ServerTimestamp", getServerTimestamp() );
@Override public com.sforce.soap.partner.IGetServerTimestampResult getServerTimestamp() throws com.sforce.ws.ConnectionException { return connection.getServerTimestamp(); }
public boolean isValid() { if(partnerConnection != null) { try { partnerConnection.getServerTimestamp(); return true; } catch (Throwable t) { LogManager.logTrace(LogConstants.CTX_CONNECTOR, "Caught Throwable in isAlive", t); //$NON-NLS-1$ } } return false; }
@Override public boolean start() throws IOException { PartnerConnection connection = ((SalesforceSource) getCurrentSource()).connect(container).connection; try { Calendar serverTimestamp = connection.getServerTimestamp().getTimestamp(); if (serverTimestamp != null) { result = serverTimestamp.getTimeInMillis(); } if (result != null) { dataCount++; return true; } else { return false; } } catch (ConnectionException e) { throw new IOException(e); } }
@Override public boolean start() throws IOException { ConnectionHolder ch = ((SalesforceSource) getCurrentSource()).connect(container); PartnerConnection connection = ch.connection; if (ch.bulkConnection != null) { LOGGER.info(MESSAGES.getMessage("info.bulkConnectionUsage")); } try { Calendar serverTimestamp = connection.getServerTimestamp().getTimestamp(); if (serverTimestamp != null) { long timestamp = serverTimestamp.getTimeInMillis(); result = new GenericData.Record(properties.schema.schema.getValue()); result.put(0, timestamp); } if (result != null) { dataCount++; return true; } else { return false; } } catch (ConnectionException e) { throw new IOException(e); } }
@Override public boolean start() throws IOException { ConnectionHolder ch = ((SalesforceSource) getCurrentSource()).connect(container); PartnerConnection connection = ch.connection; if (ch.bulkConnection != null) { LOGGER.info(MESSAGES.getMessage("info.bulkConnectionUsage")); } try { Calendar serverTimestamp = connection.getServerTimestamp().getTimestamp(); if (serverTimestamp != null) { long timestamp = serverTimestamp.getTimeInMillis(); result = new GenericData.Record(properties.schema.schema.getValue()); result.put(0, timestamp); } if (result != null) { dataCount++; return true; } else { return false; } } catch (ConnectionException e) { throw new IOException(e); } }