Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id E041D200B40 for ; Thu, 2 Jun 2016 07:26:00 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id DF58C160A4D; Thu, 2 Jun 2016 05:26:00 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 5A7BB160A4C for ; Thu, 2 Jun 2016 07:26:00 +0200 (CEST) Received: (qmail 94534 invoked by uid 500); 2 Jun 2016 05:25:59 -0000 Mailing-List: contact dev-help@ignite.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ignite.apache.org Delivered-To: mailing list dev@ignite.apache.org Received: (qmail 94513 invoked by uid 99); 2 Jun 2016 05:25:59 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 02 Jun 2016 05:25:59 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 2155B2C044E for ; Thu, 2 Jun 2016 05:25:59 +0000 (UTC) Date: Thu, 2 Jun 2016 05:25:59 +0000 (UTC) From: "Yakov Zhdanov (JIRA)" To: dev@ignite.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Created] (IGNITE-3233) need to optimize injections MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Thu, 02 Jun 2016 05:26:01 -0000 Yakov Zhdanov created IGNITE-3233: ------------------------------------- Summary: need to optimize injections Key: IGNITE-3233 URL: https://issues.apache.org/jira/browse/IGNITE-3233 Project: Ignite Issue Type: Improvement Reporter: Yakov Zhdanov Assignee: Semen Boikov Priority: Blocker Fix For: 1.7 {noformat} I want to check how this closure performs vs empty one: ignite.compute().affinityCall(xx, xx, new IgniteCallable() { @IgniteInstanceResource Ignite ignite; @SpringApplicationContextResource ApplicationContext ctx; Object bean1; Object bean2; @Override public Object call() throws Exception { bean1 = ctx.getBean(bean1class); bean2 = ctx.getBean(bean2class); return null; } }); {noformat} Closure above is 3 times slower than Noop closure. Injections should be optimized. I see the following options: # Annotations ## Introduce SpringAware annotation and annotate each object that will need injection including SPI and internal stuff ## Support Spring Autowire annotation. ## I am not sure about the approach. We can use ApplicationContext.autowire() or generate and compile code that will do injections. # Interfaces ## IgniteAware ## Spring ApplicationContext aware ## ... Implementor should suggest and back solution with microbenchmarks. -- This message was sent by Atlassian JIRA (v6.3.4#6332)