{"action":"opened","issue":{"url":"https://api.github.com/repos/jenetics/jenetics/issues/11","labels_url":"https://api.github.com/repos/jenetics/jenetics/issues/11/labels{/name}","comments_url":"https://api.github.com/repos/jenetics/jenetics/issues/11/comments","events_url":"https://api.github.com/repos/jenetics/jenetics/issues/11/events","html_url":"https://github.com/jenetics/jenetics/issues/11","id":60713767,"number":11,"title":"Inefficient thread utilization","user":{"login":"jenetics","id":1509203,"avatar_url":"https://avatars.githubusercontent.com/u/1509203?v=3","gravatar_id":"","url":"https://api.github.com/users/jenetics","html_url":"https://github.com/jenetics","followers_url":"https://api.github.com/users/jenetics/followers","following_url":"https://api.github.com/users/jenetics/following{/other_user}","gists_url":"https://api.github.com/users/jenetics/gists{/gist_id}","starred_url":"https://api.github.com/users/jenetics/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jenetics/subscriptions","organizations_url":"https://api.github.com/users/jenetics/orgs","repos_url":"https://api.github.com/users/jenetics/repos","events_url":"https://api.github.com/users/jenetics/events{/privacy}","received_events_url":"https://api.github.com/users/jenetics/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-03-11T19:16:36Z","updated_at":"2015-03-11T19:16:36Z","closed_at":null,"body":"If the `Executor` of the evolution `Engine` is set to a different value than a `ForkJoinPool`, the thread utilization is far below then expected. Setting the executor to a fixed thread pool,\r\n```java\r\nEngine\r\n    .builder(knapsack.function(), knapsack.genotype())\r\n    .populationSize(150)\r\n    .survivorsSelector(new TournamentSelector<>(5))\r\n    .offspringSelector(new RouletteWheelSelector<>())\r\n    .alterers(\r\n        new Mutator<>(0.03),\r\n        new SinglePointCrossover<>(0.125))\r\n    .executor(Executors.newFixedThreadPool(6))\r\n    .build();\r\n```\r\nthe threads will be created, but not fully utilized.\r\n![htop](https://cloud.githubusercontent.com/assets/1509203/6604750/015e9d9c-c82b-11e4-8ac4-b6c96d89f1d2.png)\r\n\r\nOn the other hand, if you set the executor to `new ForkJoinPool(1)`, all of the cores are busy.\r\n"}}