精华内容
下载资源
问答
  • Recovery

    2016-09-18 10:11:15
    Recovery
    项目地址:Recovery
    简介:Android Crash 自动恢复

    A crash recovery framework!


    Download build License

    中文文档

    Introduction

    Blog entry with introduction

    “Recovery” can help you to automatically handle application crash in runtime. It provides you with following functionality:

    • Automatic recovery activity with stack and data;
    • Ability to recover to the top activity;
    • A way to view and save crash info;
    • Ability to restart and clear the cache;
    • Allows you to do a restart instead of recovering if failed twice in one minute.

    Art

    recovery

    Usage

    Installation

    Using Gradle

    compile 'com.zxy.android:recovery:0.0.5'
    

    Using Maven

    <dependency>
          <groupId>com.zxy.android</groupId>
          <artifactId>recovery</artifactId>
          <version>0.0.5</version>
          <type>pom</type>
    </dependency>
    

    Initialization

    You can use this code sample to initialize Recovery in your application:

    Recovery.getInstance()
            .debug(true)
            .recoverInBackground(false)
            .recoverStack(true)
            .mainPage(MainActivity.class)
            .callback(new MyCrashCallback())
            .init(this);
    

    and grant permission:

    android.permission.GET_TASKS
    

    If you don't want to show the RecoveryActivity when the application crash in runtime,you can use silence recover to restore your application.

    You can use this code sample to initialize Recovery in your application:

    Recovery.getInstance()
            .debug(true)
            .recoverInBackground(false)
            .silent(false, Recovery.SilentMode.RECOVER_ACTIVITY_STACK)
            .init(this);
    

    Arguments

    Argument Type Function
    debug boolean Whether to open the debug mode
    recoverInBackgroud boolean When the App in the background, whether to restore the stack
    recoverStack boolean Whether to restore the activity stack, or to restore the top activity
    mainPage Class<? extends Activity> Initial page activity
    callback RecoveryCallback Crash info callback
    silent boolean,SilentMode Whether to use silence recover,if true it will not display RecoveryActivity and restore the activity stack automatically

    SilentMode

    1. RESTART - Restart App
    2. RECOVER_ACTIVITY_STACK - Restore the activity stack
    3. RECOVER_TOP_ACTIVITY - Restore the top activity
    4. RESTART_AND_CLEAR - Restart App and clear data

    Callback

    public interface RecoveryCallback {
    
        void stackTrace(String stackTrace);
    
        void cause(String cause);
    
        void exception(
            String throwExceptionType,
            String throwClassName,
            String throwMethodName,
            int throwLineNumber
        );
    }
    

    Custom Theme

    You can customize UI by setting these properties in your styles file:

    <color name="recoveryColorPrimary">#F44336</color>
    <color name="recoveryColorPrimaryDark">#D32F2F</color>
    <color name="recoveryColorAccent">#BDBDBD</color>
    <color name="recoveryTextColor">#FFFFFF</color>
    

    Crash File Path

    {SDCard Dir}/Android/data/{packageName}/files/recovery_crash/


    Update history

    VERSION-0.0.5——Support silent recovery

    LICENSE

       Copyright 2016 zhengxiaoyong
    
       Licensed under the Apache License, Version 2.0 (the "License");
       you may not use this file except in compliance with the License.
       You may obtain a copy of the License at
    
           http://www.apache.org/licenses/LICENSE-2.0
    
       Unless required by applicable law or agreed to in writing, software
       distributed under the License is distributed on an "AS IS" BASIS,
       WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
       See the License for the specific language governing permissions and
       limitations under the License.

    展开全文
  • recovery

    万次阅读 2012-06-13 12:29:57
    Recovery简介Android利用Recovery模式,进行恢复出厂设置,OTA升级,patch升级及firmware升级。 升级一般通过运行升级包中的META-INF/com/google/android/update-script脚本来执行自定义升级,脚本中是一组recovery...
    展开全文
  • recovery log输出机制: 1、在recovery mode下:adb pull /tmp/recovery.log %cd%/recovery.log 2、recovery mode 下 reboot 进入系统后: adb pull /cache/recovery %cd%/recovery 那问题来了,如何输出到uart?...

    recovery log输出机制:

    1、在recovery mode下:adb pull /tmp/recovery.log %cd%/recovery.log

    2、recovery mode 下 reboot 进入系统后: adb pull /cache/recovery %cd%/recovery

    那问题来了,如何输出到uart?

    直接修改\bootable\recovery\recovery.cpp:

    //static const char *TEMPORARY_LOG_FILE = "/tmp/recovery.log";

    static const char *TEMPORARY_LOG_FILE = "/dev/console";

    发现不行,加测试代码再加推论得出结论是selinux导致权限不够的原因,于是我直接把selinux关掉就可以了

    路径:system/core/init/init.cpp

    1. 方式一
    2.   static bool selinux_is_disabled(void)
    3.  {
    4.     if (ALLOW_DISABLE_SELINUX) {
    5.         if (access("/sys/fs/selinux", F_OK) != 0) {
    6.             return true;
    7.         }
    8.  
    9.         //return selinux_status_from_cmdline() == SELINUX_DISABLED;
    10.         改为:
    11.         return true;
    12.     }
    13.     return false;
    14.  }

    ——————————————android 7.1关闭selinux方法——————————————————

    /system/core/init/init.cpp

    selinux_status_from_cmdline函数:

    selinux_enforcing_status status = SELINUX_ENFORCING;

    改成: selinux_enforcing_status status = SELINUX_PERMISSIVE;

    从代码可看出,也可以修改cmdline来实现

    ————————————————————————————————————————————

    kernel :正常启动 make bootimage

    recovery 模式: make recoveryimage     out\target\product\msm8909\recovery\root\init更新

    https://blog.csdn.net/u010164190/article/details/78659476

    修改boot.image里面的cmdline 加权限:在commandline里加入androidboot.selinux=permissive

    http://www.miui.com/thread-9137678-1-1.html

    展开全文
  • 华为官方recovery

    千次下载 2015-03-30 12:08:54
    华为官方recovery,用于刷机,官方原生态,升级无忧!
  • Workflow Recovery

    2015-07-10 15:58:37
    Task Recovery Strategies Each task in a workflow has a recovery strategy. When the Integration Service recovers a workflow, it recovers tasks based on the recovery strategy: ¨ Restart task. When the

    Task Recovery Strategies

    Each task in a workflow has a recovery strategy. When the Integration Service recovers a workflow, it recovers tasks based on the recovery strategy:
    ¨ Restart task. When the Integration Service recovers a workflow, it restarts each recoverable task that is
    configured with a restart strategy. You can configure Session and Command tasks with a restart recovery
    strategy.
    All other tasks have a restart recovery strategy by default.
    ¨ Fail task and continue workflow. When the Integration Service recovers a workflow, it does not recover the
    task. The task status becomes failed, and the Integration Service continues running the workflow.
    Configure a fail recovery strategy if you want to complete the workflow, but you do not want to recover the task.
    You can configure Session and Command tasks with the fail task and continue workflow recovery strategy.
    ¨ Resume from the last checkpoint. The Integration Service recovers a stopped, aborted, or terminated
    session from the last checkpoint. You can configure a Session task with a resume strategy.

     

    Session Task Strategies


    When you configure a session for recovery, you can recover the session when you recover a workflow, or you can
    recover the session without running the rest of the workflow.
    When you configure a session, you can choose a recovery strategy of fail, restart, or resume:


    ¨ Resume from the last checkpoint. The Integration Service saves thesession state of operation and
    maintains target recovery tables.
    If the session aborts, stops, or terminates, the Integration Service uses the saved recovery information to resume the session from the point of interruption.
    When you validate a session, the Workflow Manager verifies that the transformations are configured to produce repeatable and deterministic data. The session is not valid if you configure recovery to resume from the last checkpoint, but the transformations are not configured for repeatable and deterministic data.

    You cannot configure a session with a resume strategy if it uses mapping variables.


    ¨ Restart task. The Integration Service runs the session again when it recovers the workflow.When you recover with restart task, you might need to remove the partially loaded data in the target or design a mapping to skip the duplicate rows.


    ¨ Fail task and continue workflow. When the Integration Service recovers a workflow, it does not recover the
    session. The session status becomes failed, and the Integration Service continues running the workflow.
    Configure the recovery strategy on the Properties page of the Session task.

     

    Resuming Sessions

    When you configure session recovery to resume from the last checkpoint, the Integration Service creates
    checkpoints in $PMStorageDir to determine where to start processing session recovery. When the Integration
    Service resumes a session, it restores the session state of operation, including the state of each source, target,
    and transformation. The Integration Service determines how much of the source data it needs to process.

    When the Integration Service resumes a session, the recovery session must produce the same data as the original session. The session is not valid if you configure recovery to resume from the last checkpoint, but the session cannot produce repeatable data.

    You can configure a mapping to enable transformations in the session to produce the same data between the session and recovery run. When a mapping contains a transformation that never produces repeatable data, you can add a transformation that always produces repeatable data immediately after it.

     

    When you recover a session from the last checkpoint, the Integration Service restores the session state of
    operation to determine the type of recovery it can perform:
    ¨ Incremental. The Integration Service starts processing data at the point of interruption. It does not read or
    transform rows that it processed before the interruption. By default, the Integration Service attempts to perform
    incremental recovery.
    ¨ Full. The Integration Service reads all source rows again and performs all transformation logic if it cannot
    perform incremental recovery. The Integration Service begins writing to the target at the last commit point. If
    any session component requires full recovery, the Integration Service performs full recovery on the session.

     

    You can recover a workflow if the Integration Service can access the workflow state of operation. The workflow state of operation includes the status of tasks in the workflow and workflow variable values. The Integration Service stores the state in memory or on disk, based on how you configure the workflow:
    ¨ Enable recovery. When you enable a workflow for recovery, the Integration Service saves the workflow state of operation in a shared location. You can recover the workflow if it terminates, stops, or aborts. The workflow does not have to be running.
    ¨ Suspend. When you configure a workflow to suspend on error, the Integration Service stores the workflow state of operation in memory. You can recover the suspended workflow if a task fails. You can fix the task error and recover the workflow.

     

    State of Operation


    When you recover a workflow or session, the Integration Service restores the workflow or session state of operation to determine where to begin recovery processing. The Integration Service stores the workflow state of operation in memory or on disk based on the way you configure the workflow. The Integration Service stores thesession state of operation based on the way you configure the session.

     

    Rules and Guidelines for Session Recovery

    recovery功能有很多限制条件(尤其是Session的resume from the last checkpoint选项),很多种情况都不能recovery或者recovery后会出现前后数据不一致等其他问题。(Pipeline Partitioning也是限制条件过多,要注意的事项细节太多)

    展开全文
  • android recovery

    千次阅读 2016-01-03 18:00:16
    Android recovery
  • Recovery流程梳理

    千次阅读 2018-09-28 15:08:35
    Framework recovery 分析2.1 Framework Recovery流程2.2 Framework Recovery 分析3. Recovery分析3.1 Recovery流程3.2 Recovery源码分析4. 升级的执行者 Updater分析5. OTA 目录结构6. 涉及到的其它内容 1. ...
  • Android Recovery升级原理

    万次阅读 多人点赞 2017-03-09 20:56:49
    Android Recovery升级原理 声明 摘要 Recovery相关概念 Android系统的启动模式 1 Android 各个分区介绍 2 Android的启动模式 3 如何进入Recovery模式 Recovery升级原理 1 Recovery启动参数的设置 2 OTA升级包的目录...
  • bootloader recovery

    千次阅读 2019-05-10 11:32:20
    Android Recovery 源码解析和界面定制 http://blog.csdn.net/austinde...
  • recovery 工作流程

    千次阅读 2018-02-09 16:16:35
    一、recovery.cpp 文件分析 recovery 可以理解为一个最小系统,上电开机后,uboot引导kernel,然后加载recovery镜像文件recovery.img(正常启动加载rootfs),之后执行镜像中的init 进程。在init.rc中有如下两行...
  • Surface Recovery

    千次阅读 2018-10-01 13:49:37
    Failure: 0xc0000225 ... Just failed again and again for the recovery via the official image "SurfacePro4_BMR_43_11.347.0.zip", with the failure above. Attempts: 1. bing the ...
  • Recovery 简介

    2015-07-27 11:45:03
    Recovery模式指的是一种可以对安卓机内部的数据或系统进行修改的模式(类似于windows PE或DOS)。在这个模式下我们可以刷入新的Android系 统,或者对已有的系统进行备份或升级,也可以在此恢复出厂设置。 使用方法...
  • Recovery是用户想要刷机的过程中经常会遇到的一个词。 那么什么是RecoveryRecovery模式又是什么意思?手机怎么进入Recovery模式? 对于这些大家关心的问题,小编今天就在这里一次性给大家解答,文章有点长,还请...
  • Recovery源码分析 概述 main函数 输出重定向 填充fstab结构体 挂载cache分区 获取Recovery命令参数 分析recovery命令 install_package load_keys加载公钥原文件 verify_file对升级包进行签名校验 mzOpenZipArchive-...
  • Android系统升级 Recovery模式(01)Recovery模式启动 Android系统升级 Recovery模式(02)Recovery升级过程 Android系统升级 Recovery模式(03)update-binary模块 本模块分享的内容:Recovery模式启动 本章...
  • Android系统升级 Recovery模式(01)Recovery模式启动 Android系统升级 Recovery模式(02)Recovery升级过程 Android系统升级 Recovery模式(03)update-binary模块 本模块分享的内容:Recovery升级过程 本章...
  • HTC g2 magic recovery

    热门讨论 2010-08-13 15:41:41
    HTC g2 magic刷机,包括以下三个文件 HTC g2 magic recovery1.5.2 HTC g2 magic recovery1.6.2 HTC g2 magic recovery1.7.0
  • Ceph Recovery分析

    千次阅读 2017-10-23 17:23:06
    1.ceph recovery 概述2.相关变量及函数3.线程池与工作队列4. Ceph PGQueable5.Bufferlist及序列化6.Recovery 流程 1.ceph recovery 概述 当PG完成了Peering过程后,处于Active状态的PG就已经可以对外提供服务了。...
  • Android Recovery

    2013-09-17 15:48:02
    Android Recovery Android Recovery Android Recovery: 功能简介...在某些操作之后,系统会自动重启并进入到Recovery模式,用户按组合键开机(HOME+POWER),也可进入Recovery模式。该模式提供如下功能: 1、擦
  • Recovery UI更新分析

    2018-09-28 15:10:52
    文章目录1.Recovery流程2.Recovery UI初始化流程分析3.字体加载函数`gr_init`4.下面看一下图片加载函数`LoadBitmap`5.Recovery按键事件的监听6.Recovery 中图片的显示7.Recovery UI 更新 1.Recovery流程 2.Recovery...
  • Android Recovery Theory android Recovery:功能简介 Android支持Recovery模式。在某些操作之后,系统会自动重启并进入到Recovery模式,用户按组合键开机(HOME+POWER),也可进入Recovery模式。该模式提供如下...
  • xoom recovery

    2012-07-10 14:18:44
    adb reboot bootloaderfastboot flash recovery recovery-solarnz-XXXXXX-XXXX.imgfastboot reboot adb reboot recovery
  • recovery修改

    千次阅读 2014-11-18 09:59:27
    当客户手机为1080P的时候,如果感觉recovery mode下的字体太小,可以按照如下方式修改     [SOLUTION]   1,拷贝alps/mediatek/factory/src/miniui/font_16X28.h到alps\bootable\recovery\minui下 2...
  • Recovery Catalog

    千次阅读 2016-04-20 08:52:23
    一、Recovery Catalog   利用RMAN备份时,默认使用控制文件保存RMAN资料库,资料库包含备份集、镜像备份、归档日志的备份信息。默认控制文件保存这些信息是7天,可以通过参数control_file_record_keep_...
  • recovery学习

    2012-04-18 15:10:09
    1. recovery的代码位于bootable/recovery下, 主要文件为recovery.c和install.c。
  • 导航recovery机制

    千次阅读 2019-01-14 18:43:19
    recovery机制是当移动机器人认为自己被卡住时,指导机器人进行一系列的恢复行为。 1 恢复机制 如图: move_base节点可以在机器人认为自己被卡住时选择性地执行恢复行为。默认情况下,move_base节点将采取以下操作来...
  • recovery介绍

    千次阅读 2012-12-08 11:11:23
    recovery原理 1 android启动介绍 Android系统Recovery实际上指的是Andriod系统下Recovery模式,它是Android系统下一种非常重要的启动模式。在Android系统里,一般有三种启动模式,分别是正常启动模式(启动...
  • Backup and Recovery Basis 1.4.3 Automatic Recovery After Instance Failure: Crash Recovery The crash recovery process is a special form of recovery, which happens the first time an Oracle ...

空空如也

空空如也

1 2 3 4 5 ... 20
收藏数 172,433
精华内容 68,973
关键字:

recovery