text:
using base::Time;
using base::TimeDelta;
using content::BrowserThread;

namespace extensions {

const char ExtensionDownloader::kBlacklistAppID[] = "com.google.crx.blacklist";

namespace {

const net::BackoffEntry::Policy kDefaultBackoffPolicy = {
    // Number of initial errors (in sequence) to ignore before applying
    // exponential back-off rules.
    0,

    // Initial delay for exponential back-off in ms.
    2000,

    // Factor by which the waiting time will be multiplied.
    2,

    // Fuzzing percentage. ex: 10% will spread requests randomly
    // between 90%-100% of the calculated time.
    0.1,

    // Maximum amount of time we are willing to delay our request in ms.
    -1,

    // Time to keep an entry from being discarded even when it
    // has no significant state, -1 to never discard.
    -1,

    // Don't use initial delay unless the last request was an error.
    false,
};

const char kAuthUserQueryKey[] = "authuser";

const int kMaxAuthUserValue = 10;
const int kMaxOAuth2Attempts = 3;

const char kNotFromWebstoreInstallSource[] = "notfromwebstore";
const char kDefaultInstallSource[] = "";
const char kReinstallInstallSource[] = "reinstall";

const char kGoogleDotCom[] = "google.com";
const char kTokenServiceConsumerId[] = "extension_downloader";
const char kWebstoreOAuth2Scope[] =
    "https://www.googleapis.com/auth/chromewebstore.readonly";

ExtensionDownloaderTestDelegate* g_test_delegate = nullptr;

#define RETRY_HISTOGRAM(name, retry_count, url)                           \
  if ((url).DomainIs(kGoogleDotCom)) {                                    \
    UMA_HISTOGRAM_CUSTOM_COUNTS("Extensions." name "RetryCountGoogleUrl", \
                                retry_count,                              \
                                1,                                        \
                                kMaxRetries,                              \
                                kMaxRetries + 1);                         \
  } else {                                                                \
    UMA_HISTOGRAM_CUSTOM_COUNTS("Extensions." name "RetryCountOtherUrl",  \
                                retry_count,                              \
                                1,                                        \
                                kMaxRetries,                              \
                                kMaxRetries + 1);                         \
  }

bool ShouldRetryRequest(const net::URLRequestStatus& status,
                        int response_code) {
  // Retry if the response code is a server error, or the request failed because
  // of network errors as opposed to file errors.
  return ((response_code >= 500 && status.is_success()) ||
          status.status() == net::URLRequestStatus::FAILED);
}

// This parses and updates a URL query such that the value of the |authuser|
// query parameter is incremented by 1. If parameter was not present in the URL,
// it will be added with a value of 1. All other query keys and values are
// preserved as-is. Returns |false| if the user index exceeds a hard-coded
// maximum.
bool IncrementAuthUserIndex(GURL* url) {
  int user_index = 0;
  std::string old_query = url->query();
  std::vector<std::string> new_query_parts;
  url::Component query(0, old_query.length());
  url::Component key, value;
  while (url::ExtractQueryKeyValue(old_query.c_str(), &query, &key, &value)) {
    std::string key_string = old_query.substr(key.begin, key.len);
    std::string value_string = old_query.substr(value.begin, value.len);
    if (key_string == kAuthUserQueryKey) {
      base::StringToInt(value_string, &user_index);
    } else {
      new_query_parts.push_back(base::StringPrintf(
          "%s=%s", key_string.c_str(), value_string.c_str()));
    }
  }
  if (user_index >= kMaxAuthUserValue)
    return false;
  new_query_parts.push_back(
      base::StringPrintf("%s=%d", kAuthUserQueryKey, user_index + 1));
  std::string new_query_string = base::JoinString(new_query_parts, "&");
  url::Component new_query(0, new_query_string.size());
  url::Replacements<char> replacements;
  replacements.SetQuery(new_query_string.c_str(), new_query);
  *url = url->ReplaceComponents(replacements);
  return true;
}

}  // namespace

UpdateDetails::UpdateDetails(const std::string& id,
                             const base::Version& version)
    : id(id), version(version) {}

UpdateDetails::~UpdateDetails() {
}

ExtensionDownloader::ExtensionFetch::ExtensionFetch()
    : url(), credentials(CREDENTIALS_NONE) {
}

ExtensionDownloader::ExtensionFetch::ExtensionFetch(
    const std::string& id,
    const GURL& url,
    const std::string& package_hash,
    const std::string& version,
    const std::set<int>& request_ids)
    : id(id),
      url(url),
      package_hash(package_hash),
      version(version),
      request_ids(request_ids),
      credentials(CREDENTIALS_NONE),
      oauth2_attempt_count(0) {
}

ExtensionDownloader::ExtensionFetch::~ExtensionFetch() {
}

ExtensionDownloader::ExtraParams::ExtraParams() : is_corrupt_reinstall(false) {}

ExtensionDownloader::ExtensionDownloader(
    ExtensionDownloaderDelegate* delegate,
    net::URLRequestContextGetter* request_context)
    : OAuth2TokenService::Consumer(kTokenServiceConsumerId),
      delegate_(delegate),
      request_context_(request_context),
      manifests_queue_(&kDefaultBackoffPolicy,
                       base::Bind(&ExtensionDownloader::CreateManifestFetcher,
                                  base::Unretained(this))),
      extensions_queue_(&kDefaultBackoffPolicy,
                        base::Bind(&ExtensionDownloader::CreateExtensionFetcher,
                                   base::Unretained(this))),
      extension_cache_(NULL),
      weak_ptr_factory_(this) {
  DCHECK(delegate_);
  DCHECK(request_context_.get());
}

ExtensionDownloader::~ExtensionDownloader() {
}

bool ExtensionDownloader::AddExtension(const Extension& extension,
                                       int request_id) {
  // Skip extensions with empty update URLs converted from user
  // scripts.
  if (extension.converted_from_user_script() &&
      ManifestURL::GetUpdateURL(&extension).is_empty()) {
    return false;
  }

  ExtraParams extra;

  // If the extension updates itself from the gallery, ignore any update URL
  // data.  At the moment there is no extra data that an extension can
  // communicate to the the gallery update servers.
  std::string update_url_data;
  if (!ManifestURL::UpdatesFromGallery(&extension))
    extra.update_url_data = delegate_->GetUpdateUrlData(extension.id());

  return AddExtensionData(
      extension.id(), *extension.version(), extension.GetType(),
      ManifestURL::GetUpdateURL(&extension), extra, request_id);
}

bool ExtensionDownloader::AddPendingExtension(const std::string& id,
                                              const GURL& update_url,
                                              bool is_corrupt_reinstall,
                                              int request_id) {
  // Use a zero version to ensure that a pending extension will always
  // be updated, and thus installed (assuming all extensions have
  // non-zero versions).
  base::Version version("0.0.0.0");
  DCHECK(version.IsValid());
  ExtraParams extra;
  if (is_corrupt_reinstall)
    extra.is_corrupt_reinstall = true;

  return AddExtensionData(id, version, Manifest::TYPE_UNKNOWN, update_url,
                          extra, request_id);
}

void ExtensionDownloader::StartAllPending(ExtensionCache* cache) {
  if (cache) {
    extension_cache_ = cache;
    extension_cache_->Start(base::Bind(&ExtensionDownloader::DoStartAllPending,
                                       weak_ptr_factory_.GetWeakPtr()));
  } else {
    DoStartAllPending();
  }
}

void ExtensionDownloader::DoStartAllPending() {
  ReportStats();
  url_stats_ = URLStats();

  for (FetchMap::iterator it = fetches_preparing_.begin();
       it != fetches_preparing_.end();
       ++it) {
    std::vector<std::unique_ptr<ManifestFetchData>>& list = it->second;
    for (size_t i = 0; i < list.size(); ++i)
      StartUpdateCheck(std::move(list[i]));
  }
  fetches_preparing_.clear();
}

void ExtensionDownloader::StartBlacklistUpdate(
    const std::string& version,
    const ManifestFetchData::PingData& ping_data,
    int request_id) {
  // Note: it is very important that we use the https version of the update
  // url here to avoid DNS hijacking of the blacklist, which is not validated
  // by a public key signature like .crx files are.
  std::unique_ptr<ManifestFetchData> blacklist_fetch(CreateManifestFetchData(
      extension_urls::GetWebstoreUpdateUrl(), request_id));
  DCHECK(blacklist_fetch->base_url().SchemeIsCryptographic());
  blacklist_fetch->AddExtension(kBlacklistAppID, version, &ping_data,
                                std::string(), kDefaultInstallSource);
  StartUpdateCheck(std::move(blacklist_fetch));
}

void ExtensionDownloader::SetWebstoreIdentityProvider(
    std::unique_ptr<IdentityProvider> identity_provider) {
  identity_provider_.swap(identity_provider);
}

// static
void ExtensionDownloader::set_test_delegate(
    ExtensionDownloaderTestDelegate* delegate) {
  g_test_delegate = delegate;
}

bool ExtensionDownloader::AddExtensionData(const std::string& id,
                                           const base::Version& version,
                                           Manifest::Type extension_type,
                                           const GURL& extension_update_url,
                                           const ExtraParams& extra,
                                           int request_id) {
  GURL update_url(extension_update_url);
  // Skip extensions with non-empty invalid update URLs.
  if (!update_url.is_empty() && !update_url.is_valid()) {
    DLOG(WARNING) << "Extension " << id << " has invalid update url "
                  << update_url;
    return false;
  }

  // Make sure we use SSL for store-hosted extensions.
  if (extension_urls::IsWebstoreUpdateUrl(update_url) &&
      !update_url.SchemeIsCryptographic())
    update_url = extension_urls::GetWebstoreUpdateUrl();

  // Skip extensions with empty IDs.
  if (id.empty()) {
    DLOG(WARNING) << "Found extension with empty ID";
    return false;
  }

  if (update_url.DomainIs(kGoogleDotCom)) {
    url_stats_.google_url_count++;
  } else if (update_url.is_empty()) {
    url_stats_.no_url_count++;
    // Fill in default update URL.
    update_url = extension_urls::GetWebstoreUpdateUrl();
  } else {
    url_stats_.other_url_count++;
  }

  switch (extension_type) {
    case Manifest::TYPE_THEME:
      ++url_stats_.theme_count;
      break;
    case Manifest::TYPE_EXTENSION:
    case Manifest::TYPE_USER_SCRIPT:
      ++url_stats_.extension_count;
      break;
    case Manifest::TYPE_HOSTED_APP:
    case Manifest::TYPE_LEGACY_PACKAGED_APP:
      ++url_stats_.app_count;
      break;
    case Manifest::TYPE_PLATFORM_APP:
      ++url_stats_.platform_app_count;
      break;
    case Manifest::TYPE_UNKNOWN:
    default:
      ++url_stats_.pending_count;
      break;
  }

  DCHECK(!update_url.is_empty());
  DCHECK(update_url.is_valid());

  std::string install_source = extension_urls::IsWebstoreUpdateUrl(update_url)
                                   ? kDefaultInstallSource
                                   : kNotFromWebstoreInstallSource;
  if (extra.is_corrupt_reinstall)
    install_source = kReinstallInstallSource;

  ManifestFetchData::PingData ping_data;
  ManifestFetchData::PingData* optional_ping_data = NULL;
  if (delegate_->GetPingDataForExtension(id, &ping_data))
    optional_ping_data = &ping_data;

  // Find or create a ManifestFetchData to add this extension to.
  bool added = false;
  FetchMap::iterator existing_iter =
      fetches_preparing_.find(std::make_pair(request_id, update_url));
  if (existing_iter != fetches_preparing_.end() &&
      !existing_iter->second.empty()) {
    // Try to add to the ManifestFetchData at the end of the list.
    ManifestFetchData* existing_fetch = existing_iter->second.back().get();
    if (existing_fetch->AddExtension(id, version.GetString(),
                                     optional_ping_data, extra.update_url_data,
                                     install_source)) {
      added = true;
    }
  }
  if (!added) {
    // Otherwise add a new element to the list, if the list doesn't exist or
    // if its last element is already full.
    std::unique_ptr<ManifestFetchData> fetch(
        CreateManifestFetchData(update_url, request_id));
    ManifestFetchData* fetch_ptr = fetch.get();
    fetches_preparing_[std::make_pair(request_id, update_url)].push_back(
        std::move(fetch));
    added = fetch_ptr->AddExtension(id, version.GetString(), optional_ping_data,
                                    extra.update_url_data, install_source);
    DCHECK(added);
  }

  return true;
}

void ExtensionDownloader::ReportStats() const {
  UMA_HISTOGRAM_COUNTS_100("Extensions.UpdateCheckExtension",
                           url_stats_.extension_count);
  UMA_HISTOGRAM_COUNTS_100("Extensions.UpdateCheckTheme",
                           url_stats_.theme_count);
  UMA_HISTOGRAM_COUNTS_100("Extensions.UpdateCheckApp", url_stats_.app_count);
  UMA_HISTOGRAM_COUNTS_100("Extensions.UpdateCheckPackagedApp",
                           url_stats_.platform_app_count);
  UMA_HISTOGRAM_COUNTS_100("Extensions.UpdateCheckPending",
                           url_stats_.pending_count);
  UMA_HISTOGRAM_COUNTS_100("Extensions.UpdateCheckGoogleUrl",
                           url_stats_.google_url_count);
  UMA_HISTOGRAM_COUNTS_100("Extensions.UpdateCheckOtherUrl",
                           url_stats_.other_url_count);
  UMA_HISTOGRAM_COUNTS_100("Extensions.UpdateCheckNoUrl",
                           url_stats_.no_url_count);
}

void ExtensionDownloader::StartUpdateCheck(
    std::unique_ptr<ManifestFetchData> fetch_data) {
  if (g_test_delegate) {
    g_test_delegate->StartUpdateCheck(this, delegate_, std::move(fetch_data));
    return;
  }

  const std::set<std::string>& id_set(fetch_data->extension_ids());

  if (!ExtensionsBrowserClient::Get()->IsBackgroundUpdateAllowed()) {
    NotifyExtensionsDownloadFailed(id_set,
                                   fetch_data->request_ids(),
                                   ExtensionDownloaderDelegate::DISABLED);
    return;
  }

  RequestQueue<ManifestFetchData>::iterator i;
  for (i = manifests_queue_.begin(); i != manifests_queue_.end(); ++i) {
    if (fetch_data->full_url() == i->full_url()) {
      // This url is already scheduled to be fetched.
      i->Merge(*fetch_data);
      return;
    }
  }

  if (manifests_queue_.active_request() &&
      manifests_queue_.active_request()->full_url() == fetch_data->full_url()) {
    manifests_queue_.active_request()->Merge(*fetch_data);
  } else {
    UMA_HISTOGRAM_COUNTS(
        "Extensions.UpdateCheckUrlLength",
        fetch_data->full_url().possibly_invalid_spec().length());

    manifests_queue_.ScheduleRequest(std::move(fetch_data));
  }
}

void ExtensionDownloader::CreateManifestFetcher() {
  if (VLOG_IS_ON(2)) {
    std::vector<std::string> id_vector(
        manifests_queue_.active_request()->extension_ids().begin(),
        manifests_queue_.active_request()->extension_ids().end());
    std::string id_list = base::JoinString(id_vector, ",");
    VLOG(2) << "Fetching " << manifests_queue_.active_request()->full_url()
            << " for " << id_list;
  }

  manifest_fetcher_ = net::URLFetcher::Create(
      kManifestFetcherId, manifests_queue_.active_request()->full_url(),
      net::URLFetcher::GET, this);
  manifest_fetcher_->SetRequestContext(request_context_.get());
  manifest_fetcher_->SetLoadFlags(net::LOAD_DO_NOT_SEND_COOKIES |
                                  net::LOAD_DO_NOT_SAVE_COOKIES |
                                  net::LOAD_DISABLE_CACHE);
  // Update checks can be interrupted if a network change is detected; this is
  // common for the retail mode AppPack on ChromeOS. Retrying once should be
  // enough to recover in those cases; let the fetcher retry up to 3 times
  // just in case. http://crosbug.com/130602
  manifest_fetcher_->SetAutomaticallyRetryOnNetworkChanges(3);
  manifest_fetcher_->Start();
}

void ExtensionDownloader::OnURLFetchComplete(const net::URLFetcher* source) {
  VLOG(2) << source->GetResponseCode() << " " << source->GetURL();

  if (source == manifest_fetcher_.get()) {
    std::string data;
    source->GetResponseAsString(&data);
    OnManifestFetchComplete(source->GetURL(),
                            source->GetStatus(),
                            source->GetResponseCode(),
                            source->GetBackoffDelay(),
                            data);
  } else if (source == extension_fetcher_.get()) {
    OnCRXFetchComplete(source,
                       source->GetURL(),
                       source->GetStatus(),
                       source->GetResponseCode(),
                       source->GetBackoffDelay());
  } else {
    NOTREACHED();
  }
}

void ExtensionDownloader::OnManifestFetchComplete(
    const GURL& url,
    const net::URLRequestStatus& status,
    int response_code,
    const base::TimeDelta& backoff_delay,
    const std::string& data) {
  // We want to try parsing the manifest, and if it indicates updates are
  // available, we want to fire off requests to fetch those updates.
  if (status.status() == net::URLRequestStatus::SUCCESS &&
      (response_code == 200 || (url.SchemeIsFile() && data.length() > 0))) {
    RETRY_HISTOGRAM("ManifestFetchSuccess",
                    manifests_queue_.active_request_failure_count(),
                    url);
    VLOG(2) << "beginning manifest parse for " << url;
    scoped_refptr<SafeManifestParser> safe_parser(new SafeManifestParser(
        data,
        base::Bind(
            &ExtensionDownloader::HandleManifestResults,
            weak_ptr_factory_.GetWeakPtr(),
            base::Owned(manifests_queue_.reset_active_request().release()))));
    safe_parser->Start();
  } else {
    VLOG(1) << "Failed to fetch manifest '" << url.possibly_invalid_spec()
            << "' response code:" << response_code;
    if (ShouldRetryRequest(status, response_code) &&
        manifests_queue_.active_request_failure_count() < kMaxRetries) {
      manifests_queue_.RetryRequest(backoff_delay);
    } else {
      RETRY_HISTOGRAM("ManifestFetchFailure",
                      manifests_queue_.active_request_failure_count(),
                      url);
      NotifyExtensionsDownloadFailed(
          manifests_queue_.active_request()->extension_ids(),
          manifests_queue_.active_request()->request_ids(),
          ExtensionDownloaderDelegate::MANIFEST_FETCH_FAILED);
    }
  }
  manifest_fetcher_.reset();
  manifests_queue_.reset_active_request();

  // If we have any pending manifest requests, fire off the next one.
  manifests_queue_.StartNextRequest();
}

void ExtensionDownloader::HandleManifestResults(
    const ManifestFetchData* fetch_data,
    const UpdateManifest::Results* results) {
  // Keep a list of extensions that will not be updated, so that the |delegate_|
  // can be notified once we're done here.
  std::set<std::string> not_updated(fetch_data->extension_ids());

  if (!results) {
    VLOG(2) << "parsing manifest failed (" << fetch_data->full_url() << ")";
    NotifyExtensionsDownloadFailed(
        not_updated, fetch_data->request_ids(),
        ExtensionDownloaderDelegate::MANIFEST_INVALID);
    return;
  } else {
    VLOG(2) << "parsing manifest succeeded (" << fetch_data->full_url() << ")";
  }

  // Examine the parsed manifest and kick off fetches of any new crx files.
  std::vector<int> updates;
  DetermineUpdates(*fetch_data, *results, &updates);
  for (size_t i = 0; i < updates.size(); i++) {
    const UpdateManifest::Result* update = &(results->list.at(updates[i]));
    const std::string& id = update->extension_id;
    not_updated.erase(id);

    GURL crx_url = update->crx_url;
    if (id != kBlacklistAppID) {
      NotifyUpdateFound(update->extension_id, update->version);
    } else {
      // The URL of the blacklist file is returned by the server and we need to
      // be sure that we continue to be able to reliably detect whether a URL
      // references a blacklist file.
      DCHECK(extension_urls::IsBlacklistUpdateUrl(crx_url)) << crx_url;

      // Force https (crbug.com/129587).
      if (!crx_url.SchemeIsCryptographic()) {
        url::Replacements<char> replacements;
        std::string scheme("https");
        replacements.SetScheme(scheme.c_str(),
                               url::Component(0, scheme.size()));
        crx_url = crx_url.ReplaceComponents(replacements);
      }
    }
    std::unique_ptr<ExtensionFetch> fetch(
        new ExtensionFetch(update->extension_id, crx_url, update->package_hash,
                           update->version, fetch_data->request_ids()));
    FetchUpdatedExtension(std::move(fetch));
  }

  // If the manifest response included a <daystart> element, we want to save
  // that value for any extensions which had sent a ping in the request.
  if (fetch_data->base_url().DomainIs(kGoogleDotCom) &&
      results->daystart_elapsed_seconds >= 0) {
    Time day_start =
        Time::Now() - TimeDelta::FromSeconds(results->daystart_elapsed_seconds);

    const std::set<std::string>& extension_ids = fetch_data->extension_ids();
    std::set<std::string>::const_iterator i;
    for (i = extension_ids.begin(); i != extension_ids.end(); i++) {
      const std::string& id = *i;
      ExtensionDownloaderDelegate::PingResult& result = ping_results_[id];
      result.did_ping = fetch_data->DidPing(id, ManifestFetchData::ROLLCALL);
      result.day_start = day_start;
    }
  }

  NotifyExtensionsDownloadFailed(
      not_updated, fetch_data->request_ids(),
      ExtensionDownloaderDelegate::NO_UPDATE_AVAILABLE);
}

void ExtensionDownloader::DetermineUpdates(
    const ManifestFetchData& fetch_data,
    const UpdateManifest::Results& possible_updates,
    std::vector<int>* result) {
  for (size_t i = 0; i < possible_updates.list.size(); i++) {
    const UpdateManifest::Result* update = &possible_updates.list[i];
    const std::string& id = update->extension_id;

    if (!fetch_data.Includes(id)) {
      VLOG(2) << "Ignoring " << id << " from this manifest";
      continue;
    }

    if (VLOG_IS_ON(2)) {
      if (update->version.empty())
        VLOG(2) << "manifest indicates " << id << " has no update";
      else
        VLOG(2) << "manifest indicates " << id << " latest version is '"
                << update->version << "'";
    }

    if (!delegate_->IsExtensionPending(id)) {
      // If we're not installing pending extension, and the update
      // version is the same or older than what's already installed,
      // we don't want it.
      std::string version;
      if (!delegate_->GetExtensionExistingVersion(id, &version)) {
        VLOG(2) << id << " is not installed";
        continue;
      }

      VLOG(2) << id << " is at '" << version << "'";

      base::Version existing_version(version);
      base::Version update_version(update->version);
      if (!update_version.IsValid() ||
          update_version.CompareTo(existing_version) <= 0) {
        continue;
      }
    }

    // If the update specifies a browser minimum version, do we qualify?
    if (update->browser_min_version.length() > 0 &&
        !ExtensionsBrowserClient::Get()->IsMinBrowserVersionSupported(
            update->browser_min_version)) {
      // TODO(asargent) - We may want this to show up in the extensions UI
      // eventually. (http://crbug.com/12547).
      DLOG(WARNING) << "Updated version of extension " << id
                    << " available, but requires chrome version "
                    << update->browser_min_version;
      continue;
    }
    VLOG(2) << "will try to update " << id;
    result->push_back(i);
  }
}

// Begins (or queues up) download of an updated extension.
void ExtensionDownloader::FetchUpdatedExtension(
    std::unique_ptr<ExtensionFetch> fetch_data) {
  if (!fetch_data->url.is_valid()) {
    // TODO(asargent): This can sometimes be invalid. See crbug.com/130881.
    DLOG(WARNING) << "Invalid URL: '" << fetch_data->url.possibly_invalid_spec()
                  << "' for extension " << fetch_data->id;
    return;
  }

  for (RequestQueue<ExtensionFetch>::iterator iter = extensions_queue_.begin();
       iter != extensions_queue_.end();
       ++iter) {
    if (iter->id == fetch_data->id || iter->url == fetch_data->url) {
      iter->request_ids.insert(fetch_data->request_ids.begin(),
                               fetch_data->request_ids.end());
      return;  // already scheduled
    }
  }

  if (extensions_queue_.active_request() &&
      extensions_queue_.active_request()->url == fetch_data->url) {
    extensions_queue_.active_request()->request_ids.insert(
        fetch_data->request_ids.begin(), fetch_data->request_ids.end());
  } else {
    std::string version;
    if (extension_cache_ &&
        extension_cache_->GetExtension(fetch_data->id, fetch_data->package_hash,
                                       NULL, &version) &&
        version == fetch_data->version) {
      base::FilePath crx_path;
      // Now get .crx file path and mark extension as used.
      extension_cache_->GetExtension(fetch_data->id, fetch_data->package_hash,
                                     &crx_path, &version);
      NotifyDelegateDownloadFinished(std::move(fetch_data), true, crx_path,
                                     false);
    } else {
      extensions_queue_.ScheduleRequest(std::move(fetch_data));
    }
  }
}

void ExtensionDownloader::NotifyDelegateDownloadFinished(
    std::unique_ptr<ExtensionFetch> fetch_data,
    bool from_cache,
    const base::FilePath& crx_path,
    bool file_ownership_passed) {
  // Dereference required params before passing a scoped_ptr.
  const std::string& id = fetch_data->id;
  const std::string& package_hash = fetch_data->package_hash;
  const GURL& url = fetch_data->url;
  const std::string& version = fetch_data->version;
  const std::set<int>& request_ids = fetch_data->request_ids;
  delegate_->OnExtensionDownloadFinished(
      CRXFileInfo(id, crx_path, package_hash), file_ownership_passed, url,
      version, ping_results_[id], request_ids,
      from_cache ? base::Bind(&ExtensionDownloader::CacheInstallDone,
                              weak_ptr_factory_.GetWeakPtr(),
                              base::Passed(&fetch_data))
                 : ExtensionDownloaderDelegate::InstallCallback());
  if (!from_cache)
    ping_results_.erase(id);
}

void ExtensionDownloader::CacheInstallDone(
    std::unique_ptr<ExtensionFetch> fetch_data,
    bool should_download) {
  ping_results_.erase(fetch_data->id);
  if (should_download) {
    // Resume download from cached manifest data.
    extensions_queue_.ScheduleRequest(std::move(fetch_data));
  }
}

void ExtensionDownloader::CreateExtensionFetcher() {
  const ExtensionFetch* fetch = extensions_queue_.active_request();
  extension_fetcher_ = net::URLFetcher::Create(kExtensionFetcherId, fetch->url,
                                               net::URLFetcher::GET, this);
  extension_fetcher_->SetRequestContext(request_context_.get());
  extension_fetcher_->SetAutomaticallyRetryOnNetworkChanges(3);

  int load_flags = net::LOAD_DISABLE_CACHE;
  bool is_secure = fetch->url.SchemeIsCryptographic();
  if (fetch->credentials != ExtensionFetch::CREDENTIALS_COOKIES || !is_secure) {
    load_flags |= net::LOAD_DO_NOT_SEND_COOKIES | net::LOAD_DO_NOT_SAVE_COOKIES;
  }
  extension_fetcher_->SetLoadFlags(load_flags);

  // Download CRX files to a temp file. The blacklist is small and will be
  // processed in memory, so it is fetched into a string.
  if (fetch->id != kBlacklistAppID) {
    extension_fetcher_->SaveResponseToTemporaryFile(
        BrowserThread::GetTaskRunnerForThread(BrowserThread::FILE));
  }

  if (fetch->credentials == ExtensionFetch::CREDENTIALS_OAUTH2_TOKEN &&
      is_secure) {
    if (access_token_.empty()) {
      // We should try OAuth2, but we have no token cached. This
      // ExtensionFetcher will be started once the token fetch is complete,
      // in either OnTokenFetchSuccess or OnTokenFetchFailure.
      DCHECK(identity_provider_.get());
      OAuth2TokenService::ScopeSet webstore_scopes;
      webstore_scopes.insert(kWebstoreOAuth2Scope);
      access_token_request_ =
          identity_provider_->GetTokenService()->StartRequest(
              identity_provider_->GetActiveAccountId(), webstore_scopes, this);
      return;
    }
    extension_fetcher_->AddExtraRequestHeader(
        base::StringPrintf("%s: Bearer %s",
                           net::HttpRequestHeaders::kAuthorization,
                           access_token_.c_str()));
  }

  VLOG(2) << "Starting fetch of " << fetch->url << " for " << fetch->id;
  extension_fetcher_->Start();
}

void ExtensionDownloader::OnCRXFetchComplete(
    const net::URLFetcher* source,
    const GURL& url,
    const net::URLRequestStatus& status,
    int response_code,
    const base::TimeDelta& backoff_delay) {
  ExtensionFetch& active_request = *extensions_queue_.active_request();
  const std::string& id = active_request.id;
  if (status.status() == net::URLRequestStatus::SUCCESS &&
      (response_code == 200 || url.SchemeIsFile())) {
    RETRY_HISTOGRAM("CrxFetchSuccess",
                    extensions_queue_.active_request_failure_count(),
                    url);
    base::FilePath crx_path;
    // Take ownership of the file at |crx_path|.
    CHECK(source->GetResponseAsFilePath(true, &crx_path));
    std::unique_ptr<ExtensionFetch> fetch_data =
        extensions_queue_.reset_active_request();
    if (extension_cache_) {
      const std::string& version = fetch_data->version;
      const std::string& expected_hash = fetch_data->package_hash;
      extension_cache_->PutExtension(
          id, expected_hash, crx_path, version,
          base::Bind(&ExtensionDownloader::NotifyDelegateDownloadFinished,
                     weak_ptr_factory_.GetWeakPtr(), base::Passed(&fetch_data),
                     false));
    } else {
      NotifyDelegateDownloadFinished(std::move(fetch_data), false, crx_path,
                                     true);
    }
  } else if (IterateFetchCredentialsAfterFailure(
                 &active_request, status, response_code)) {
    extensions_queue_.RetryRequest(backoff_delay);
  } else {
    const std::set<int>& request_ids = active_request.request_ids;
    const ExtensionDownloaderDelegate::PingResult& ping = ping_results_[id];
    VLOG(1) << "Failed to fetch extension '" << url.possibly_invalid_spec()
            << "' response code:" << response_code;
    if (ShouldRetryRequest(status, response_code) &&
        extensions_queue_.active_request_failure_count() < kMaxRetries) {
      extensions_queue_.RetryRequest(backoff_delay);
    } else {
      RETRY_HISTOGRAM("CrxFetchFailure",
                      extensions_queue_.active_request_failure_count(),
                      url);
      // status.error() is 0 (net::OK) or negative. (See net/base/net_errors.h)
      UMA_HISTOGRAM_SPARSE_SLOWLY("Extensions.CrxFetchError", -status.error());
      delegate_->OnExtensionDownloadFailed(
          id, ExtensionDownloaderDelegate::CRX_FETCH_FAILED, ping, request_ids);
    }
    ping_results_.erase(id);
    extensions_queue_.reset_active_request();
  }

  extension_fetcher_.reset();

  // If there are any pending downloads left, start the next one.
  extensions_queue_.StartNextRequest();
}

void ExtensionDownloader::NotifyExtensionsDownloadFailed(
    const std::set<std::string>& extension_ids,
    const std::set<int>& request_ids,
    ExtensionDownloaderDelegate::Error error) {
  for (std::set<std::string>::const_iterator it = extension_ids.begin();
       it != extension_ids.end();
       ++it) {
    const ExtensionDownloaderDelegate::PingResult& ping = ping_results_[*it];
    delegate_->OnExtensionDownloadFailed(*it, error, ping, request_ids);
    ping_results_.erase(*it);
  }
}

void ExtensionDownloader::NotifyUpdateFound(const std::string& id,
                                            const std::string& version) {
  UpdateDetails updateInfo(id, base::Version(version));
  content::NotificationService::current()->Notify(
      extensions::NOTIFICATION_EXTENSION_UPDATE_FOUND,
      content::NotificationService::AllBrowserContextsAndSources(),
      content::Details<UpdateDetails>(&updateInfo));
}

bool ExtensionDownloader::IterateFetchCredentialsAfterFailure(
    ExtensionFetch* fetch,
    const net::URLRequestStatus& status,
    int response_code) {
  bool auth_failure = status.status() == net::URLRequestStatus::CANCELED ||
                      (status.status() == net::URLRequestStatus::SUCCESS &&
                       (response_code == net::HTTP_UNAUTHORIZED ||
                        response_code == net::HTTP_FORBIDDEN));
  if (!auth_failure) {
    return false;
  }
  // Here we decide what to do next if the server refused to authorize this
  // fetch.
  switch (fetch->credentials) {
    case ExtensionFetch::CREDENTIALS_NONE:
      if (fetch->url.DomainIs(kGoogleDotCom) && identity_provider_) {
        fetch->credentials = ExtensionFetch::CREDENTIALS_OAUTH2_TOKEN;
      } else {
        fetch->credentials = ExtensionFetch::CREDENTIALS_COOKIES;
      }
      return true;
    case ExtensionFetch::CREDENTIALS_OAUTH2_TOKEN:
      fetch->oauth2_attempt_count++;
      // OAuth2 may fail due to an expired access token, in which case we
      // should invalidate the token and try again.
      if (response_code == net::HTTP_UNAUTHORIZED &&
          fetch->oauth2_attempt_count <= kMaxOAuth2Attempts) {
        DCHECK(identity_provider_.get());
        OAuth2TokenService::ScopeSet webstore_scopes;
        webstore_scopes.insert(kWebstoreOAuth2Scope);
        identity_provider_->GetTokenService()->InvalidateAccessToken(
            identity_provider_->GetActiveAccountId(), webstore_scopes,
            access_token_);
        access_token_.clear();
        return true;
      }
      // Either there is no Gaia identity available, the active identity
      // doesn't have access to this resource, or the server keeps returning
      // 401s and we've retried too many times. Fall back on cookies.
      if (access_token_.empty() || response_code == net::HTTP_FORBIDDEN ||
          fetch->oauth2_attempt_count > kMaxOAuth2Attempts) {
        fetch->credentials = ExtensionFetch::CREDENTIALS_COOKIES;
        return true;
      }
      // Something else is wrong. Time to give up.
      return false;
    case ExtensionFetch::CREDENTIALS_COOKIES:
      if (response_code == net::HTTP_FORBIDDEN) {
        // Try the next session identity, up to some maximum.
        return IncrementAuthUserIndex(&fetch->url);
      }
      return false;
    default:
      NOTREACHED();
  }
  NOTREACHED();
  return false;
}

void ExtensionDownloader::OnGetTokenSuccess(
    const OAuth2TokenService::Request* request,
    const std::string& access_token,
    const base::Time& expiration_time) {
  access_token_ = access_token;
  extension_fetcher_->AddExtraRequestHeader(
      base::StringPrintf("%s: Bearer %s",
                         net::HttpRequestHeaders::kAuthorization,
                         access_token_.c_str()));
  extension_fetcher_->Start();
}

void ExtensionDownloader::OnGetTokenFailure(
    const OAuth2TokenService::Request* request,
    const GoogleServiceAuthError& error) {
  // If we fail to get an access token, kick the pending fetch and let it fall
  // back on cookies.
  extension_fetcher_->Start();
}

ManifestFetchData* ExtensionDownloader::CreateManifestFetchData(
    const GURL& update_url,
    int request_id) {
  ManifestFetchData::PingMode ping_mode = ManifestFetchData::NO_PING;
  if (update_url.DomainIs(ping_enabled_domain_.c_str()))
    ping_mode = ManifestFetchData::PING_WITH_ENABLED_STATE;
  return new ManifestFetchData(
      update_url, request_id, brand_code_, manifest_query_params_, ping_mode);
}

}  // namespace extensions


