Commit Graph

113 Commits

Author SHA1 Message Date
Andrew Kent 13c96bba33 Additional test for shared field 2018-10-10 10:40:04 -07:00
Tyler Benson 330e09d0b3
Merge pull request #477 from DataDog/tyler/bb-upgrade
Upgrade Byte Buddy to 1.9.0
2018-10-02 11:31:11 -04:00
Tyler Benson 6b8eb60ca2 Upgrade Byte Buddy to 1.9.0 2018-10-01 13:31:03 -04:00
Andrew Kent 5864dd90e7 Allow instrumenting com.sun.messaging. namespace 2018-09-28 14:37:32 -07:00
Tyler Benson 3d78afbc2c Disable Executor instrumentation ThreadPoolExecutor instances
If we can’t add generic runnables to the queue.

This won’t solve the problem for all cases, but it will help with some.

Tests forthcoming.
2018-09-20 16:06:01 +10:00
Tyler Benson f9f0438e85 Initialize WeakMapProvider even earlier
It is used by classes delcared as static fields in AgentInstaller, so there were some cases where the fallback is being used.
2018-09-19 08:37:08 +10:00
Tyler Benson 296f9adfc2 Ignore byte buddy classes
not having this produced the following error on startup:

```
Cannot resolve type description for net.bytebuddy.dynamic.Nexus
```
2018-09-18 17:20:36 +10:00
Tyler Benson 8061bd2471 Add comment. 2018-08-31 16:27:31 +10:00
Tyler Benson 2d04ef292e
Merge pull request #468 from DataDog/tyler/evict-typepool
Add eviction to a TypePool.CacheProvider’s cache
2018-08-31 08:57:18 +10:00
Tyler Benson 6b0f20fc05 Add eviction to a TypePool.CacheProvider’s cache
Most items loaded are probably not often used.  Puts an upper limit on the size and evicts unused Resolution’s over time.
2018-08-30 11:56:53 +10:00
Andrew Kent 61aaebfc97 Create muzzle references from ldc instructions 2018-08-29 17:18:11 -07:00
Andrew Kent 7154b54e10 Rename TracerBridge and Provider 2018-08-27 12:04:26 -07:00
Andrew Kent 9f1d22ea6b Register TracerBridge in TracerInstaller instead of DDTracer init 2018-08-27 12:04:26 -07:00
Andrew Kent c6841c9d06 Add maven version scanning to muzzle 2018-08-24 10:47:37 -07:00
Tyler Benson 36b49c7de3
Merge pull request #451 from DataDog/tyler/netty-client-fixes
Allow trace to persist across netty connect.
2018-08-23 16:03:58 +10:00
Tyler Benson 898647e000 Allow trace to persist across netty connect.
Also create span with error on connection failure.

Add tests for connection failure.
2018-08-22 09:45:33 +10:00
Nikolay Martynov c95baef487 Wait for given reference to get GCed in `waitGC`
This should help to make sure that object we are interested in
actually gets GCed.

