You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2016/09/23 09:51:20 UTC

[jira] [Commented] (FLINK-4669) scala api createLocalEnvironment() function add default Configuration parameter

    [ https://issues.apache.org/jira/browse/FLINK-4669?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15515995#comment-15515995 ] 

ASF GitHub Bot commented on FLINK-4669:
---------------------------------------

GitHub user shijinkui opened a pull request:

    https://github.com/apache/flink/pull/2541

    [FLINK-4669] scala api createLocalEnvironment() function add default Configuration parameter

    1. add Configuration as createLocalEnvironment second default paramter
    2. fix the mistake scaladoc usage of readFile function
    3. delete the brackets if method have no parameter. Because methods that follow JavaBean naming contract for accessors are expected to have no side effects. The recommended convention is to use a parameterless method whenever there are no parameters and the method have no side effect.
    
    - [ ] General
      - The pull request references the related JIRA issue ("[FLINK-4669] scala api createLocalEnvironment() function add default Configuration parameter")
      - The pull request addresses only one issue
      - Each commit in the PR has a meaningful commit message (including the JIRA id)
    
    - [ ] Documentation
      - Documentation has been added for new functionality
      - Old documentation affected by the pull request has been updated
      - JavaDoc for public methods has been added
    
    - [ ] Tests & Build
      - Functionality added by the pull request is covered by tests
      - `mvn clean verify` has been executed successfully locally or a Travis build has passed
    


You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/shijinkui/flink create_local_env_with_conf

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/flink/pull/2541.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #2541
    
----
commit f79ec4c3cb20d7be496e864aac7c5619199f96a4
Author: shijinkui <sh...@huawei.com>
Date:   2016-09-23T09:46:08Z

    [FLINK-4669] scala api createLocalEnvironment() function add default Configuration parameter
    1.add Configuration as createLocalEnvironment second default paramter
    2.fix the mistake scaladoc usage of readFile function
    3.Methods that follow JavaBean naming contract for accessors are expected to have no side effects. The recommended convention is to use a parameterless method whenever there are no parameters and the method have no side effect.

----


> scala api createLocalEnvironment() function add default Configuration parameter
> -------------------------------------------------------------------------------
>
>                 Key: FLINK-4669
>                 URL: https://issues.apache.org/jira/browse/FLINK-4669
>             Project: Flink
>          Issue Type: Improvement
>          Components: Streaming
>            Reporter: shijinkui
>
> scala program can't direct use createLocalEnvironment with custom Configure object.
> such as I want to start web server in local mode, I will do such as:
> ```
> // set up execution environment
> val conf = new Configuration
> conf.setBoolean(ConfigConstants.LOCAL_START_WEBSERVER, true)
> conf.setInteger(ConfigConstants.JOB_MANAGER_WEB_PORT_KEY, ConfigConstants.DEFAULT_JOB_MANAGER_WEB_FRONTEND_PORT)
> val env = new org.apache.flink.streaming.api.scala.StreamExecutionEnvironment(
>   org.apache.flink.streaming.api.environment.StreamExecutionEnvironment.createLocalEnvironment(2, conf)
> )
> ```
> so we need createLocalEnvironment function have a config parameter 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)