Rev a shelf tall pantry pull out tall wall filler inch. Rev a shelf 4wdp18 45 45in pantry door unit only. Rev a shelf 66quot; kitchen pantry reviews allmodern. Rev a shelf pull out pantry review. 18 polymer full circle pantry cabinet lazy susan, rev a. Rev a shelf tall pullout wood pantry (item#448 tp51 8 1). Rev a shelf pantry vitanmedinfo.
Excellent fireplace mantel shelves the homy design. Winsome timothy 3 x 3 cube shelf with baskets reviews wayfair. Moon to moon: etsy focus stone and violet. 1, 2, 3, 4 tier wooden bookcase shelving display storage. Landforms found on the ocean floor. Wood box for veritas shelf pin drilling jig pocket holes. Wall mount bracket shelf for av component tv cable box stb. 97 elf on the shelf girl light walmart com the elf on. Wall mount stainless steel nickel brushed bathroom bath. Walk in beer cooler shelving beer keg racks and cooler. Set of 4 rectangle floating wall storage multi colours.
Floating shelves for tv living room modern with cube eames. Wall mount corner shelf for tv. 20 ways to incorporate wall mounted tvs and shelves into. Diy entertainment centers ideas 4423 decorathing. Ikon white floating tv unit medium delux deco. Amazing floating entertainment shelf center glass for. Basement remodel contemporary basement dc metro.


text:
Research brings personalized medicine to treat leukemia one step closer
by University of Birmingham
Bone marrow aspirate showing acute myeloid leukemia. Several blasts have Auer rods. Credit: Wikipedia
Scientists at the University of Birmingham have revealed the roles that different types of gene mutations play in causing blood cancers in a study that was the culmination of a decade's research.
The findings of the team, led by Professor Constanze Bonifer and Professor Peter Cockerill of the University of Birmingham's Institute of Cancer and Genomic Studies, mean doctors are now one step closer to being able to provide tailored and targeted treatment specific to individual patients—increasing their chances of survival.
The team, funded by blood cancer research charity Bloodwise, has spent the last 10 years carrying out a painstaking global analysis of the cells of patients diagnosed with acute myeloid leukaemia (AML), the results of which are published today in Nature Genetics.
AML is an aggressive cancer of the white blood cells, called myeloid cells, which normally function to fight bacterial infections and eliminate parasites from the body.
By picking apart the mutated cells in AML patients and gathering big data on each of them, the researchers were able to study the basic building blocks that control the production of these abnormal cells.
This step-by-step process, carried out in collaboration with Professor Mike Griffiths and his team at the West Midlands Regional Genetics Laboratory at Birmingham Women's and Children's NHS Foundation Trust, identified the main trigger points where critical mutations feed through to other genes that control the cells' identity and behaviour.
Lead author Professor Constanze Bonifer said: "In acute myeloid leukaemia, genes are targeted by mutations that encode either master regulators controlling cell identity or factors transmitting signals through the cell, therefore the normal process of turning genes on or off is defunct.
"Our research found that, when this happens, the cells step sideways from their normal developmental programme and speed out of control.
"Crucially, AML cells from patients with the same types of mutations always take the same route when they head off in the wrong direction. "Our analyses of each of the pathways that the cells took when developing into cancer identified key points in the cell that could be used in the future to target and develop new drugs to treat each type of AML in a different way."
Co-lead author Professor Peter Cockerill said: "Doctors in Birmingham are already testing AML patients for the many different mutations that cause AML. However, now they know which genes are the most important for each type of AML.
"This means that personalised medicine will one day become a reality for blood cell cancers, which will see a different drug being given to treat each form of AML, creating personalised treatment for each cancer patient depending on the mutation that has caused their disease."
Dr. Alasdair Rankin, Director of Research at Bloodwise, said: "Although a handful of targeted drugs have recently become available for people with acute myeloid leukaemia, they only help a small number of people.
"We need to be smarter about matching the right treatment to the right person if we want to boost survival rates for AML, especially if there are already drugs out there that can help. "These landmark research findings will act as a blueprint for how to tackle this, and could even help with the delivery of personalised medicine in mainstream healthcare in the future."
This study comes after research, by the same team at the University of Birmingham in collaboration with Professor Olaf Heidenreich's team at Newcastle University, was published last month (October) in Cancer Cell (i), which focussed on just one type of DNA mutation in AML to study a single pathway to cancer development.
The researchers found that a growth-promoting gene, called CCND2, was crucial for the survival of this type of cancer cell and, significantly, it was found that an already approved breast cancer drug called palbociclib designed to inhibit CCDN2 was able to block tumour development—therefore identifying it as a drug that could be used to target and treat AML.
Also in the same issue of Cancer Cell (ii) published in October the University of Birmingham team—this time in collaboration with scientists led by Professor Jan Jacob Schuringa at the University of Groningen in the Netherlands—published further research aimed at advancing tailored and targeted treatment for AML patients.
Of this research, Professor Bonifer explains: "Acute myeloid leukaemia is made up of several groups of cells with different combinations of mutations, some of which are so aggressive they allow these cancer cells to survive after treatment.
"Often these combinations of mutations are present before treatment, but we have never previously been able to identify them when a patient is first diagnosed with AML—meaning that the cancer can later return as a different disease which is often more aggressive.
"Our research in collaboration with the University of Groningen identified how to makes it possible to identify these cells when patients are first diagnosed with AML so that they can be treated with the right combination of drugs."
Breast cancer drug could be used to treat life-threatening leukaemia
More information: Salam A. Assi et al, Subtype-specific regulatory network rewiring in acute myeloid leukemia, Nature Genetics (2018). DOI: 10.1038/s41588-018-0270-1
(i) Natalia Martinez-Soria et al. The Oncogenic Transcription Factor RUNX1/ETO Corrupts Cell Cycle Regulation to Drive Leukemic Transformation, Cancer Cell (2018). DOI: 10.1016/j.ccell.2018.08.015
(ii) Bauke de Boer et al. Prospective Isolation and Characterization of Genetically and Functionally Distinct AML Subclones, Cancer Cell (2018). DOI: 10.1016/j.ccell.2018.08.014
Journal information: Cancer Cell , Nature Genetics
Provided by University of Birmingham
Citation: Research brings personalized medicine to treat leukemia one step closer (2018, November 12) retrieved 17 July 2019 from https://medicalxpress.com/news/2018-11-personalized-medicine-leukemia-closer.html
Study leads to breakthrough in better understanding acute myeloid leukemia
Could immune system spark new therapies for hard-to-treat blood cancer?
Opening the door to the cause of myeloid leukemia: Finding the targets of common mutation
Scientists map the genetic evolution of childhood leukaemia
Two drugs are better than one in fight against leukaemia

redpajama_set_name: RedPajamaCommonCrawl


text:
Jason Martin, Ed.D.
Academic Libraries and Leadership
Creating an Emotionally Intelligent Library Culture
The webinar PPT is available here.
Bradberry, T. & Geaves, J. (2009). Emotional Intelligence 2.0. San Diego: Talent Smart.
Goleman, D. (1998). Working with emotional intelligence. Bantam Books.
Goleman, D. (2004). What makes a leader? Harvard Business Review, 82(1), 82-91.
Goleman, D. (2005). Emotional intelligence. New York: Bantam Books.
Goleman, D., Boyatzs, R. & McKee, A. (2013). Primal leadership: Unleashing the power of emotional intelligence. Boston: Harvard Business Review Press.
HBR's 10 must reads on emotional intelligence. (2015). Boston: Harvard Business Review Press.
HBR guide to emotional intelligence. (2017). Boston: Harvard Business Review Press.
Hougaard, R. & Carter, J. (2018). The mind of the leader. Boston: Harvard Business Review Press.
Hernon, P. & Rossieter, N. (2006). Emotional intelligence: Which traits are most prized? College and Research Libraries, 67(3), 260-275.
Kreitz, P. (2009). Leadership and emotional intelligence: A study of university library directors and their senior management teams. College & Research Libraries, 70(6), 531-554.
Leeder, K. (2013). Someday when I am incompetent…": Reflections on the Peter Principle, leadership, and emotional intelligence. In the Library with the Lead Pipe.
Martin, J. (2019). Library leadership your way. Chicago: ALA Editions
Martin, J. (2019). Emotional intelligence, emotional culture, and library leadership. Library Leadership & Management 33(2).
Martin, J. (2018). Leading in the present: Mindfulness for library leadership. Library Leadership & Management 33(1).
Martin, J. (2016). Emotionally intelligent leadership at 30 Rock: What librarians can learn from a case study of comedy writers. Journal of Library Administration, 56(4), 345-358.
Matthews, G., Zeidner, M., & Roberts, R. D. (2012). Emotional intelligence 101. New York: Springer.
Sadri, G., Weber, T., & Gentry, W. (2011). Empathic emotion and leadership performance: An empirical analysis across 38 countries. The Leadership Quarterly, 22(5), 818-830.
Salovey, P. & Mayer, J. (1990). Emotional intelligence. Imagination, Cognition, and Personality, 9(3), 185-211.
Vakola, M., Tsaousis, I., & Nikolaou, I. (2004). The role of emotional intelligence and personality variables on attitudes toward organisational change. Journal of Managerial Psychology, 19(1/2), 88-110.
Here is an interview I did for MTSU On the Record, a news program for WMOT 89.5, about this webinar and emotional intelligence.
A short video from the same interview.


text:
package qwop.spiderman2;

import java.util.concurrent.CountDownLatch;

/**
 * CountDownLatch这个类能够使一个线程等待其他线程完成各自的工作后再执行。
 * 例如,应用程序的主线程希望在负责启动框架服务的线程已经启动所有的框架服务之后再执行。
 CountDownLatch是通过一个计数器来实现的,计数器的初始值为线程的数量。
    每当一个线程完成了自己的任务后,计数器的值就会减1。当计数器值到达0时,
    它表示所有的线程已经完成了任务,然后在闭锁上等待的线程就可以恢复执行任务。
 * <Short overview of features> <Features detail>
 *
 * @author qwop
 * @date May 13, 2017
 * @version [The version number, May 13, 2017]
 * @see [Related classes/methods]
 * @since [Products/Module version]
 */
public class CountDownLatchTest {
    public static void main(String[] args) throws Exception {
        new Driver().main();
    }
}

class Driver { // ...
    private static final int N = 10;

    void main() throws InterruptedException {
        CountDownLatch startSignal = new CountDownLatch(1);
        CountDownLatch doneSignal = new CountDownLatch(N);

        for (int i = 0; i < N; ++i) // create and start threads
            new Thread(new Worker(startSignal, doneSignal)).start();

        doSomethingElse(); // don't let run yet
        startSignal.countDown(); // let all threads proceed
        doSomethingElse();
        doneSignal.await(); // wait for all to finish
    }

    private void doSomethingElse() {
       System.out.println(" do something else ");
    }
}

class Worker implements Runnable {
    private final CountDownLatch startSignal;

    private final CountDownLatch doneSignal;

    Worker(CountDownLatch startSignal, CountDownLatch doneSignal) {
        this.startSignal = startSignal;
        this.doneSignal = doneSignal;
    }

    public void run() {
        try {
            startSignal.await();
            doWork();
            doneSignal.countDown();
        }
        catch (InterruptedException ex) {
        } // return;
    }

    void doWork() throws InterruptedException {
       for ( int i = 0; i < 10 ; i++ ) {
            System.out.println( Thread.currentThread().getName() +  " working " + i );
            Thread.sleep( 1000 );
        }
    }
}

redpajama_set_name: RedPajamaGithub


That is highly creative. Mine never go missing, but they ARE ugly.
Never in a million years would I have thought I would hear you say the words "Send me pics of your toilet." and "cute" all in the same breath.
THE POWER OF CHRIST COMPELS YOU!!!!!!!!!!!!!!!!!!!!!! THE POWER OF CHRIST COMPELS YOU!!!!!!!!!!!!
That's fantastic!! Haha. Cool idea.
You show such flair my Lady of the Loo. No wonder you have such an adoring public queueing up behind me.
You are so awesome! 🙂 You know, I probably should have mentioned in the post that once the salt and pepper shakers become toilet decor, they should NOT be again used as shakers! 😉 Good grief…can you imagine? Ewww!!!
Love it–touché for re-purposing! You are a clever one. I wonder if pets or little people find interest enough to play with it while on the bathroom floor?
Why thank you! It's so much nicer having something cute there. So far my wily little kitties have not disturbed them. Fingers crossed. 🙂 HUGS!!!!
Thank ya, doll. I have a a chubby little fox sitting on the screw in my "no-penises-allowed" bathroom. He's so cute!


If you haven't noticed, the end of the school year is upon us. My son's last day was yesterday. Most kids throughout central Texas end either this week or next week. Every school in the US is looking at a room full of hyper and dysregulated children. The last few weeks of school seem to be a free-for-all, which has always perplexed me and I find myself wondering "Why don't they just let those kids out early?" But I guess if the last day of school was May 15, then the weeks leading up to May 15 would be the same free-for-all.
Why is the end of the year so hard for our kids of trauma?
MAJOR transition. Of course you already know this, but any transition is hard for our children's nervous systems. Different = danger. Different puts their nervous system at the edge of fight/flight/freeze as they prepare for any unexpected danger that might come their way.
MAJOR loss! Loss of teachers and friends can have a tremendous impact on a child who has already experienced the unimaginable loss of a first-parent. As kids become more and more dysregulated, they start to function out of lower and lower areas of their brain. As they go lower into their brain, they start to lose their sense of time. Temporary pauses in relationships seem like forever endings. "See you in August!" means nothing to a child who is dysregulated and operating out of their limbic brain.
MAJOR unpredictability. School provides an amount of structure that most trauma mommas can't recreate at home. For many kids of trauma, the structure of school is safe and predictable. Of course, there are children who are so stressed out by the demands of school that any benefits of structure are really lost on them, but for those kids who thrive in the structure of school, transitioning into summer is very difficult.
So, what are some things you can do?
Rest assured that all kids and parents are going out of their minds right now. Even kids without developmental trauma are struggling through this transition.
Check out what your scared momma thoughts are in the trauma tornado. "I'll never survive the summer!" Or maybe it's "My kid does so much better at school than at home with me- why does she hate me?" Whatever your scared momma belief is, tune into it, assess if it's accurate (it's probably not), and do a quick check of step one and two of Developing your Trauma Momma Super Powers…how did trauma impact your child's ability to transition, manage loss, and deal with loss of structure? Practice strengthening your four super powers and replace your scared momma thoughts with those true thoughts.
Provide as much structure as possible! Maybe that means summer camp. Maybe that means scheduled and structured days. Most trauma kids can't handle lazy mornings, breakfast whenever, cartoons, getting dressed around 11am, and then thinking about some activities to do for the day. Make a daily schedule and stick with it. Pick out activities to do ahead of time and give your child the information about the day at the time you know works for them. Some kids need it in the morning or the night before. Some need it a week before. Some kids would go crazy anticipating a fun event for over a week. You know your child best!
Stay connected with other trauma mommas! Do you need help and support to practice your super powers and jump out of the trauma tornado? I started a Facebook group "Trauma Mommas with Super Powers!" with the intent of bringing trauma mommas together to provide that support for each other. Come check it out! It's brand new so I'd love to get it started during this tough time of year for trauma mommas.
Take care of yourself! Remember that our nervous systems will match each other. If you can keep your nervous system regulated, you're giving your child the opportunity to borrow that energy. If you stay dysregulated, your child's dysregulation will continue to spiral in the trauma tornado. Your own regulated nervous system isn't a cure for your child, but it sure does help.


PuppyFinder.com is your source for finding an ideal Basset Artesian Normand Puppy for Sale in USA. Browse thru our ID Verified puppy for sale listings to find your perfect puppy in your area.
Sorry, there are no Basset Artesian Normand puppies for sale at this time.
You can browse thru list of Basset Artesian Normand Breeders or consider adopting Basset Artesian Normand dog. See dog breeds similar to Basset Artesian Normand .


Who is liable for a parking lot slip and fall?
On behalf of Susan Fuller & Associates, P.C. posted in premises liability on Friday, October 19, 2018.
The weather is already turning cold and damp -- and it won't be long before ice and snow are on the ground. When that happens, you can be sure that one more thing is soon to follow: slip and fall accidents.
On behalf of Susan Fuller & Associates, P.C. on Thursday, October 18, 2018.
Experiencing sexual harassment at work can be terrifying. You might not know what to do next because you are afraid that your job may be on the line. Your employer's reaction to a complaint can be unpredictable; however, it is important to know that you are protected by certain laws.
On behalf of Susan Fuller & Associates, P.C. posted in dui on Thursday, October 4, 2018.
The biggest threat to your civil rights is simply not being aware of them in the first place. Unless you know your rights, it's difficult to assert them with confidence during a traffic stop -- and you can't expect the police to guide you!


text:
require "spec_helper"

describe Statesman::Adapters::ActiveRecordQueries, active_record: true do
  before do
    prepare_model_table
    prepare_transitions_table
    prepare_other_model_table
    prepare_other_transitions_table
  end

  before do
    Statesman.configure { storage_adapter(Statesman::Adapters::ActiveRecord) }
  end
  after { Statesman.configure { storage_adapter(Statesman::Adapters::Memory) } }

  before do
    MyActiveRecordModel.send(:include, Statesman::Adapters::ActiveRecordQueries)
    MyActiveRecordModel.class_eval do
      def self.transition_class
        MyActiveRecordModelTransition
      end

      def self.initial_state
        :initial
      end
    end

    OtherActiveRecordModel.send(:include,
                                Statesman::Adapters::ActiveRecordQueries)
    OtherActiveRecordModel.class_eval do
      def self.transition_class
        OtherActiveRecordModelTransition
      end

      def self.initial_state
        :initial
      end
    end
  end
  before { MyActiveRecordModel.send(:has_one, :other_active_record_model) }
  before { OtherActiveRecordModel.send(:belongs_to, :my_active_record_model) }

  let!(:model) do
    model = MyActiveRecordModel.create
    model.state_machine.transition_to(:succeeded)
    model
  end

  let!(:other_model) do
    model = MyActiveRecordModel.create
    model.state_machine.transition_to(:failed)
    model
  end

  let!(:initial_state_model) { MyActiveRecordModel.create }

  let!(:returned_to_initial_model) do
    model = MyActiveRecordModel.create
    model.state_machine.transition_to(:failed)
    model.state_machine.transition_to(:initial)
    model
  end

  describe ".in_state" do
    context "given a single state" do
      subject { MyActiveRecordModel.in_state(:succeeded) }

      it { is_expected.to include model }
      it { is_expected.not_to include other_model }
    end

    context "given multiple states" do
      subject { MyActiveRecordModel.in_state(:succeeded, :failed) }

      it { is_expected.to include model }
      it { is_expected.to include other_model }
    end

    context "given the initial state" do
      subject { MyActiveRecordModel.in_state(:initial) }

      it { is_expected.to include initial_state_model }
      it { is_expected.to include returned_to_initial_model }
    end

    context "given an array of states" do
      subject { MyActiveRecordModel.in_state([:succeeded, :failed]) }

      it { is_expected.to include model }
      it { is_expected.to include other_model }
    end

    context "merging two queries" do
      subject do
        MyActiveRecordModel.in_state(:succeeded).
          joins(:other_active_record_model).
          merge(OtherActiveRecordModel.in_state(:initial))
      end

      it { is_expected.to be_empty }
    end
  end

  describe ".not_in_state" do
    context "given a single state" do
      subject { MyActiveRecordModel.not_in_state(:failed) }
      it { is_expected.to include model }
      it { is_expected.not_to include other_model }
    end

    context "given multiple states" do
      subject { MyActiveRecordModel.not_in_state(:succeeded, :failed) }
      it do
        is_expected.to match_array([initial_state_model,
                                    returned_to_initial_model])
      end
    end

    context "given an array of states" do
      subject { MyActiveRecordModel.not_in_state([:succeeded, :failed]) }
      it do
        is_expected.to match_array([initial_state_model,
                                    returned_to_initial_model])
      end
    end
  end

  context "with a transition name" do
    before do
      MyActiveRecordModel.send(:has_many,
                               :custom_name,
                               class_name: 'MyActiveRecordModelTransition')
      MyActiveRecordModel.class_eval do
        def self.transition_name
          :custom_name
        end
      end
    end

    describe ".in_state" do
      subject(:query) { MyActiveRecordModel.in_state(:succeeded) }
      specify { expect { query }.to_not raise_error }
    end
  end
end


Optimized Multicolor Immunofluorescence Panel (OMIP) is a special peer-reviewed Cytometry Part A publication type that reports on newly designed and optimized multicolor panels for flow cytometry, fluorescence microscopy, image cytometry, and other polychromatic fluorescence-based methods. The first two OMIPs were published in the September 2010 issue of the Journal.
OMIPs are aimed: (1) to alleviate the development time for researchers in need of the same or highly similar panels, (2) to provide a starting point for the creation of novel OMIPs, and (3) to give the developers of the panels credit via citation or the publication.
An online component includes significant amount of technical details, such as panel development strategy, cross-references to related panels, exact staining protocol, instrument configuration and reagent information.
OMIP-001: Quality and phenotype of Ag-responsive human T-cells.
OMIP-002: Phenotypic analysis of specific human CD8 T-cells using peptide-MHC class I multimers for any of four epitopes.
OMIP-010: A new 10-color monoclonal antibody panel for polychromatic immunophenotyping of small hematopoietic cell samples.
OMIP-013: Differentiation of human T-cells.
OMIP-020: Phenotypic characterization of human γδ T-cells by multicolor flow cytometry.


text:
13 thoughts on "Victim impact statement"
david.markey@mail.com on September 2, 2015 at 11:52 am said:
Interesting read and found some very substantiated trends in my own situation.
Fact: This November my son will be 17. I last had contact with him on the 10th of December 1999. I sort the legal avenue until I became financially and mentally exhausted. His Mother succeeded in her wishes to sever the relationship between Father and son as a means of a final act of abuse and defiance to the separation.
Every attempt to retain any form of contact has been maliciously vandalized.
I have had no alternative other then to move on with my life although barely a day goes by of which I do not think of him.
I had hoped the Family Law would of matured enough by this day and age to recognize and place counter measures to this behavior for what it is – Parental Alienation, the ultimate weapon of domestic abuse.
Unfortunately despite the extensive research and reporting of this issue, the Family Court has failed to manifest this tort of law. The tort however does not result in legal liability but that of a disastrous social liability.
Kids First - Children's Rights Activists (CRA) on September 7, 2015 at 7:38 am said:
Definition of family violence etc.
(1) For the purposes of this Act, family violence means violent, threatening or other behaviour by a person that coerces or controls a member of the person's family (the family member ), or causes the family member to be fearful.
(i) preventing the family member from making or keeping connections with his or her family, friends or culture; or
(j) unlawfully depriving the family member, or any member of the family member's family, of his or her liberty.
http://fathersaustralia.com/study-law-courses-online-australia/family-law-act-1975-sect-4ab/
"Destroy the family, you destroy the country." Vladimir Ilyich Lenin Who in their right mind would in a constitutional monarchy create a secret star camber court then make our sworn enemies, Marxist feminist chief justice, that has clear intentions breaking honest hard working real people, the back bone of our society. We have got to target these traffickers and criminals who are managing promoting and selling this human trade, trafficking in human suffering, we are determined to put an end to this vile trade, trade in human life, trade in human death.
We have got to put the blame squarely at the appalling human traffickers, we now need to do everything we can using a comprehensive approach.
These traffickers are utterly ruthless, they just want the cash, once they have the cash the deal is done.
Every Australian Dad needs to join a political party today and lobby for justice. http://fathersaustralia.com/
Quotes by Vladimir Lenin
When one makes a Revolution, one cannot mark time; one must always go forward — or go back. He who now talks about the freedom of the press goes backward, and halts our headlong course towards Socialism.
Literature must become party literature. Down with unpartisan litterateurs! Down with the superman of literature! Literature must become a part of the general cause of the proletariat.
http://www.austlii.edu.au/au/legis/cth/consol_act/fla1975114/s121.html
The real issue is no moral compass especially from our civil service employee's, illegitimate authority, is a clear indicator of APD [sociopaths and psychopaths].
1% of the population have Antisocial Personality Disorder APD [ref DSM5] that is 230,000 psychopaths in Australia alone. Worldwide 70,000,000.
APD [psychopaths] is why we are always at war, they are genetically flawed, disposing them to be criminally and morally insane.
So where are they all, Terrorist States, ISIS, socialist states, civil services? Seems psychopaths gravitate to positions of power it is their nature.
Australia is experiencing a massive constitutional crisis, 21 Billion PA wasted on fraudulent socialist services corruption in family court alone, 21 deaths per week by way of suicide, where is the public outcry here?,
Our courts and civil services are awash with fraud and political corruption, especially here in Queensland.
I Have been in family court for 5 years on proven via confession of false allegations of DV, against fraudulent socialist services corruption by Legal Aid Queensland they still won't let my 5yo son see me, despite court orders, anyone like to try explaining that?
Please stop funding legal aid Queensland socialist corruption and their feminists agenda.
Please ask the [our] government.
1. Do they employ psychopaths in civil services?
2. How many psychopaths are employed in or civil services?
3. Why are they employing psychopaths in civil services?
4. Have they warned the people they are employing psychopaths in civil services?
http://fathersaustralia.com/dsm-5/
DadMan on June 24, 2015 at 10:16 am said:
Am a single father (in Canada) with sole custody of a young child. My child was criminally abducted to another country by the mother and eventually the child was located, rescued and returned home by myself. It seems to me that the searching parents (of missing or abducted children) who are more likely to find and return their children are those who take what i would call immediate and decisive action, (including sometimes moving to the country where the child has been taken to and searching full-time until the child is rescued). Examples of parents who have done this are Damien Gayle (London, England), Sean Felton (England), Henry da Massa (Manchester, England), Stephen Watkins (Ontario, Canada), Joe Chisholm who searched for 18 1/2 years (Toronto, Ontario, Canada) and Australia's Ken Thompson. The family law systems (and the Hague Convention on the Civil Aspects of International Child Abduction) around the world are at best blunt instruments (to resolve a conflict between parents) or inadequate and often destructive (to a child's well-being and life). There are small, secretive organizations which will help a parent (only with proven legal custody) locate and rescue an abducted child, some for free (charities).
The following ideas are my opinions, based on experience and research (of other successful searching parents). You must research the law in the country where the child has been taken to and how deeply rooted corruption is in that country before planning any such action. You should make the other parent aware that you will never give up searching for your child, no matter how many years it may take and that you are willing to sacrifice your own life to protect and rescue your child. You must be willing to die, to sacrifice your own life, if necessary, to get your child back home alive. Cut off every source of income to the abusive parent. Enlist the aid of every person you can find who will help you in the country where the child is being held. Martin Luther King, Jr. once said that you don't have to see all the stairs to take the first step and this may be good advice. You may have to find a way to move to the country where the child is, for however long it may take, to establish a parental relationship with the child and to, sooner or later, find and rescue the child. Even the countries which seem to be the most dangerous (due to violence and corruption usually) can be livable places if you understand how things work in reality and can hide your fear. Basically, you have to find a way to make possible what seems impossible and take the necessary action.
Whatever you do or do not do (to find and rescue your daughter), you must assume your daughter will, some day, some year, learn about what you did or did not do to rescue her. Even if your actions don't result in the rescue of your child, she will know you tried and took action well beyond what anyone could have expected of you. If you do get her back, she will know that your love for her is boundless. Actions speak louder than words, always.
The comments above are in response to the comments posted by Wayne Kilowsky (on June 12, 2015). In Canada a parent has the responsibility and the right to remove his child from the other parent's care if the person (or somebody associated with the abusive parent) is actually or is suspected of abusing (or seriously neglecting) the child, even if removing the child from that person's care would otherwise be contrary to a court order. An example would be a court order that you must return the child to the other parent (after a visit) by a certain day of the week and at a certain time but when you try to do so the other person is found to be drunk or otherwise intoxicated or unconscious, which would mean you would be responsible for taking the child into your care and control (even though a court order states otherwise).
wayne kilowsky on June 12, 2015 at 10:03 pm said:
My now 10yr old half thai daughter is being prostituted regularly for 3yrs by ex wife thai mother under a deal with DCP here but organised unbeknown to me back in thai before we even met to have babies to aust or canadian men and groom them then separate and pimp them or supply pedophile parties ect but has had 2 suicide attemps since age 7 and theres nothing I can do after over 3yrs family court and 140k+ and theres 2 others same age one male the other female and of lao desent in same position ? but with no one at all to help them cept me any help muchley appreciated wayne
Kids First - Children's Rights Activists (CRA) on June 13, 2015 at 4:20 am said:
The members of Luke's Army are here for support and to use the group as a healthy way of expressing emotion and frustration at a failing system. Many victims of child protection have been abused by the psychological and medical professionals they were referred to by child protection.
This group is designed to be a safe place where people can safely discuss their troubles, not a place for vindictive child protection staff to come looking for ammunition to use against already devastated and victimised parents..
We also welcome foster carers, foster children, child protection workers current and previous, even politicians and media are welcome as is the general public who wish to see an end to the tyranny which portrays itself as child protection. https://www.facebook.com/groups/LukesArmy/?fref=ts
Anonymous on June 13, 2015 at 8:37 am said:
Well that's it for family court and still in shock but not from loosing but how blatently corrupt it is and how many people know it is and/or are involved and must say I feel ashamed and betrayed by Australia for turning the other cheek on the most vile piece of shit pedo judges and their supporters and the horror the kids have got to through getting raped daly with again lots of people in the know and nothing done and these are not my people but where are they as Ive been serching for over 2yrs and still not a fucking sniff ? but what is needed is somebody with you that knows abit and never go alone as I did because then they know and team together and use you to "mop the floor" and get away with illeagal stuff that we don't know about
Genetics tell us psychopaths are inhuman, non human species. Socialism feminism fascism islamism capitalism communism are all psychopathic manifestations. "All animals are equal, but some animals are more equal than others." http://en.wikipedia.org/wiki/Animal_Farm
Dear Friend, We have got to target these traffickers and criminals who are managing promoting and selling this human trade, trafficking in human suffering, we are determined to put an end to this vile trade, trade in human life, trade in human death.
Every Australian Dad needs to join a political party today and lobby for justice.
http://fathersaustralia.com/
betrayedfathert on October 24, 2013 at 7:26 am said:
Thanks for getting to me so soon I will everything which you advised me and let you know of I need more help, much appreciated, thanks
Rohit on October 24, 2013 at 1:06 am said:
I was an international student and met an Australian girl and had a daughter with her. I paid child support and thousands of dollars to my ex-girl friend and to her mother for almost 4 years for my daughter and my partner and her mother ,but we broke up in March this year because she and her mother asks me for money all the time and said if I don not give them money they will not let me see my daughter, she says because I am not an Australian, so I do not have any rights in this Australian and every body will believe what ever she says. She told me that I am not the father of the child because she says she had sex with different guys when she was with me and I have not seen my daughter (which I am sure is mine) for last 7 months. Now I have trust issues, can not concentrate on my work, can't sleep properly at nights and my health is also effected. I really do not know what to do?
Kids First - Children's Rights Activists (CRA) on October 24, 2013 at 5:59 am said:
Hi Rohit,
I sugest you contact DIDSS Dads in Distress, and a Salvo's legal, let us know if there is anything we can do for you.
Steve FUA
http://fathersaustralia.com/links/links-in-general/
http://fathersaustralia.com/lawyers/salvos-legal/
http://fathersaustralia.com/contact/


text:
The Monroe–Ruston–Bastrop Combined Statistical Area is made up of four parishes in northern Louisiana. The statistical area consists of the Monroe Metropolitan Statistical Area, the Ruston Micropolitan Statistical Area, and the Bastrop Micropolitan Statistical Area. As of the 2010 census, the CSA had a population of 251,155.

Parishes
 Lincoln Parish
 Morehouse Parish
 Ouachita Parish
 Union Parish

Communities

Places with more than 50,000 people
 Monroe (Principal city)

Places with 10,000 to 25,000 people
 Ruston (Principal city)
 Bastrop (Principal city)
 West Monroe

Places with 5,000 to 10,000 people
 Brownsville–Bawcomville
 Claiborne

Places with fewer than 5,000 people
 Bernice
 Bonita
 Collinston
 Downsville
 Farmerville
 Lillie
 Marion
 Mer Rouge
 Oak Ridge
 Richwood
 Spearsville
 Sterlington
 Swartz

Demographics
As of the census of 2000, there were 201,074 people, 75,455 households, and 53,051 families residing within the CSA. The racial makeup of the CSA was 63.74% White, 34.49% African American, 0.21% Native American, 0.53% Asian, 0.02% Pacific Islander, 0.40% from other races, and 0.61% from two or more races. Hispanic or Latino of any race were 1.21% of the population.

The median income for a household in the CSA was $28,744, and the median income for a family was $35,866. Males had a median income of $31,165 versus $20,894 for females. The per capita income for the CSA was $15,033.

See also
 Louisiana census statistical areas
 List of cities, towns, and villages in Louisiana
 List of census-designated places in Louisiana

References

Geography of Ouachita Parish, Louisiana
Geography of Morehouse Parish, Louisiana
Geography of Union Parish, Louisiana
Combined statistical areas of the United States

redpajama_set_name: RedPajamaWikipedia


text:
Q&A: What do I do when I don't feel like striving anymore?
Q&A: What do I do when I don't feel like striving anymore? I know I'm supposed to, but it's brutal.
What an honest question.
You're right, sometimes friends and counsellors or others sometimes emphasise the need for us to strive. Often we know that we need to strive, but the issue is not knowing it, the issue is sometimes simply getting through it.
a) Where there's purpose, find it.
Think of the flight of the Holy Family to Egypt. I don't imagine it was pleasant for them to go to a different country on a night's notice. They were not rich by anyone's reckoning, they didn't know Egyptian, they didn't have relatives there, and they were treated really badly most of the time. There are stories of people who refused them food, refused them lodging, and left them out in the cold.
What made the striving bearable was the understanding of the necessity of the situation. If they didn't flee Israel, the baby would die. It was as simple as that. No beautiful words or soliloquies could change that reality.
So sometimes, we have to simply lock into the necessity without philosophising on anything else. Step out, look at the big question of "why", and then do what is needed for that why. Stopping to overly analyse will only add to your despair or make you focus energy somewhere not helpful to your plight. Imagine if the Family decided it wasn't worth it, or "what if instead we just tried such and such". Things would have been very different. Imagine if you are running for your life, and you stop to ask why you cannot have pizza right now like those people at the restaurant. Not the right time, keep running.
I guess that leads one to understand that sometimes the striving is actually the safest place to be.
b) When there's no purpose or injustice, live in the present moment.
Here, I think of Joseph. Sure, he was really annoying to his brothers, and sure, he was spoiled. Being thrown into a pit, however, was still an injustice. Being sold as a slave was an even greater injustice. Being imprisoned for refusing to commit adultery with his boss' wife, however, is egregiously unfair. Yet, we are not presented with a murmuring, angry young man. Instead, we find someone successful all the time.
I'm not using this example to irritate you, but only to say taht many of us in his position would be talking mostly about how unfair it was to go through all of this without doing anything wrong. Most of us would have given up on this God. Most of us would think, forget this, it's not worth it. Here I am in jail while corrupt people are rich and having the time of their lives. He didn't.
I think it's because he lived in the moment. He had hope, yes, but he also made the most of each day. He couldn't have gotten all these promotions, even in jail, simply by moping. Happiness will not come to us while wishing we were somewhere else, or that we had something else. Happiness will not come until you make wherever you are, where you want to be.
c) Don't misdirect blame.
Psalm 137 (By the rivers of Babylon…), is all about the sadness of exile, of even being taunted during the hard times. What is not in the psalm, however, is blame. There is no blame, because the Israelites knew it was their fault. It was their own negligence and contempt that led to their captivity, not the ill-will of anyone else.
I will not dwell on this one, because I do not want to dwell on negativity or blame, but just to say, careful not to be angry at something that you might have caused. If you did cause it, relax, the captivity comes to an end. Keep your eyes on the opportunity for an escape.
d) Keep friends close, tell them to keep their sermons to themselves, but talk about it if you need
These periods are not often healthy to go through alone. Isolation can make anyone go mad who has not been trained in dealing with his or her own thoughts. This warfare is particularly seen in monastic circles, when a disciple will be tormented by his thoughts, especially of despair, and the smallest of thoughts can be amplified exponentially.
When David was being pursued by Saul, he took solace in his friendship with Jonathan. When our Lord went through the agony in the garden, He took three of His closes friends with Him, and yes, He called them friends. When Saint Moses was afflicted by thoughts night and day, he kept going back to his spiritual guide.
So, expose your thoughts, do not let them boil inside of you until you explode or doing something irrational. Talk about it with someone from whom you have no fear of judgment or ridiculing or belittling. These people do exist. Whether it's a spiritual father, mother, spouse, sibling, close friend, whoever it is that can give you some respite, take them up on it. I say this in the context of letting things out, but I do not suggest taking advice from just anyone either.
Call in your friends. Let your friends know that you might be a bummer to be around and that you thank them in advance for accepting it. If you don't need a sermon from them, let them know. Tell them that sometimes the comfort doesn't come from words, it comes from the companionship. Job's friends were probably really annoying when they were talking, but at the same time, it was probably a solace that they came at all to him when he smelled gross, was miserable, and his wife was in the corner cursing God. Not every friend is willing to put up with all of that, so use your friends, that's what they're there for.
e) Find love.
The thing that can give meaning to any suffering, is love. Love is what carried soldiers through war, that carries mothers through labour, that allows caregivers to give invalids…it's what allowed our Lord Jesus to surrender Himself to death.
Love is self-sacrifice. The more we are able to give to others during our times of self-pity, the stronger we are in combatting our feelings of contempt or our feeling that we cannot endure longer. My sister told me the remarkable story once of a friend of hers who lost her child. She did not just lose her child, she went through the torture of so many surgeries, so much false hope about the child's recovery, teetering from day to day about which day might be the child's last…That's a pain that I cannot even begin to fathom. That is a striving that I do not think I could personally endure.
Yet, this woman and her husband give love to their family, they bring joy to others, and they serve. Humans are relational, if you are not able to find a way to direct this love towards God Himself, do not despair. Do it to others in the name of Christ. He already said that everyone is Him, so tell Him, I'm loving this person in Your Name. I will give myself to others even in my pain. You will soon find your own therapy in the person or persons that you are serving. In doing this, you are learning the highest honour, martyrdom: because greater love has no man than this, but that He lay his life down for his friends (John 15:13).
Strife has a way of transforming us into loving and real human beings – if we allot it to do so.
f) Pray.
I really mean this. We scoff at it, but we rarely do it. Turn every sigh, every groan, every fit, every outburst, everything – turn it into prayer. Our Lord did this when He was in agony, the prophets, the apostles and the saints did this, and all of them found solace. If you talk to everyone but Him about your problems, you have not gotten a chance to have a dialogue.
And call upon me in the day of trouble: I will deliver thee (Psalm 50:15)
Put some effort into this. Try it out. If you do not know how, then ask.
g) Do stuff, don't just let yourself drown.
The analogy I will use here is not Biblical, but I like it. I think of someone who is on a ship at sea, and a storm comes and the ship is in great peril. Is there reason to panic? Of course. So shout, scream, sound alarms, and make as much noise as you can. That is wise. What would be unwise, however, is to not take the measures and steps needed to keep you from drowning in the meantime. Throw heavy cargo off the boat if that is helpful, do whatever is necessary to the sails, get your life jacket on in case you're thrown overboard, do whatever you need to do to ensure survival for the longest amount of time, until you either cannot do anything anymore, or help comes. I know it's hard to believe sometimes, but "at night there may be weeping, but in the morning joy" (Psalm 30:5), there's a great calm after a terrible storm.
There is way more that could be said – like reading stories of people with whom you can relate, different methods of thinking and various other things. But these are the things that came first to mind. Feel free to holler back if these are not what you are looking for, because there are a plethora of other things that one can do to get through things. I will close with one last piece of advice from the desert fathers, encouraging us to finish the strife in order to be transformed:
A certain elder said, "We often fail to advance because we know not the conditions of our strife, nor have we patience to complete the work we have begun. No virtue can be attained without toil."
Posted by Fr. Moses Samaan
His Eminence Metropolitan Serapion celebrated the Divine Liturgy at St. Verena & The Three Holy Youth Coptic Orthodox Church
On the Third Sunday of the blessed month of Tobe, January 29, 2023, His Eminence Metropolitan Serapion celebrated the Divine...
St. Athanasius and St. Cyril Coptic Theological School Officially Opens New Cutting-Edge Campus with Grand Opening Ceremony
The new 18,000-square-feet campus features facilities that will enhance student experienceand prepare future students to...
His Eminence Metropolitan Serapion Celebrates the Theophany Feast at St. Mark Coptic Orthodox Church
On the night of Wednesday, January 18, 2023, His Eminence Metropolitan Serapion celebrated the Divine Liturgy of Blessing of...
January 2023 Clergy Meeting at St. John Coptic Orthodox Church
On January 12, 2023, His Eminence Metropolitan, accompanied by His Grace Bishop Abraham, and His Grace Bishop Kyrillos, met...
His Eminence Metropolitan Serapion Celebrates the Divine Liturgy at St. Justina Coptic Orthodox Church
On the Fifth Sunday of the blessed month of Koiahk, January 8, 2023, His Eminence Metropolitan Serapion celebrated the Divine...