This change also improves tests for PendingTrace and ScopeManager to
make sure that trace gets cleaned up.
2018-08-21 10:05:10 -04:00
Nikolay Martynov 138f78ce4b Make Muzzle log class being instrumented 2018-08-16 17:28:32 -04:00
Andrew Kent 3c1bf569ea Add reference pretty-printer to muzzle plugin 2018-08-15 10:01:19 -07:00
Andrew Kent c351a4825e Regenerate muzzle bytecode when run multiple times 2018-08-15 09:49:50 -07:00
Nikolay Martynov 36ec5d51e5 SafeHasSuperTypeMatcher: handle exceptions when getting class erasure 2018-08-15 09:49:50 -07:00
Andrew Kent a7c63b9261 Clarify comment for safe interface iteration. 2018-08-15 09:49:50 -07:00
Andrew Kent 57e85d4a13 Catch and log instrumentation matcher exception
Catching instrumentation matcher exceptions at the Instrumenter level
allows other, unrelated instrumentation to match.
2018-08-15 09:49:50 -07:00
Andrew Kent d64b162539 Remove safeMatch from element matcher and document bb cache class 2018-08-15 09:49:50 -07:00
Andrew Kent 260e3520aa Fix classloading integration tests 2018-08-15 09:49:50 -07:00
Andrew Kent 35c6fa2343 More error catching in safe matcher and reduce log level 2018-08-15 09:49:50 -07:00
Andrew Kent 75a6cee068 Add DDCachingPoolStrategy to reuse type descriptions 2018-08-15 09:49:50 -07:00
Ark f01c8349cc Deep-merge Reference fields and methods
Plus misc cleanup.
2018-08-15 09:49:50 -07:00
Andrew Kent e7bb7cfb3e Remove findLoadedClass 2018-08-15 09:49:50 -07:00
Andrew Kent 50c5a57c49 Replace UnloadedType with ByteBuddy TypeDescription 2018-08-15 09:49:50 -07:00
Andrew Kent 27cade057c Delegate bootstrap resource loading for unloaded types 2018-08-15 09:49:37 -07:00
Andrew Kent f8f45d7f14 Muzzle field matching 2018-08-15 09:49:37 -07:00
Andrew Kent c4daf007e3 Muzzle method and access matching 2018-08-15 09:49:37 -07:00
Andrew Kent 4887822eba Muzzle method ref creation and matching 2018-08-15 09:46:30 -07:00
Andrew Kent 0f6761dd4b Optimize Instrumenter logging 2018-08-15 09:46:30 -07:00
Andrew Kent 55a0abce68 Add notes of potential references to ReferenceCreator 2018-08-15 09:46:30 -07:00
Tyler Benson 84d38a8270
Merge pull request #439 from DataDog/tyler/method-signatures
Cleanup method signatures and servlet 2 instrumentation
2018-08-13 17:29:02 +10:00
Tyler Benson f801cbd466
Merge pull request #428 from DataDog/tyler/use-WeakConcurrentMap
Use WeakConcurrentMap
2018-08-13 16:44:16 +10:00
Tyler Benson 232708e457 Prevent abstract classes from going through the muzzle plugin. 2018-08-13 15:35:46 +10:00
Tyler Benson 4583d12b31 Cleanup method signatures and servlet 2 instrumentation
adding the abstract servlet instrumentation reduces code duplication and makes it more similar to servlet 3 instrumentation.
2018-08-13 15:14:10 +10:00
Nikolay Martynov fc8cc47f85 WeakMap improvements
* Improve tests to not depend on thread schedulting
* Test all underlying implementations
* Reduce number of static values
2018-08-10 22:16:21 -07:00
Tyler Benson 6cef9b89b0 Make some things non-static 2018-08-10 15:41:26 +10:00
Tyler Benson b220309a68 PR review changes. 2018-08-10 12:23:13 +10:00
Tyler Benson a3875aff2c Logging improvements and other misc
from reviewing a customer’s logs.
2018-08-09 15:59:59 +10:00
Tyler Benson eacc2d6402 Restructure how WeakMap is implemented
Use an interface.
Use a provider/supplier to avoid loading more onto the bootstrap classpath.
2018-08-08 16:54:44 +10:00
Tyler Benson 5e55defeb3 Fix bootstrap classpath. 2018-08-07 17:11:42 +10:00
Tyler Benson 847484cd47 Use WeakConcurrentMap
Instead of `Collections.synchronizedMap(new WeakHashMap<>())`.
2018-08-06 14:14:57 +10:00
Tyler Benson 064ae4c238 Separate span for input and output streams. 2018-08-03 15:41:16 +10:00
Nikolay Martynov 7ad9305927 Add some integration tests to check ByteBuddy's behavoir on class loading and parsing 2018-08-01 14:17:12 -04:00
Nikolay Martynov bb2126bd9a Improve ByteBuddyElementMatchers javadoc 2018-07-31 20:14:03 -04:00