Commit Graph

3089 Commits

Author SHA1 Message Date
dougqh 02c2d43b80 spring-data -> spring-data-1.9
Changing directory name to spring-data-1.9 to reflect version restrictions as per review comments
2019-09-30 15:58:13 -04:00
dougqh 8b42d286e8 Removing unnecessary test code
Removing unnecessary test code left over from initial port integration
2019-09-30 14:21:24 -04:00
dougqh aeef4f4203 Removing unused dependency 2019-09-30 14:20:49 -04:00
dougqh 3780cec4f2 Adding setAsync
Adding setAsync as per review comment
2019-09-30 13:50:53 -04:00
dougqh 1b1cc34ba5 Switching setResourceName -> setTag
Per view comment, switching setResourceName -> setTag
2019-09-27 16:01:50 -04:00
dougqh 48b701877a googleJavaFormat 2019-09-27 13:55:32 -04:00
dougqh b91648d0e3 googleJavaFormat 2019-09-27 09:40:32 -04:00
dougqh ac557ed4ee operationName -> resourceName
Addressing review comments: operationName -> resourceName

This was vestige of the original SignalFX code
2019-09-26 14:56:50 -04:00
dougqh d192811419 Fixing muzzle version 2019-09-26 14:45:29 -04:00
dougqh 5cb0cc7c79 Preparing for ElasticSearch test
Adding spring-data-elasticsearch dependency just to make sure everything plays nice together
2019-09-26 09:57:40 -04:00
dougqh 56cebb1c0b Switched to extending JpaRepository
Switched to extending JpaRepository rather than CrudRepository, so that multiple spring data integrations can coexist.

Since JpaRepository redefines findAll, this required one update to the test.  The other references to CrudRepositopry remain unchanged since JpaRepository extends CrudRepository without redefining those methods.
2019-09-26 09:46:53 -04:00
dougqh 4d287c63bf googleJavaFormat 2019-09-26 09:31:28 -04:00
dougqh 45f6edfa6e / -> . 2019-09-26 09:30:04 -04:00
dougqh eb05fc7bc4 Adjusting support version of spring-data
Rather than using a somewhat ugly solution of implementing both postProcess method signatures.

I'm restricting the integration to newer versions (1.9 - Sept 2014) of spring-data to start.
2019-09-26 09:29:45 -04:00
dougqh 3b14a1cacd Simplify @Bean annotation 2019-09-25 17:05:59 -04:00
dougqh 1e8af55d57 Fixed typo 2019-09-25 16:57:24 -04:00
dougqh 64a5fd61f9 Tinkering with version compatibility
RepositoryProxyPostProcessor has different method sigs depending on the version of spring-data-commons.

As stop gap implemented both signatures, but probably need to split spring-data support by version.
2019-09-25 16:50:45 -04:00
dougqh 59416bf521 Prefix with Jpa 2019-09-25 16:24:27 -04:00
dougqh 682cc40a32 PersistenceConfig -> JpaPersistenceConfig 2019-09-25 16:03:11 -04:00
dougqh d0cf564f07 spring -> spring.jpa
Moved spring to spring.jpa to make room for other spring data integrations.
2019-09-25 15:59:43 -04:00
dougqh 64e3ebca88 Adding license clause 2019-09-24 10:32:20 -04:00
dougqh 02c7e5b98b Renamed variable
Renamed transactionalMethod to just method, since this is no longer tied to spring-tx
2019-09-23 16:32:57 -04:00
dougqh 680c4426bc Changing muzzle spec to depend on spring-data again 2019-09-23 16:14:56 -04:00
dougqh a242e088de codeNarc - removed unused import of @Shared 2019-09-23 15:54:44 -04:00
dougqh 8a89547004 googleJavaFormat 2019-09-23 15:29:15 -04:00
dougqh 6b5acc8386 New Approach - instrument RepositoryFactorySupport
This revised version targets spring-data RepositoryFactorySupport rather than spring-tx

This is accomplished by injecting a RepositoryProxyPostProcessor during construction that adds a datadog specific MethodIntercptor.

In the end, this functions similarly to the tx support in that it uses a widely scoped MethodInterceptor.

This required some changes to the test as well.  The old test set-up the repository before the instrumentation was fully-enabled.  Enabling the instrumentation earlier capture extra traces where Spring JPA performs metainfo queries.
2019-09-23 15:26:18 -04:00
dougqh 7c5e74bdf0 Cleaning-up decorator
The SpringDataDecorator is really for Spring transactions including non-DB related transactions.