A ray of hope when antidepressants have failed!
Dealing with depression is not easy, but getting help can give you your life back. Challenge your negative thinking; the sooner you act, the sooner you can change.
According to the World Health Organization over 300 million people are affected by depression globally. It also predicts that by 2020, depression will rival heart disease as the health disorder with the highest global burden.
A new research published on the 7th of December 2012 by Dr.Nicola Wiles in Lancet, the very first large scale study trial carried out to look at the effectiveness of therapy (Cognitive Behavioural Therapy) that was given to people who were already on antidepressants. Research findings suggest that a combination of medication and therapy works when drug treatments alone have failed. It helps reducing depressive symptoms and improves quality of life. This further emphasizes the importance to investigate more on the alternative treatment options. The American Psychological Society urges "psychotherapy as depression treatment before pills".
Psychotherapy is a safe and very secure way to help patients to work through their problems, thus enhancing your mood , energy, improving job performance, satisfying relationships and being able to function effectively in other areas of life that have been negatively impacted by depression.
So if you are suffering from depression and feel that antidepressants are just not working, give psychotherapy a try!


An injury-stricken Manchester United frustrated Liverpool at Old Trafford holding Jurgen Klopp's men to a scoreless draw.
United lost three players to injury in the first 40 minutes with Ander Herrera, Juan Mata and Jesse Lingard all being forced off for Solskjaer's side.
Despite the injuries to their opponents, Liverpool struggled in the final third and could not muster up any clear-cut chances as their usually so potent front three looked poor throughout.
As the title race takes another twist, let's take a look at 12 quickfire conclusions from Manchester United's 0-0 draw with Liverpool.
1) Manchester United started the game allowing Liverpool the majority of the ball, dropping deep and looking to release their front three quick when back in possession. There was however a couple of occasions where United dropped too deep and allowed the away side into dangerous positions.
2) The injuries in the United ranks were absolutely massive in this game. Losing Herrera, Mata and Lingard in the space of 40 minutes was almost comically unlucky on Solskjaer's side.
3) Marcus Rashford also didn't look right in the first half. He was limping for a spell and couldn't find his usual form as he drifted out of the game.
4) Liverpool certainly should have opened the scoring in the first half considering their dominance in possession and the injuries in the United ranks. Klopp's men simply couldn't find the final ball in the last third required to break United down.
5) The introduction of Pereira was also a telling substitution. The Portuguese is a promising young player in the United ranks but Solskjaer opting for him instead of £52 million Fred in the same position could be an indication that the Brazilian isn't in his plans.
6) Credit to Peirera though, he and McTominay both performed very well in the Manchester United midfield given the circumstances.
7) Despite the injuries, the atmosphere at Old Trafford was excellent throughout the game. It's clear that the fans are very much behind Solskjaer and his side.
8) As the second half went on it appeared as though Liverpool were growing more desperate for the opener, trying to force the issue when a sense of calm and fluidity in the final third would have been required.
9) United grew into the second half performing excellently, shutting out Liverpool's attacks and battling in the midfield despite being short of experience.
10) A special mention to Luke Shaw also, who had a fantastic game up against Mo Salah and didn't give the Egyptian a sniff all afternoon at Old Trafford.
11) A draw at Old Trafford is not the end of the world for Liverpool but when you consider United's first-half struggles, it will be a point which will certainly frustrate Jurgen Klopp.
12) Solskjaer also proved that he can cope well with adversity and this will certainly be a point that will be looked upon as a positive for United. A far cry from the performance at Anfield in December which saw Mourinho sacked.