ByteCode Instrumentation
Bytecode Instrumentation 定义
我们首先来看看,什么叫“Instrumentation”?Instrumentation这个词有很多意思,在维基百科中,它是这样解释的:
Instrumentation is the use of measuring instruments to monitor and control a process. It is the art and science of measurement and control of process variables within a production, laboratory, or manufacturing area.
似乎中文中没有一个合适的词来描述,意思就是“使用计量器具去监控和控制一个流程”就可以被叫做“Instrumentation”。比如下面这个很
直观的器具就被用来做Instrumentation了。
![]()
什么是ByteCode Instrumentation
这是我在网上[2](大专栏 ByteCode Instrumentationnoreferrer">http://www.ibm.com/developerworks/cn/java/j-rtm2/index.html)看到的一个定义,里面对“bytecode instrumentation”的翻译就是“字节码插装”,但是这里有个缺陷就是,针对字节码的插装,并不只限于Java语言,其他基于字节码的语言(比如.Net/Python)也是可以插装的。
而且可以进一步延伸的是,除了有字节码插装(bytecode instrumentation)之外,也有源代码级别的插装(sourcecode instrumentation)。他们的使用场景是不一样的,比如字节码插装主要发生在进程运行时,当然编译时也是可以字节码插装的。而源代码级别的插装主要是发生在编译时。
参考:
- http://www.ibm.com/developerworks/cn/java/j-rtm2/index.html
- https://technoga.wordpress.com/2012/12/01/what-is-bytecode-instrumentation/#2
- https://github.com/neuroo/equip
- http://security.coverity.com/blog/2014/Nov/understanding-python-bytecode.html
ByteCode Instrumentation的更多相关文章
- Living in the Matrix with Bytecode Manipulation--转
原文地址:https://www.infoq.com/articles/Living-Matrix-Bytecode-Manipulation You are probably all too fam ...
- java.lang.instrument.Instrumentation
java.lang.instrument.Instrumentation 看完文档之后,我们发现这么两个接口:redefineClasses和retransformClasses.一个是重新定义cla ...
- Java资源大全中文版(Awesome最新版)
Awesome系列的Java资源整理.awesome-java 就是akullpp发起维护的Java资源列表,内容包括:构建工具.数据库.框架.模板.安全.代码分析.日志.第三方库.书籍.Java 站 ...
- batch_size 和 fetch_size作用
hibernate抓取策略,,batch-szie在<class>上的应用 batch-size属性,可以批量加载实体类, hbm.xml classes.hbm.xml <?xml ...
- Hibernate-入门教程
首先了解hibernate的目录结构 . +lib antlr.jar cglib-full.jar asm.jar asm-attrs.jars commons-collections.jar co ...
- Hibernate 抓取策略fetch-2 (批量抓取batch-size以及hibernate.jdbc.fetch_size、hibernate.jdbc.batch_size)
类关系: User N~1 Group 测试代码: System.out.println("1"); List stuList = session.createQuery(&quo ...
- JavaPersistenceWithHibernate第二版笔记-第五章-Mapping value types-005控制类型映射(Nationalized、@LOB、@org.hibernate.annotations.Type)
一.简介 1. 2. 3. 4. to override this default mapping. The JPA specification has a convenient shortcut a ...
- Android 如何切换到 Transform API?
摘要: 如果你的 Android 构建中涉及到字节码插装(bytecode instrumentation),或者应用中提供了进行插装的插件,并希望它能支持 Instant Run,那么你必须切换到 ...
- awesome-java
Awesome Java A curated list of awesome Java frameworks, libraries and software. Awesome Java Ancient ...
随机推荐
- jQuery 1.3.2 简单实现select二级联动
jQuery 1.3.2 简单实现select二级联动 复制代码代码如下: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transiti ...
- php日期时间戳,日期函数使用
date_default_timezone_get():获得当前php的时区 date_default_timezone_set():设置当前php的时区 date("Y-m-d H-i-s ...
- hdu2457(最少替换多少个字符使主串不包含模式串)ac自动机+dp
题:http://acm.hdu.edu.cn/showproblem.php?pid=2457 题意:给定n个模式串,给定一个主串,问最替换掉多少个字符使主串不包含模式串或输出“-1”表示没有可行的 ...
- salt-stack 安装nginx
init-pkg-install: pkg.installed: - names: - gcc - gcc-c++ - make - autoconf - openssl - openssl-deve ...
- http head详解
Http普通报头: 少数报头域用于所有的请求和响应消息, 但并不用于被传输的实体 cache-Control: 用于指定缓存指令, 缓存指令是单向的 ,且是独立的(一个消息的缓存指令不会影 ...
- springboot的配置文件说明
1.以servlet的方式启动SpringBoot 正常情况下要复制代码到tomcat去启动,但springboot内置tomcat了,配置好就可以直接run方法直接运行. 2.直接run运行
- lvm镜像卷
镜像能够分配物理分区的多个副本,从而提高数据的可用性.当某个磁盘发生故障并且其物理分区变为不可用时,你仍然可以访问可用磁盘上的镜像数据.LVM在逻辑卷内执行镜像. 系统版本 # cat /etc/ce ...
- Consul集群版容器化部署与应用集成
背景 由于公司目前的主要产品使用的注册中心是consul,consul需要用集群来保证高可用,传统的方式(Nginx/HAProxy)会有单点故障问题,为了解决该问题,我开始研究如何只依赖consul ...
- 2018.11.2JavaScript随笔
构造函数首字母大写 通过new创建对象 BOM:浏览器对象模型
- 黑马_13 Spring Boot:05.spring boot 整合其他技术
13 Spring Boot: 01.spring boot 介绍&&02.spring boot 入门 04.spring boot 配置文件 05.spring boot 整合其他 ...