The SpringDataDecorator never really implemented DB or ORM support anyway, since most of the methods just returned null.

Changing the decorator to just extend ClientDecorator instead.  Also rename to reflect its true purpose.
2019-09-17 10:51:30 -04:00
dougqh 172ff747cb Updating muzzle spec
Switching muzzle to target spring-tx rather than spring-data (which is logical given the instrumentation point)

Also added extraDependency on aopalliance
This restricts the support the Spring 2.5 when spring-tx & spring-aop using aopalliance were introduced.
2019-09-17 10:06:43 -04:00
dougqh e43baf82be Renaming advice class
Renaming advice class to more accurately reflect what is being instrumented
2019-09-17 09:27:39 -04:00
dougqh 85389b48d8 Google Format 2019-09-17 08:24:57 -04:00
dougqh 0c3e0579b2 Switching to instrumenting transaction support
After experimenting with RepositorySupport$QueryExecutorMethodInterceptor switched to TransactionInterceptor.

QueryExecutorMethodInterceptor was too narrowly scoped and didn't capture the UPDATE or DELETE statement.  TransactionInterceptor captures everything, but is still a bit more broadly applicable than I'd like.
2019-09-17 08:19:42 -04:00
dougqh 122533fde6 Switching to simple concat for efficiency 2019-09-16 11:08:37 -04:00
dougqh d2ba6af80c Removing unneecessary dependencies
Removing dependencies rendered redundant by clean-up in datadog repo - as per review comment
2019-09-11 14:29:34 -04:00
dougqh 5f5605f6b1 Putting in alphabetical order 2019-09-11 11:53:15 -04:00
dougqh ab52988ced Removing "Modified by SignalFx" 2019-09-11 11:33:14 -04:00
dougqh 60e9cc249c Removing "Modified by SignalFx"
Removing "Modified by SignalFx" comments, since our integration is current the same.

Added a comment to SpringJpaTest explaining the differences.
2019-09-11 11:23:49 -04:00
dougqh 7a366f0f01 Added explanatory comments to test
Added some explanatory comments for each span -- might turn these into assertions later

Primary aim was to understand the differences from the signalfx fork.  They seem to stem deviations in the underlying JDBC integration.
2019-09-11 09:55:40 -04:00
dougqh 1335296975 Fixing mismatches in spans collected by signalfx fork & datadog
There are two main differences...
- "hsqldb" vs "spring-data" as the root test service name
- an extra seemingly spurious sql span in signalfx
2019-09-10 17:42:49 -04:00
dougqh 6d38831252 Merge branch 'master' into dougqh/spring-data
Tweak partially picked from signalfx -- that commit included same other unwanted changes in this file and others (see 636c23ed2c)
2019-09-10 17:40:36 -04:00
Ryan Fitzpatrick 5f7e0609ed Initial spring data instrumentation 2019-09-10 15:13:20 -04:00
Douglas Q Hawkins 2e5766ece9
Merge pull request #974 from DataDog/dougqh/no-lang-client-spans
Ensure "client" spans do not set the language tag
2019-09-05 13:38:25 -04:00
dougqh 46a36569e6 Adding FIXME for possible test clean-up 2019-09-05 13:23:51 -04:00
Tyler Benson 0c23cf94a9
Merge pull request #976 from DataDog/tyler/more-aws-tags
Add additional tags for aws-sdk spans
2019-09-04 13:35:41 -07:00
Tyler Benson c410f5b78b Add additional tags for aws-sdk spans
s3 -> bucket name
dynamodb -> table name
sqs -> queue name/url
kinesis -> stream name
2019-09-04 12:41:45 -07:00
Tyler Benson b20a32b44d
Merge pull request #895 from aantono/haystack
Added support for Haystack trace propagation
2019-09-04 11:09:08 -07:00
Laplie Anderson 983b4e2e6c
Merge pull request #973 from DataDog/landerson/all-tests-on-all-jvms
Run all tests on all java versions
2019-09-04 12:28:26 -04:00
Laplie Anderson 619ecb8170 Fix a couple tests failing with IBM 8 2019-09-03 17:19:46 -04:00
dougqh 1d087574fd Removing unused imports
Removing unused imports caught by codeNarc
2019-09-03 16:49:20 -04:00
dougqh 4851cc9069 Re-running format through gradle
Need to figure out why IntelliJ and gradle are behaving differently for import order
2019-09-03 16:16:13 -04:00
dougqh 57beee76d2 Running Google Code Formatter
Changes here are all non-functional -- and in methods unrelated to the core change
2019-09-03 14:09:46 -04:00