# Batch profiling with custom services

**URL:** <https://community.dynatrace.com/t/batch-profiling-with-custom-services/16805>\
**Category:** Open Q&A\
**Tags:** distributed-traces-classic, services-classic\
**Created:** [November 5, 2018, 1:05pm UTC](https://community.dynatrace.com/t/batch-profiling-with-custom-services/16805 "2018-11-05T13:05:06Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jean-Pierre\_Rio](https://avatars.discourse-cdn.com/v4/letter/j/e8c25b/32.png) [@Jean-Pierre\_Rio](https://community.dynatrace.com/u/Jean-Pierre_Rio)\
**Post date:** [November 5, 2018, 1:05pm UTC](https://community.dynatrace.com/t/batch-profiling-with-custom-services/16805/1 "2018-11-05T13:05:06Z")

</div>

Hello,

I’m trying to find where the time is consumed in a Java batch application with Dynatrace. I created a custom entry point (custom service) that match the main method of the batch and the method called iteratively. The process is detected but I don’t know where to find the resulted distributed traces.

JP

---

<div class="post-metadata">

**Author:** ![pahofmann](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/pahofmann/32/17076_2.png) [@pahofmann](https://community.dynatrace.com/u/pahofmann)\
**Post date:** [November 5, 2018, 2:19pm UTC](https://community.dynatrace.com/t/batch-profiling-with-custom-services/16805/2 "2018-11-05T14:19:15Z")

</div>

You should see the custom service in the _Transactions & services_ overview.

You can use the filter for _Service Type: Custom service:_

 ![18766-2018-11-05-15-18-19-window.png](https://global.discourse-cdn.com/dynatrace/original/3X/4/7/4728f317b367f6c4a42c06c7054d723c1ae3853e.png)

---

<div class="post-metadata">

**Author:** ![Jean-Pierre\_Rio](https://avatars.discourse-cdn.com/v4/letter/j/e8c25b/32.png) [@Jean-Pierre\_Rio](https://community.dynatrace.com/u/Jean-Pierre_Rio)\
**Post date:** [November 5, 2018, 3:07pm UTC](https://community.dynatrace.com/t/batch-profiling-with-custom-services/16805/3 "2018-11-05T15:07:14Z")

</div>

Thank you [@Patrick H.](https://answers.dynatrace.com/users/11534/view.html) for your answer. I was trying on a test batch :

```auto
public class Entree {
	public static void main(String[] args) throws Exception {
		doIt();
	}
	private static void doIt() throws InterruptedException {
		while (true) {
			System.out.println(" Il est " + new Date() );
			Thread.sleep(5000);
		}
	}
}

```

and it didn’t work (?).

I tried on my real batch, and now it seems to works.

Thank you for your help,

JP

---

<div class="post-metadata">

**Author:** ![pahofmann](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/pahofmann/32/17076_2.png) [@pahofmann](https://community.dynatrace.com/u/pahofmann)\
**Post date:** [November 6, 2018, 9:43am UTC](https://community.dynatrace.com/t/batch-profiling-with-custom-services/16805/4 "2018-11-06T09:43:24Z")

</div>

Maybe you didn’t restart the process or activate Hot Sensor Placement for Java when configuring the test Batch?

---

<div class="post-metadata">

**Author:** ![Jean-Pierre\_Rio](https://avatars.discourse-cdn.com/v4/letter/j/e8c25b/32.png) [@Jean-Pierre\_Rio](https://community.dynatrace.com/u/Jean-Pierre_Rio)\
**Post date:** [November 6, 2018, 12:32pm UTC](https://community.dynatrace.com/t/batch-profiling-with-custom-services/16805/5 "2018-11-06T12:32:58Z")

</div>

Patrick,

I did restart the process. I’ll try to understand later, when I have some time.

Regards,

JP
