类 JettyResourceFactory

    • 方法详细资料

      • setExecutor

        public void setExecutor​(@Nullable
                                Executor executor)
        Configure the Executor to use.

        By default, initialized with a QueuedThreadPool.

        参数:
        executor - the executor to use
      • setByteBufferPool

        public void setByteBufferPool​(@Nullable
                                      org.eclipse.jetty.io.ByteBufferPool byteBufferPool)
        Configure the ByteBufferPool to use.

        By default, initialized with a MappedByteBufferPool.

        参数:
        byteBufferPool - the ByteBuffer pool to use
      • setScheduler

        public void setScheduler​(@Nullable
                                 org.eclipse.jetty.util.thread.Scheduler scheduler)
        Configure the Scheduler to use.

        By default, initialized with a ScheduledExecutorScheduler.

        参数:
        scheduler - the Scheduler to use
      • setThreadPrefix

        public void setThreadPrefix​(String threadPrefix)
        Configure the thread prefix to initialize QueuedThreadPool executor with. This is used only when a Executor instance isn't provided.

        By default set to "jetty-http".

        参数:
        threadPrefix - the thread prefix to use
      • getScheduler

        @Nullable
        public org.eclipse.jetty.util.thread.Scheduler getScheduler()
        Return the configured Scheduler.
      • afterPropertiesSet

        public void afterPropertiesSet()
                                throws Exception
        从接口复制的说明: InitializingBean
        Invoked by the containing BeanFactory after it has set all bean properties and satisfied BeanFactoryAware, ApplicationContextAware etc.

        This method allows the bean instance to perform validation of its overall configuration and final initialization when all bean properties have been set.

        指定者:
        afterPropertiesSet 在接口中 InitializingBean
        抛出:
        Exception - in the event of misconfiguration (such as failure to set an essential property) or if initialization fails for any other reason
      • destroy

        public void destroy()
                     throws Exception
        从接口复制的说明: DisposableBean
        Invoked by the containing BeanFactory on destruction of a bean.
        指定者:
        destroy 在接口中 DisposableBean
        抛出:
        Exception - in case of shutdown errors. Exceptions will get logged but not rethrown to allow other beans to release their resources as well.