[ 
https://issues.apache.org/jira/browse/LIVY-617?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Saisai Shao resolved LIVY-617.
------------------------------
    Fix Version/s: 0.7.0
         Assignee: shanyu zhao
       Resolution: Fixed

Issue resolved by pull request 187
https://github.com/apache/incubator-livy/pull/187

> Livy session leak on Yarn when creating session duplicated names
> ----------------------------------------------------------------
>
>                 Key: LIVY-617
>                 URL: https://issues.apache.org/jira/browse/LIVY-617
>             Project: Livy
>          Issue Type: Bug
>          Components: Server
>    Affects Versions: 0.6.0
>            Reporter: shanyu zhao
>            Assignee: shanyu zhao
>            Priority: Major
>             Fix For: 0.7.0
>
>          Time Spent: 2h 40m
>  Remaining Estimate: 0h
>
> When running Livy on Yarn and try to create session with duplicated names, 
> Livy server sends response to client "Duplicate session name: xxx" but it 
> doesn't stop the session. The session creation failed, however, the Yarn 
> application got started and keeps running forever.
> This is because during livy session register method, exception 
> "IllegalArgumentException" is thrown without stopping the session:
> {code:java}
> def register(session: S): S = {
>     info(s"Registering new session ${session.id}")
>     synchronized {
>       session.name.foreach { sessionName =>
>         if (sessionsByName.contains(sessionName)) {
>           throw new IllegalArgumentException(s"Duplicate session name: 
> ${session.name}")
>         } else {
>           sessionsByName.put(sessionName, session)
>         }
>       }
>       sessions.put(session.id, session)
>       session.start()
>     }
>     session
>   }{code}
>  
> Reproduction scripts:
> curl -s -k -u username:password -X POST --data '\{"name": "duplicatedname", 
> "kind": "pyspark"}' -H "Content-Type: application/json" 
> 'https://myserver/livy/v1/sessions'



--
This message was sent by Atlassian Jira
(v8.3.2#803003)

Reply via email to