Alexandre Da
email: alexandre.veith@ens-lyon.fr.

Silva Veith

Marcos Dias De Assunc
email: marcos.dias.de.assuncao@ens-lyon.fr.

Laurent Lefèvre
email: laurent.lefevre@ens-lyon.fr.

Monte-Carlo Tree Search and Reinforcement Learning for Reconfiguring Data Stream Processing on Edge Computing

Distributed Stream Processing (DSP) applications are increasingly used in new pervasive services that process enormous amounts of data in a seamless and near real-time fashion. Edge computing has emerged as a means to minimise the time to handle events by enabling processing (i.e., operators) to be offloaded from the Cloud to the edges of the Internet, where the data is often generated. Deciding where to execute such operations (i.e., edge or cloud) during application deployment or at runtime is not a trivial problem. In this work, we employ Reinforcement Learning (RL) and Monte-Carlo Tree Search (MCTS) to reassign operators during application runtime. Experimental results show that RL and MCTS algorithms perform better than traditional placement techniques. We also introduce an optimisation to a MCTS algorithm, called MCTS-Best-UCT, that achieves similar latency with fewer operator migrations and faster execution time. In certain scenarios, the time needed by MCTS-Best-UCT to find the best end-to-end latency is at least 33% smaller than the time required by the other algorithms.

I. INTRODUCTION

Society is increasingly instrumented with sensors integrated to mobile phones, Internet of Things (IoT), and in systems for monitoring operational infrastructure, transportation and precision agriculture. These sources provide continuous data streams gathered and analysed by Distributed Stream Processing (DSP) applications that extract information required for decision making in near real-time.

A DSP application is often structured as a directed graph or dataflow whose vertices are operators that execute a function over the incoming data and edges that define how data flows between the operators. A dataflow has one or multiple sources (i.e., sensors, gateways or actuators); operators that perform transformations on the data (e.g., filtering, projection, and aggregation); and sinks (i.e., queries that consume or store the data). Traditionally, DSP applications were conceived to run on clusters of homogeneous resources or/and on the cloud. In a traditional cloud deployment, the whole application is placed on the cloud to benefit from virtually unlimited resources. However, processing all the data on the cloud can introduce latency due to data transfer between data sources and cloud servers. Edge computing is an attractive solution for performing certain stream processing operations as many edge devices have non-trivial compute capacity and are often geographically closer 1 to where the data is generated.

The task of scheduling operators of a DSP application on computing resources is generally referred to as operator placement; a problem that is exacerbated when considering the joint exploration of cloud and edge devices as assigning operators to heterogeneous resources has proven to be NPhard [START_REF] Benoit | Scheduling linear chain streaming applications on heterogeneous systems with failures[END_REF]. Moving operators from cloud to edge devices is also challenging due to limitations of devices and network latency. Existing work proposed several techniques to address the operator placement problem [START_REF] Lakshmanan | Placement strategies for internet-scale data stream systems[END_REF], some of which consider only cloud [START_REF] Xu | T-Storm: Traffic-aware online scheduling in storm[END_REF], [START_REF] Li | Model-free control for distributed stream data processing using deep reinforcement learning[END_REF], and others that consider edge computing [START_REF] Sajjad | Spanedge: Towards unifying stream processing over central and near-the-edge data centers[END_REF], [START_REF] Hochreiner | VISP: An ecosystem for elastic data stream processing for the Internet of things[END_REF], [START_REF] Cheng | Geelytics: Enabling on-demand edge analytics over scoped data sources[END_REF], [START_REF] Cardellini | Distributed QoS-aware scheduling in Storm[END_REF], [START_REF] Ni | Resource allocation strategy in fog computing based on priced timed petri nets[END_REF]. In previous work, we considered the placement of applications with feedback loops (i.e, data sinks/actuators at the edge) onto cloud and edge resources [START_REF] Veith | Latency-aware placement of data stream analytics on edge computing[END_REF].

Although the initial placement is important, operators may need to be reconfigured during an application life-cycle due to variable load conditions or device failures. The solution search space for operator reconfiguration can be enormous depending on the number of operators, streams, resources and network links. Moreover, in addition to improving the application end-to-end latency, it is important to minimise the number of operator migrations due to the time required to transfer operator state and code.

Reinforcement Learning (RL) and Monte-Carlo Tree Search (MCTS) have been used to tackle problems with large search spaces and states [START_REF] Gelly | Monte-carlo tree search and rapid action value estimation in computer go[END_REF], [START_REF] Vodopivec | On monte carlo tree search and reinforcement learning[END_REF], performing at human-level or better in games such as Go. In the present work, we model the operator reconfiguration problem as a Markov Decision Process (MDP) and investigate the use of RL and MCTS algorithms to devise reconfiguration plans that improve the end-to-end latency of DSP.

Hence, the main contributions of this paper are:

• We model the operator reconfiguration problem as an MDP and employ RL algorithms to devise reconfiguration plans that minimise the aggregate end-to-end latency of data events; • a performance evaluation comparing the RL and MCTS algorithms to traditional strategies used to compute the placement of DSP operators; and • a domain optimisation that improves the search time of a MCTS-UCT algorithm. The rest of this paper is organised as follows. Section II presents background information on Markov decision processes and reinforcement learning algorithms. Section III describes the system model and the optimisation problem for reconfiguring data stream processing applications. The proposed solutions are introduced in Section IV. The experimental setup and performance evaluation are presented in Section V. Section VI discusses related work, whereas Section VII concludes the paper.

II. BACKGROUND

This section describes background on Markov decision process and reinforcement learning algorithms.

A. Markov Decision Process

A Markov Decision Process (MDP) provides a decisionmaking framework where an agent makes decisions by interacting with a simulated environment over a number of steps. An MDP often comprises a set of environment states S including the initial state s 0 and a terminal state s |S|-1 , where each state s has a set of possible actions A(s) and a reward function R(s). At a non-terminal state, the agent picks an available action and interacts with the simulated environment to determine the state and reward for the next step.

The goal of solving an MDP is to determine the mapping from states to actions (i.e., policy), which maximises the reward. When the transition model and reward function are available, dynamic programming easily solves this task. Otherwise, the concept of an iterative approach remains the backbone of most RL algorithms. These algorithms apply greedy approaches based on MCTS and/or Temporal-Difference Tree Search (TDTS) in order to keep track of state transitions when evaluating the application using the MDP framework and by applying mathematical approaches to balance exploration of new solutions and exploitation of good and well-known ones.

B. Reinforcement Learning Algorithms

Reinforcement learning algorithms such as MCTS, TDTS and Q-Learning are considered in this work for reconfiguring DSP applications. By using such algorithms, an agent (i.e., the scheduler) interacts with a simulated environment using a model described later in Section III and transitions along states that maximise the reward.

1) Monte-Carlo Tree Search: is a simulation-based search mechanism consisting of running a number of simulations and building a search tree with the results [START_REF] Gelly | Monte-carlo tree search and rapid action value estimation in computer go[END_REF]. Each node n(s) of the search tree T represents a state s that has been seen during simulation. A node/state maintains a count N (s) with the number of times it has been visited, an action value Q(s, a) for each action a ∈ A(s) and a count N (s, a) with the number of times the action has been picked.

For each episode, the estimated value function can be updated with an incremental mean. A simulation or episode starts at the root state s 0 and is divided into two phases. First, when the state s t is found in the search tree, a tree policy is employed to select an action. Otherwise in the second phase a default policy continues the simulation until a terminal state. The simplest policy is greedy that selects max a Q(s, a) in the first phase and random actions during the second phase. MCTS attempts to approximate value functions from experience.

MCTS with a greedy policy can lead to inefficiencies by selecting actions among a small set, avoiding other actions after a few poor outcomes. The MCTS with Upper Confidence Bounds for Trees (MCTS-UCT) uses an optimistic approach in the face of uncertainty by giving a bonus that represents the uncertainty in the value of a state-action (i.e., explorationexploitation dilemma [START_REF] Sutton | Reinforcement Learning: An introduction[END_REF]). The tree policy picks actions using the UCB1 algorithm [START_REF] Sutton | Reinforcement Learning: An introduction[END_REF], which maximises an Upper Confidence Bound (UCB) on the action values. The policy tree selects the action a * that maximises the UCB value (C is a scalar exploration constant):

Q(s, a) = Q(s, a) + C 2lnN (s) N (s, a) (1)
a * = max a Q(s, a) (2)
2) Temporal-Difference Tree Search: while MCTS needs to wait until an episode ends to update the node and action values, the basic implementation of Temporal Difference (TD), i.e., T D(0), waits until the next step and updates the values after transitioning to a new state s t and receiving the reward R(s t ). Since TD bases its update on an existing estimate, it is said to be a bootstrapping method. A TD variant that unifies TD and MCTS and allows for specifying the number of future states on which estimates are evaluated is T D(λ) where a large value for λ will eventually result in MCTS behaviour.

TDTS-Sarsa(λ) is a TD method that combines Sarsa(λ) and UCT algorithms. The general Sarsa derives its name from how the policy evaluation algorithm is structured. A state-action (s, a) pair yields a reward R and takes the execution to a new state, s , at which the policy picks action a , and the value of this transition is evaluated to Q(s , a ). Sarsa(λ) considers m steps of experience [START_REF] Vodopivec | On monte carlo tree search and reinforcement learning[END_REF].

3) Q-learning: is a learning algorithm where an agent tries to learn an optimal state-action transition policy based on state-action rewards that it receives by interacting with the environment [START_REF] Sutton | Reinforcement Learning: An introduction[END_REF]. The agent computes the return of stateactions, the so called Q-values, so that it picks actions that maximise the reward. With Q-values computed the value of state s is:

Q(s) = max a Q(s, a) (3)
Action values are updated when transitioning from state s to s as follows:

Q(s, a) = Q(s, a)+α[R(s)+γmax a Q(s , a )-Q(s, a)] ( 4
)
where α is the learning rate and γ is the discount factor [START_REF] Sutton | Reinforcement Learning: An introduction[END_REF].

III. SYSTEM MODEL AND PROBLEM DEFINITION

This section describes the system model for operator placement introduced in our previous work [START_REF] Veith | Latency-aware placement of data stream analytics on edge computing[END_REF] and the reconfiguration problem tackled in the present paper.

A. System Model

The infrastructure is a graph2 N = (R, L) where R is the set of compute resources in the cloud and/or at the edge sites and L comprises the logical links interconnecting the resources. A compute resource is a tuple r k = cpu r k , mem r k , where cpu r k is its CPU capability in MIPS, and mem r k is its memory capacity in bytes. A network link is a tuple l k↔l = bdw k↔l , lat k↔l , where k ↔ l represents the interconnection of resources k and l, bdw k↔l the bandwidth in bps, and lat k↔l the latency in seconds. The latency of resource k to itself (i.e lat k↔k ) is 0.

A DSP application is a Directed Acyclic Graph (DAG) G = (O, E) of operators O that execute functions over the incoming data, and streams E of data events flowing between operators. Each operator is a tuple

o i = cpu o i , mem o i , ψ o i , ω o i ,
where cpu o i is the CPU requirement to handle an individual event, mem o i is the memory in bytes to load the operator, ψ o i is the ratio of number of input events to output events (i.e., selectivity), and ω o i is the ratio of the size of input events to the size of output events (i.e., data compression/expansion factor). The rate at which operator i can process events at resource k is denoted by µ i,k and is essentially

µ i,k = cpu r k ÷ cpu o i . An event stream e ρ
k→l ∈ E connects operator k to l with a probability ρ that an output event emitted by k will flow through to l.

The rate at which operator i produces events, λ out i , is a product of its input event rate λ in i and its selectivity ψ o i . The output event rate of a source operator depends on the number of measurements it takes from a sensor or a monitored device. Likewise, we can recursively compute the average size ς in i of events that arrive at a downstream operator i and the size of events it emits ς out i by considering the upstream operators' event sizes and their respective compression/expansion factors.

A compute resource can host one or more operators. Operators within the same node communicate directly whereas internode communication is done via a communication service that serialises events to be sent to another node, as depicted in Figure 1. Both operators and the communication service handle events in a First-Come, First-Served (FCFS) fashion and follow an M/M/1 queue model which allows for estimating the computation and communication times. The computation time stime oi,r k of operator i on resource k is given by:

stime i,k = 1 µ i,k -λ in i (5)
while the communication time ctime i,k j,l for operator i placed on resource k to send a message to operator j on resource l is:

ctime i,k j,l = 1 bdw k↔l ς out i -λ in j + l k↔l (6)
A mapping function M : O → R, E → L indicates the resource to which an operator is assigned and the link(s) to which a stream is mapped. The function mo i,k returns 1 if operator i is placed on resource k and 0 otherwise. Likewise, the function ms i→j,k↔l returns 1 when the stream between operators i and j has been assigned to the link between resources k and l, and 0 otherwise.

A path

p i = o 0 , o 1 , . . . , o n-1
, o n is a sequence of n operators and n-1 streams, starting at a source o 0 and ending at a sink o n . The set of all possible paths in the application graph is P. The end-to-end latency L pi of a path p i is the sum of the computation time of all operators along the path and the communication time required to stream events on the path. More formally, L pi is:

(7) L pi = o∈Or∈R mo o,r × stime o,r + r ∈R ms o→o+1,r↔r × ctime o,r o+1,r

B. Operator Placement and Reconfiguration Problem

Placing or scheduling a DSP application consists of finding a mapping M : O → R, E → L that minimises the Aggregate End-to-End Latency (AL) of all paths (Equation 8) that respects the resource and network constraints. A detailed description of all constraints is given in our previous work [START_REF] Veith | Latency-aware placement of data stream analytics on edge computing[END_REF].

AL = min pi∈P L pi (8)
As DSP applications are often long-running, during their life-cycle they can experience variable load requirements that change the working conditions of operators. Unlike the cloud, edge resources are often more constrained and less reliable, with higher failure rates. To preserve the application performance within acceptable bounds it is important to adjust the initial placement and conveniently migrate operators to available resources. Migrating operators can incur a cost regarding storing operator state, stopping an operator, migrating it and resuming it on a target resource. The present work focuses on finding a new mapping M : O → R, E → L or plan that improves the AL compared to the initial placement.

IV. REINFORCEMENT LEARNING BASED RECONFIGURATION OF DSP APPLICATIONS

This section first details how the reconfiguration is modelled as an MDP. After that, it presents an extension to the Upper Confidence Bounds for Trees (UCT) algorithm, and a domain optimisation to sort operators to be migrated

A. The MDP for DSP Reconfiguration

In the MDP considered for reconfiguration, a state s ∈ S contains a mapping of operator/stream onto resource/link(s) (i.e., M : O → R, E → L), where s 0 is the mapping provided by the placement algorithm. At each state there are x possible actions where x is the number of computational resources available. The set of actions A(s) at state s comprises the possible migrations of an operator to another resource, or maintaining the current mapping.

We can simulate the expected AL of new states by applying the model in Section III. The reward R(s) of a state s is given by the reduction of its aggregate latency AL s compared to the aggregate latency AL s0 given by the original mapping:

R(s) = AL s0 -AL s (9)
By solving the MDP one obtains a policy π(s) : s ∈ S → a ∈ A(s) with the migrations needed to reconfigure an operator deployment. An optimal policy picks migration actions that maximise the reward and hence minimise the AL.

B. MCTS-Best-UCT

We propose a strategy that extends MCTS-UCT by storing the UCB value at each node and enabling a search for the best UCT node. The MDP reconfiguration model allows for making any node terminal as it contains a valid stream and operator mapping. Algorithm 1 depicts the M CT SBestU CT function that receives the current mapping s 0 , initialises the search mechanism and builds the tree. M CT SBestU CT is similar to MCTS-UCT, but with different function behaviours. T reeP olicy (line 9) returns the node with highest UCT value, whereas MCTS-UCT starts the search at the root and estimates the UCT values up to a new state n / ∈ T . Def aultP olicy (lines 15-17) expands and simulates f (s(n), a) for the new node n taking a random action from the input node. Backup (lines 19-23) includes and updates the UCB value for each node as well as the N (s) count and Q value.

C. Building a Deployment Hierarchy (DH)

The search space of the application reconfiguration can be large due to the number of available computing resources and application operators. DSP applications can be time-sensitive and have some sinks on the cloud while other sinks are placed on the edge, providing information to actuators or warning systems. When optimising the AL, one can assume

N (n) ← N (n) + 1 21 Q(n) ← Q(n) + ∆ 22 U CT (n) ← Q(s,a) N (s,a) + C 2lnN (s) N (s,a) 23 n ← parent of n 24 Function BestChild() 25 return argmax n ∈T U CT (n )
that operators that communicate only with data sinks on the cloud have less priority than operators that send data to sinks on the edge.

We propose a domain optimisation approach that sorts operators by their potential impact on aggregate end-to-end latency when assessing the application reconfiguration. The approach builds a hierarchy of region dependencies (i.e. downstream and upstream relations between regions) and ignores sources and sinks as we consider that their placement is user-defined and do not change. Hereafter called Deployment Hierarchy (DH), the approach identifies the split points used to build a deployment hierarchy of operators and determine which operators can be placed on the edge and which should be hosted in the cloud. This deployment hierarchy is used for sorting operators to build the MDP for reconfiguration, hence increasing the chance that operators with greater impact on AL, and that are likely to be moved to edge resources, are evaluated first.

V. EVALUATION

This section describes the experimental setup and results.

A. Experimental Setup

We use a framework built in house atop OMNET++ [START_REF] Veith | Latency-aware placement of data stream analytics on edge computing[END_REF] to model and simulate DSP applications. We resort to simulation as it provides a controllable and repeatable environment. Our edge devices are modelled as Raspberry PI's 2 (RPi) (i.e., 4,74 MIPS at 1 GHz and 1 GB of RAM), and the cloud servers as AMD RYZEN 7 1800x (i.e., 304,51 MIPS3 at 3.6 GHz and 1 TB of memory). The infrastructure comprises two edge sites with 20 RPi's each and a Cloud with 2 servers. A gateway interfaces each edge site's LAN and the external WAN (the Internet). The LAN latency is uniformly distributed between 0.015 and 0.8 ms with a bandwidth of 100 Mbps. The WAN latency is drawn uniformly between 65 and 85 ms, and bandwidth of 1 Gbps. The latency values are consistent with measurements carried out in previous work [START_REF] Hu | Quantifying the impact of edge computing on mobile applications[END_REF].

We consider two applications with multiple data paths, shown as AppA and AppB in Figure 2. The graphs were crafted using a Python library 4 and their orders are based on the size of RIoTBench [START_REF] Shukla | Riotbench: An iot benchmark for distributed stream processing systems[END_REF] applications -a Realtime IoT Benchmark suite. Moreover, for each application we generated 15 different configurations by randomly varying: (i) the application input event size and rate; (ii) operators' selectivity, data compression rates, memory and CPU requirements; and (iii) the location of sinks and sources, except for the sink on the critical path (17 for AppA and 21 for AppB) which is always hosted on the cloud. The parameters were drawn uniformly from the ranges presented in Table I. All reported results for each application are averages values of these 15 different configurations.

The reinforcement learning algorithms consider an execution budget of 10,000 simulations. The considered metrics used to evaluate the algorithms performance are:

• latency improvement in (%), which represents the percentage of latency improvement under the given execu-tion budget of the MCTS algorithms and Q-Learning; • algorithm execution time (in seconds), the time required by each algorithm to complete the execution budget; • time to best latency (in seconds), the time required by the algorithm to find the best latency achievable under the allotted execution budget; • number of operator migrations needed by the devised plan to achieve the latency improvement; and • minimum AL (in ms) achieved when the simulations of the allotted budget finish.

B. Performance Evaluation

The entire application graph, except for sinks outside the critical path and data sources, are initially placed on the cloud. This is called the cloud-only placement. The algorithms are then evaluated under the following scenarios:

• Scenario 1: The MCTS algorithms, Q-Learning and MCTS-Best-UCT receive the cloud-only placement and run during the assigned execution budget in order to devise a reconfiguration plan that improves the AL. The algorithms are evaluated under two distinct cases, namely without DH and with DH. • Scenario 2: Consists of evaluating the minimum AL achieved the proposed solution and by state-of-the-art algorithms: cloud-only, Taneja's [START_REF] Taneja | Resource aware placement of iot application modules in fog-cloud computing paradigm[END_REF], and RTR and RTR-RP that we proposed in previous work [START_REF] Veith | Latency-aware placement of data stream analytics on edge computing[END_REF]). We also evaluate the baseline approaches in MCTS-UCT, TDTS-Sarsa(λ), and Q-Learning -described in Section II.

Taneja's algorithm iterates each item of the application graph, organises the computational resources and gets the middle term resource considering the CPU capacity. RTR is a greedy algorithm that places operators incrementally by evaluating the end-to-end latency of paths, and RTR-RP explores application graph patterns and the location where the sink is assigned to optimise placement. RTR-RP is essentially RTR with DH. 1) Scenario 1: Figures 3 and4 summarise the results on latency improvement and execution time of each algorithm for AppA and AppB, respectively. All algorithms substantially improve the AL, with improvements above 20% for both AppA and AppB. MCTS-Best-UCT achieves improvements that are similar to those obtained by the other algorithms. However, it requires less time to achieve such improvements, specially under the case without DH. MCTS-Best-UCT performs better because it needs to simulate only the next state s for obtaining the Q-value for bootstrapping, unlike the other algorithms that need to iterate until a terminal state. Moreover, the introduction of DH in the other algorithms improves their execution times, but they still remain higher than those achieved by MCTS-Best-UCT.

Figure 5 shows the time required by each algorithm to find the best latency achievable under the allotted execution budget. MCTS-Best-UCT again provides the shortest time to best latency compared to the other algorithms. For AppA, the time needed by MCTS-Best-UCT is at least 64% smaller than the time required by MCTS-UCT -the best of the remaining algorithms without DH -and over 33% smaller than MCTS-UCT with DH. Overall, the introduction of DH improves the time to best latency of all algorithms. DH does not improve the time to best latency of MCTS-Best-UCT for AppB by much because the application has its latency improved by migrating most operators to edge resources (see Figure 6), which is discovered early on by the algorithms. From this point onwards, the gain brought by DH becomes negligible. Figure 6 summarises the number of operator migrations for AppA and AppB without DH and with DH. MCTS-Best-UCT requires fewer migrations than TDTS-Sarsa(λ) and MCTS-UCT. This is because it finds the operators that have the greatest impact on AL, mainly operators that are selective, and moves them to edge resources, which in turn reduces the amount of data transferred over the WAN. The other algorithms require the support of DH to perform similarly to MCTS-Best-UCT. However, as shown earlier, they have a higher execution overhead. Q-learning performs less mi-grations, but it has a very high execution time and small improvement in latency.

2) Scenario 2: Figure 7 summarises the results on minimum AL with and without DH. The RTR and Cloud-only are evaluated without applying DH because they consider the whole application dataflow. RTR-RP, as mentioned earlier, builds the DH as the algorithm optimises the number of operators to be reassigned. The results show that the RL approaches can improve and provide more stable operator reconfigurations regarding AL than the state-of-the-art. The reason is that RL algorithms balance exploration and exploitation of solutions. Also considering AL, MCTS-Best-UCT outperforms Taneja's algorithm and Cloud-only by over 25%, and RTR by over 15% without DH. With DH our proposed algorithm still outperforms RTR-RP by over 33%. When compared to the other RL algorithms, on average MCTS-Best-UCT reduces in average the latency in 19%. This improvement seems small, but needs to be considered together with the substantial reduction in algorithm execution time that it achieves as discussed in Scenario 1.

VI. RELATED WORK

Existing work proposes architecture to place certain stream processing elements on resources located closer to where the data is generated [START_REF] Buddhika | Neptune: Real time stream processing for internet of things and sensing environments[END_REF], [START_REF] Cheng | Geelytics: Enabling on-demand edge analytics over scoped data sources[END_REF] or employs mobile devices for stream processing [START_REF] Morales | Symbiosis: Sharing Mobile Resources for Stream Processing[END_REF], [START_REF] Elbamby | Proactive edge computing in latency-constrained fog networks[END_REF]. The problem of placing DSP applications onto heterogeneous hardware is at least NP-Hard as shown by Benoit et al. [START_REF] Benoit | Scheduling linear chain streaming applications on heterogeneous systems with failures[END_REF]. To simplify the placement problem, communication is often neglected [START_REF] Cheng | Geelytics: Enabling on-demand edge analytics over scoped data sources[END_REF]. Likewise, the operator behaviour and requirements are oversimplified using static splitting decisions as proposed by Sajjad et al. [START_REF] Sajjad | Spanedge: Towards unifying stream processing over central and near-the-edge data centers[END_REF].

Effort has been made on modelling the placement problem of DSP applications on heterogeneous infrastructure [START_REF] Ni | Resource allocation strategy in fog computing based on priced timed petri nets[END_REF] using techniques such as Petri nets. Eidenbenz et al. [START_REF] Eidenbenz | Task allocation for distributed stream processing[END_REF] evaluated series-parallel-decomposable graphs to decompose the application graph and use an approximation algorithm to determine the placement. Taneja et. al. [START_REF] Taneja | Resource aware placement of iot application modules in fog-cloud computing paradigm[END_REF] offer a naive approach for deploying an application graph across cloud and edge while respecting a set of constraints.

Reinforcement learning [START_REF] Sutton | Reinforcement Learning: An introduction[END_REF] and MCTS have demonstrated great potential in addressing problems with large search spaces, such as the game of Go [START_REF] Gelly | Monte-carlo tree search and rapid action value estimation in computer go[END_REF]. It has been used in addressing scheduling problems [START_REF] Orhean | New scheduling approach using reinforcement learning for heterogeneous distributed systems[END_REF], [START_REF] Mai | Real-time task assignment approach leveraging reinforcement learning with evolution strategies for long-term latency minimization in fog computing[END_REF] and elasticity of DSP applications [START_REF] Russo | Multi-level elasticity for wide-area data streaming systems: A reinforcement learning approach[END_REF]. The present work considers RL and MCTS for addressing the problem of reconfiguring DSP applications on cloud-edge environments while minimising the aggregate end-to-end latency of processing graphs.

VII. CONCLUSIONS AND FUTURE WORK

This paper explored the reconfiguration of data stream processing applications. It proposed the MCTS-Best-UCT algorithm to reconfigure the applications in order to minimise the aggregate end-to-end latency while reducing the number of required iterations in the simulations to create an episode. We optimise the number of operators to be reassigned by applying a method named Deployment Hierarchy, which prioritises certain operators and avoids reassigning those that only process and forward events to sinks on the cloud. We also compared the performance of Monte-Carlo Tree Search and Reinforcement Learning algorithms. Our solution was evaluated considering applications with generic application behaviours. We simulated reassigning application operators using our approach and compared it against state-of-the-art MCTS algorithms and Q-Learning. The results showed that our approach is capable of achieving similar or better latency improvement while being faster and requiring fewer operator migrations. In certain scenarios, the time needed by MCTS-Best-UCT to find the best aggregate endto-end latency under a given execution budget is at least 33% smaller than the time required by the other evaluated algorithms.

As future work we aim to investigate machine learning techniques to optimise the energy consumption, and the monetary and migration costs of reconfiguring data stream processing applications on a real cloud-edge infrastructure.

Fig. 1 :

 1 Fig. 1: Example of four operators and their respective message queues placed on two resources.

Algorithm 1 : 2 create root node n 0 with state s 0 3 while within computational budget: 4 n 10 Function 16 ∆

 12341016 The MCTS-Best-UCT algorithm.1 Function MCTSBestUCT(s 0 ) Expand(n)11 choose a ∈ untried actions from A(s(n)) at random 12 add a new child n to n with s(n ) = f (s(n), a)and a(n) = a ← R(s(n ))17 return n , ∆ 18 Function Backup(n, ∆) 19 while n is not null:

20

 20

Fig. 2 :

 2 Fig. 2: Evaluated applications.

Fig. 3 :Fig. 4 :

 34 Fig. 3: Latency improvement and the algorithms execution time for AppA.

Fig. 5 :

 5 Fig. 5: Time to achieve the best latency for AppA and AppB.

Fig. 6 :

 6 Fig. 6: Number of operator migrations for AppA and AppB.

Fig. 7 :

 7 Fig. 7: Minimal AL of state-of-the-art against RL approaches with/without DH.

TABLE I :

 I Operator attributes.

	Parameter	Value	Unit
	cpu	1-100	MIPS
	Data compression rate	10-100	%
	mem	100-7500	Bytes
	Input event size	100-2500	Bytes
	Selectivity	10-100	%
	Input event rate	1000-10000 Number of messages
	AppA		AppB

We use geographical closeness as synonymous to latency closeness.

The graph is directed, with each link comprising two arcs, namely for download and upload. For the sake of simplicity, however, we represent links here as bidirectional.

https://reddit.com/r/BOINC/comments/5xog5v/ boinc performance on amd ryzen

https://gist.github.com/bwbaugh/4602818

ACKNOWLEDGEMENTS

This work was performed within the framework of the LABEX MILYON (ANR-10-LABX-0070) of the University of Lyon, within the program "Investissements d'Avenir" (ANR-11-IDEX-0007).


Stéphane Esquerré

Court structure and legal efficiency, the case of French échevinage in bankruptcy courts

come

Court structure and legal efficiency, the case of French échevinage in bankruptcy courts

Introduction

In most countries, bankruptcy is judged by common law courts. Only few countries including the USA or France have a specialised jurisdiction to judge bankruptcy. France is also unique with most of its bankruptcy judges being elected among businessmen. Since 1563, French bankruptcy judges have been lay judges 1 , called consular judges, elected among businessmen in each jurisdiction 2 . Thanks to an historical accident, France has another judicial in [START_REF] Lazega | Polynormativité et contrôle social du monde des affaires : l'exemple de l'interventionnisme et de la punitivité des juges du Tribunal de commerce de Paris[END_REF] for example).

These results have lead some authors to question the need for judges rather than a well-refined regulation [START_REF] Shleifer | The Failure of Judges and the of Regulators[END_REF] which is not affected by biases. Shleifer also argues over the judges' legitimacy in their expertise, for example when they judge business issues. Results from several papers award shortcomings in many bankruptcy reforms to the lack of expertise from judges, for example in the Czech Republic [START_REF] Johnson | World Bank Report on Observance of Standards and Codes, Insolvency and Creditor Rights Systems[END_REF] or in Lithuania (Johnson, 2002), as mentioned by [START_REF] Ayotte | Matching bankruptcy laws to legal environments[END_REF]. The same drawback also explains in part the failure in the US-inspired Hungarian bankruptcy system where the trustees in charge were given too much discretion with an inappropriate compensation scheme biasing their decisions [START_REF] Franks | A Study of Inefficient Going Concerns in Bankruptcy[END_REF].

We must stress out a possible limit in these arguments. They tend to reduce Courts to a single judge while the interactions between judges matter. Our chapter is also interested in asking how the various sets of skills born by lay and professional judges can differ in courts only formed by lay judges. [START_REF] Lazega | A spinning top model of formal organization and informal behavior: dynamics of advice networks among judges in a commercial court[END_REF] reports the interviews of French judges in the Parisian Commercial court with only consular judges.

They show that a social network emerged where they share skills on specific business issues. Other evidences of this socialisation is shown by [START_REF] Vidal | Bias in open peer-review: evidence from the english superior courts[END_REF] in the English Court of Appeal: judges tend to quote citations from esteemed colleagues. Their citations show how their decisions are affected by their social network.

Most importantly, this chapter is driven by the question linking court's organisation and efficiency of bankruptcy. Such organisation may raise economic, financing and policy issues. As stressed by [START_REF] Ayotte | Matching bankruptcy laws to legal environments[END_REF], in an incomplete contract world, a debtor friendly bankruptcy law like the French one needs for the judges to screen out viable firms within the bankrupt ones. Otherwise the creditors are more at risk when lending and more prone to credit constraint. If a lay court tends to promote reorganisation despite lack of business opportunities or, on the contrary, if a professional judge wishes to apply more strictly the French law to reorganise before considering debt collection by the creditors6 , then courts would tend to promote type I error with a negative impact on the lending channel.

Lay courts are composed of experts only with a high knowledge of each business customs. They are also proud to judge with equity, that is to interpret the law as to enforce a good decision according to them7 . In 2018, legal training became mandatory for French consular judges, it consists as 8 days as initial training, and two days as training each year8 . This training used to be optional beforehand but not mandatory.

Many legal professionals, like those of the judges trade union (Union sociale des magistrats) have always claimed it is far from enough to learn the law and how to judge (see [START_REF] Untermaier | Rapport d'information n•1006 sur le rôle de la justice en matière commerciale[END_REF]. It is all the truer for small bankruptcy courts where experiences is thus limited. It is sometimes argued that their judgment may heavily rely on all the legal experts who work with them in courts, such as court's clerks or the insolvency practitioners. The other main criticism builds upon their impartiality. As noted in a report from the Council of Europe (GRECO, 2014), consular judges sit as benevolent judges so they keep on earning their wages from their business, or they depend on the revenues of their own business. This can lead to a conflict of interest. The issue was addressed in the 2016 Justice law with a code of ethics. It is written by the National Council of Commercial Courts, composed of consular judges and instated in 2018. The rule of ethic is left at the discretion of the judge.

Having these drawbacks in mind, two main arguments can be assessed regarding the generalisation of mixed-courts9 : improvement of judiciary human capital; more transparency for investors, and in particular international investors. Yet the efficiency brought by mixed courts rely on the the trust and cooperation between professional and lay judges as shown by [START_REF] Machura | Lay assessors of german administrative courts: fairness, power-distance orientation, and deliberation activity[END_REF] in its study of German administrative mixed courts. Machura, 2016 notes that professional judges have gained prestige through their legal studies, familiarity with work routines, and specialized legal knowledge. He shows that lay judges can work well with professional judges when they are seen as experts ; and when they have a strong sense of justice that helps them question the decisions of professional judges. Overall success in mixed courts depends on mutual appreciation. Peaceful collaboration is not ensured out-side Alsace-Moselle. Échevinage is a sensitive issue for consular judges in France judging from how the question has caused threats of strike and resignation letters sent to the French minister of justice10 .

Mixed and lay courts are considered meaningful by allowing citizens to be involved(se e [START_REF] Hans | Introduction: lay participation in legal decision making[END_REF]. Rather than this policy question, we want to tackle the economic efficiency of the court's organisation. Bankruptcy literature distinguishes between ex-ante and ex-post efficiency. Ex-post efficiency in bankruptcy deals with the maximisation of the value of the firm by the court. The court must choose if it allows the firm to reorganize or, on the contrary, to be liquidated. It is especially true in France where the court can decide to reorganize the firm despite the creditors' wish for liquidation11 (see [START_REF] Blazy | un)secured debt and the likelihood of court-supervised reorganization[END_REF] on this liquidation bias). A bankruptcy court makes ex-post efficient decisions if it is able to screen efficiently firms. It should prevent type I errors (reorganization of firm that should be liquidated) and type II errors (liquidation of firms that should be reorganized).

Ex-ante efficiency of bankruptcy embraces direct impact on broad economic outcomes which concern all the firms and not only the distressed ones.

In line with our previous argument, [START_REF] Brown | Does law and finance matter? lessons from externally imposed courts[END_REF] show that tribal courts in Native-American reserves are less predictable and thus have weaker credit markets than jurisdictions with state courts. The authors prove that this distinctive feature in courts leads to significant decreases in broad economic outcomes such as lower levels of per capita income. [START_REF] Ponticelli | Firms, local courts and bankruptcy in brazil[END_REF] looks at the efficiency in the implementation of a creditorfriendly bankruptcy reform in Brazil. The success in its implementation depends on the court's efficiency proxied by its congestion. The effect does not only concern bankrupt firms, it concerns all firms in the jurisdiction.

Most efficient jurisdictions end up with higher profitability after the reform.

We will consider in this chapter ex-ante efficiency as the incentive to file for bankruptcy when facing financial distress. The firm can no longer resolve its financial situation with out of court settlement. It is an important function of bankruptcy to ensure the best use and reallocation of capital rather than its loss.Misuse of capital happens if the distressed firm would linger in bankruptcy while it needs to be liquidated ; or because the firm missed busi-ness opportunities instead of restructuring its debts under reorganisation 12 .

We do not consider here ex-ante as the impact on financial relationship and contracts design.

At last, our chapter builds upon a policy debate that has been well-worn in France since 1981. Should we leave merchants' business decisions for merchants to decide as it was the impulse for the creation of the bankruptcy courts during the Italian commercial revolution 13 from the XIVth century?

Or should we generalize échevinage considering the increase in judicial technicalities plus the possible lack of independence from lay judges? The debate went on in France with strikes from consular judges in 1984, 1997 or again in 2014 each time a new reform was discussed.

In order to investigate differences in judgments, we get a hold of data on French businesses with available financial information in Alsace-Moselle and the bordering counties (département administratif ). Half of the firms are in Alsace-Moselle (51%). We choose to use survival analysis to understand filing decisions by the firms; choice of bankruptcy proceedings by the court (either liquidation or reorganisation); and lastly how courts are able to shut down non-viable businesses (either directly or by stopping the reorganisation process). We start following firms from the implementation of a new bankruptcy rating by Altares-D&B in march 2011 with monthly updates over a year 14 . We consider firms being "at-risk" when their rating dropped over a month, meaning an increase in their bankruptcy risk over the next twelve months. We then study the possible outcomes: a raise in their rating and drops in their bankruptcy risk; filing for bankruptcy; or a voluntary shut-down with no debt issues. We want to test court's efficiency ex-ante examining how fast firms file for bankruptcy after being "at-risk".

We test ex-post efficiency looking at the liquidation and survival rates of firms that were reorganised. We look at ex-post efficiency only for Type-I errors, reorganisation of firms that should have been liquidated. We cannot infer relative efficiency of courts for Type-II errors, firms that are liquidated which should have been reorganized. 12 We follow [START_REF] Blazy | Employment preservation vs. creditors' repayment under bankruptcy law: the french dilemma?[END_REF]: a bankruptcy law is ex-ante efficient when failing firms have incentives to file rather than let their financial information get worse off.

13 Polanyi and MacIver, 1944 14 The European debt crisis started only one year before this date. There is no reason to think Alsace-Moselle firms faced a different situation than firms from the rest of France except for geographical reasons, such as proximity to Germany. We measure this proximity by the distance to the administrative line that separates both areas.

We find that bankruptcy rates are smaller in mixed-court jurisdictions than in lay courts (1.11% vs. 1.51%). This result must be related with lower chances of being reorganised within mixed courts (30% vs. 48%). Survival analysis also allows for comparing the times to decisions. They are similar for all outcomes except for reorganisation that happens faster in lay courts.

Lay courts might increase incentives to trigger the procedure more quickly and to preserve the value of the debtor's assets. Lay courts could be more efficient ex-ante. Yet this hinders the fact that lay courts show the same liquidation rates as mixed court. Indeed when the court decides that the firm can be reorganised, it can still abort the plan, and liquidate the firm if the reorganisation process fails.

We show that the reorganisation rates from lay courts hide more type-I errors, i.e. reorganised firms that should be liquidated. While mixed courts, despite lower ex-ante incentives to file for bankruptcy, have similar performances over the re-allocation of capital, in screening non-viable firms through liquidation.

To the best of our knowledge, we report the first evidence of deviations in applying bankruptcy law brought by structural differences. Even with a same set of laws, both organisations do not have the same bankruptcy policy. Furthermore, both courts' organisations have similar results regarding their ability to screen out non-viable firms. A welfare cost analysis would probably show entrepreneurs outside Alsace-Moselle being better off with better chances of reorganisation, while creditors would rather have less uncertainty regarding their debt collection. Since this idea raises an endogeneity issue, we make a robustness check with a 2SLS model. Échevinage is instrumented with local tax rate. The coefficient showing the impact of échevinage is reduced. We find overall similar results in terms of significance except from some of our subsample.

The rest of the chapter proceeds as follows. Section II gives more background about the comparison between échevinage and consular judges. Section III develops our empirical strategy. Section IV provides information on the data used in the samples. Section V analyses the impact of échevinage ex-ante in filing for bankruptcy, in the selection of a proceeding and in the liquidation process. Section VI concludes. This exception is upheld by a French law in 1923 and even extended to Sarreguemines and Thionville in 1978, and Saverne in 1989. In Alsace-Moselle, commercial law is served in a special chamber of the regional courts (Tribunal de Grande Instance). This chamber is composed of a professional judge acting as president and two consular judges elected since June 192418 .

Context

Differences in organisation of French bankruptcy courts

Most of the French bankruptcy organisation in France is made of 134 commercial courts over mainland France including only 7 mixed courts in Alsace-Moselle (plus 9 mixed courts overseas). Commercial court is a specialized first degree court. Bankruptcy is one of its area of expertise but so are commercial disputes and various commercial acts. In Alsace-Moselle, commercial issues are decided in commercial chambers from a Tribunal de Grande Instance, i.e. the French equivalent to High Courts.

Each commercial court is composed by one president of the court who is elected for four years by the other bankruptcy judges. While in Alsace-Moselle, the president of the court is a career judge. Bankruptcy judges, rather called consular judges are merchants or business persons chosen by their peers through a two-stage election. Their first mandate lasts two years and they can be reelected for four years up to four times19 .

In Alsace-Moselle, some small business disputes are settled outside the commercial chamber. But the bankruptcies are only filed in the commercial chamber. The president of the chamber cannot be replaced by another consular judge unlike in the rest of France (art. L. 731-4 of the Code of Commerce). Last, it is the duty of the president to prevent financial and economic distress in its jurisdiction. This can raise an issue in Alsace-Moselle since legal training may not help professional judges in setting the best organisation to do so. But they can get advice from consular judges who assist them.

French bankruptcy judges

There are three explanations for the success of consular justice. For the state, it is seen as a cheap organisation, even if [START_REF] Montebourg | Tribunaux de commerce , une justice en faillite[END_REF] has shown that this argument should be qualified with the reimbursement of some of the consular judges' expenses. It has always been a fast justice compared to the ordinary one. Tenants of the lay courts deem that decisionmaking is a lot faster than in usual courts. And the business expertise of the judges is also supposedly appreciated by the debtors. However the latter argument should be questioned depending on the size of the firm, and the size of the court. In the biggest court such as Paris, many consular judges are senior executives with very different experiences and opinions on business compared to small firm entrepreneurs.

The legitimacy of lay judges is the main subject of criticism by the legal professionals who question their impartiality. This is all truer for French bankruptcy judges. While consisting of volunteers, some courts have been accused of collusion in their judgments (see [START_REF] Gaudino | La mafia des tribunaux de commerce[END_REF][START_REF] Montebourg | Tribunaux de commerce , une justice en faillite[END_REF]GRECO, 2014). Since 2018, lay judges need to take the vow and have ethical obligations like the other French magistrates with a specific code of ethics.

If there is a challenge of a consular judge, the Code of Civil Proceeding (article 349) and if the judge opposes this challenge or does not answer, the matter is decided by the president of the court, and not the superior jurisdiction. There is no possibility to plea afterwards.

As such, involving a legal professional should enhance the transparency of the decisions. It would also prevent international investors to avoid some opportunities because of the uniqueness of French bankruptcy courts.Provine (1998) actually shows that although decisions by lay judges are similar to those of professional judges, the main difference deals with the cautiousness from plaintiffs. Lay judges' decisions are perceived as less predictable to career judges because of personal interpretation of the law [START_REF] Deffains | Analyse économique de l'échevinage dans la justice commerciale[END_REF].

The decision to leave commercial judicial affairs to merchants, based on their expertise, was often discussed. With commercial law becoming more and more complex, the need for deep legal knowledge was also deemed Aside from these arguments, the French policy debate seems to revolve around a cost-benefit analysis. Actually, adding a legal professional to preside the court is an expensive measure. It implies to increase recruitment while the decisions over the extension of public forces is strongly debated.

Lay courts provide a nearly costless institution which partly explains why échevinage remains limited to Alsace-Moselle. The absence of legal professionals also allows for the court's organisation to be less formal.

Data

Sources and data selection

Data on bankruptcies can be found in many legal sources ranging from legal advertisements in newspapers to official publications in the Bodacc. Our dataset originates from Altares, a French company specialized in the gathering and homogenization of these various sources of information on corporate bankruptcy. Altares-D&B allowed us to use all these various sources to ensure we do not lack some events after a firm has filed for bankruptcy. We can infer all the judicial process from its filing to the end of the bankruptcy.

Since Altares data lack information on the creditors (identity, due claims, debt collection), we focus on the proceeding's success and the firm's survival. To do so, we merge this information with the Courts' decisions and the survival of firms.

To estimate the probability of bankruptcy, we used the monthly scores of all French firms from the launch of Altares-D&B new score in March 2011 and for 13 months. The score is computed for all French firms but we wanted to be able to test for other information than the score. It estimates the likelihood of insolvency proceedings (safeguarding procedure, administration or winding up) within 12 months with a logistic regression. It is made of a combination of variables (for example: Has published / Obligation to publish / Age of latest publication), mostly financial ratios and aggregates. We can map the logistic output of the score with a bankruptcy risk within the next 12 months. The score was then broken into risk-buckets into 4, 20, and 100 levels.

We select only firms with financial information publicly available within the 24 months before the firm is scored. Our sample contains only firms created at least two years before the score. Distressed firms tend to stop publishing their financial information. But the selection bias is limited by the use of profitability and size ratios. It ensures that possible differences in financial information availability between Alsace-Moselle and the rest of France do not bias our results. Overall financial information is available only for roughly a third of all French businesses. Its availability increases with the size of the firm. More than half of bankrupt firms that have at least one employee have available financial information. This increases to 80% of the firms that have more than 50 employees 20 .

We use several financial ratios, four to define the size of the firm and one for the profitability. We have limited ourselves to five ratios/indicators and tested them to prevent collinearity with our bankruptcy rating which is also based on financial information. The size of the assets is a good measure of the economic weight of the firm. This size will give incentives to court to let the firm reorganise. At the same time, the more the assets, the harder it is to reorganise in case of economic distress. The turnover of the firm is an alternative measure of size which depends on the yearly business activity.

It needs to be taken into account with a profitability ratio to see if the firm is solvent. We take profit with the EBIT over the sales for our profitability ratio. The last important size ratio is the number of employees. As for the size of the assets, it should give incentives to the court to let the firm be reorganized and, at the same time, a firm which is too big may have reduced chances to reorganise if the firm needs to change its business model and its use of labour.

We also have general business information given by the French census.

We can include the firm's age, its business activity, its legal form and its location. We use the latter to compute the distance to the administrative line that separates Alsace-Moselle from the rest of France. As in Chemin and Wasmer, 2009, we reduce our geographical selection of firms to Alsace-Moselle and the neighbour French departments. We select all the six departments that share an administrative border with Alsace-Moselle 21 . Our sample contains 60 000 observations in Alsace-Moselle and the districts nearby.

Descriptive statistics

We compare firms located in Alsace-Moselle to other French firms outside of this area. We consider successively our whole sample (Table 1) and next two subsampless. The first subsample uses the administrative line that separates Alsace-Moselle from the rest of France. We get the first quartile of firms that reside the closest to the administrative line on each side (Table 2). By doing so, we limit the influence of Germany on Alsace-Moselle firms. Firms next to the border may have different business activities due to their proximity to Germany than in the rest of France. Also firms the closest have greater chances of sharing similar business opportunities, culture and employment zone. The second subsample selects only the firms with the highest bankruptcy score before the increase in bankruptcy risk (Table 3).

We select the firms in the highest of the four risk buckets proposed by Altares' score, called Very high risk. In this state of financial distress, the firms have less opportunities on out-of-court settlements. Out-of-court settlements may be different depending on local culture in Alsace-Moselle versus the rest of France. In this subsample, the incentive to file for bankruptcy heavily depends on the expectations of the court.

We want to estimate the probability of bankruptcy after the firm has an increase in its bankruptcy risk. The score allows us to do so when the firm's 20-score drop by at least one unit. Our main concern is to check whether the risk distribution over firms is different in Alsace-Moselle and in the other area. We have two means to do so. First, looking at the distribution in the four risk buckets of the Altares score (from very low to very high risk).

Then, we look at the estimated chances of bankruptcy. Since each score can be matched to a bankruptcy risk we can compute an average probability risk.

The estimated risk is relatively the same throughout all samples. The distribution in risk buckets shows that Alsace Moselle has more firms with very high bankruptcy risk. Yet when we focus on this subpopulation only (Table 3), the estimated risk is a 1-percentage point higher than outside Alsace-Moselle. We see a similar difference in Table 2. This explains why we use estimated risk rather than the risk buckets in our empirical model.

Overall firms looked really similar on average on both sides of the administrative border. Looking only at financial variables, we observe that firms in Alsace-Moselle are marginally bigger, considering both their size of assets and number of employees (see Table 1). This remains true when we look closely at firms within the closest distance to the administrative line (Table 2), or in the very bankruptcy risk bucket (Table 3). In the first two tables, firms in Alsace Moselle are shown to be less profitable than their counterparts (shown by their profit, EBIT, as a share of their sales). It is only in Table 3 that we have a reverse situation with profitability ratio lower in Alsace-Moselle than in the rest of France, yet standard deviation is also higher (20 vs. 19).

Apart from the risk and financial ratios, we have two other main sets of controls: business activity and legal forms. Both can have huge impact. If an area were more specialized in a specific type of business, differences in bankruptcy rates between the two areas could be explained by heterogeneity on how they cope with economic bad times. Only two sectors differ by more than a percentage point in our whole sample, manufacturing (16% in Alsace Moselle vs. 19% outside) and wholesale-retail (33% vs. 30%).

Fortunately, our subsample with only the closest firms resolve this issue (Table 2), even if the discrepancies for the Manufacturing sector slightly increase to 2 percentage points.

The concern over legal forms depends on limited liability. Firms with normal or simplified LLC differ only marginally on this issue. More than four out of five firms are LLC firms on both sides of the administrative line. In all our samples, the other legal forms are scarce and the differences between the two sides of the administrative border are lower than 1 percentage point.

Identification strategy

Survival analysis

In the first step of our strategy, we want to estimate the ex-ante efficiency of each type of Court. To do so, we analyse the choices made by the Court when the firms file for bankruptcy and the delays from the moment a firm becomes at risk and the time when it is reorganised or liquidated. Actually, after a firm becomes at risk and enters our sample, several outcomes are possible: (i) its bankruptcy risk drops because its situation improves and its score increases toward a lower risk ; (ii) the managers decide to shut down the firm without filing for bankruptcy if there is no dispute with the creditors ; (iii) filing for bankruptcy. Because of all these outcomes, we choose a competing risk model.

We want to analyse the filing for bankruptcy in general but also the choice made by the Court, between the three above mentioned legal proceedings as mentioned before. We summarize all possible outcomes in Table 1. We choose to assume independent censoring between events with the controls we have set on. This may be a strong assumption, it would mean for example that the times to liquidation or to reorganisation for the same firm would not be affected by one another. In reality, both potential outcomes are strongly linked. Yet the discrete-time setting and the number of events prevent to do otherwise.

Despite a compete-risk setting, we thus compare bankruptcy to all the other outcomes (censuring, voluntary shut-down, economic improvement) combined. Upon modeling the filing for bankruptcy of firms for example, we consider firms that are better off after few months as censored. They leave our sample. It is the same for firms that enter our sample and with no event until the end of the study period. To check how strong this assumption is, we have decided to test the effect of échevinage on all possible outcomes (see in Appendix 7.2). Less than 0.1% of the firms are voluntary shut-down (19 firms in our sample). We assume their effects is non-significant. Around 18% of the firms in our sample are better off after some time. But looking at the cumulative incidence functions (see figure 1), firms are not affected by their location in or outside Alsace-Moselle since the two curves are juxtaposed.

In the second stage of our modeling, we consider all liquidations whether they happen at the tile of filing or afterwards, despite the firm being engaged into reorganisation. A sale as a going concern is also treated as a liquidation. This models the ability of the court to reallocate misused capital through the liquidation process. We consider only two states "being at risk" and "being liquidated" as in a simple survival model. The model is more straightforward than the previous one. The estimation is still based on a piece-wise constant hazard ratio with the same time dummies as previously.

The first condition to observe a timely process is to consider a point in time where the firms become at risk. Since we follow firms using bankruptcy risk derived by a failure score, we cannot use information before March 2011.

To do so and prevent our sample from left truncation, we define "at risk" firms that suffer from an increase in their bankruptcy risk. The Altares-D&B score is summarized in 20 risk-buckets. A firm enters our sample when its score rating drops from at least one risk-bucket.

The hazard ratio h i,s,t is the probability for a firm to change from being "at risk" until time t to a certain state s precisely at time t. We study mainly three changes of state : filing for bankruptcy, being accepted to reorganise, and being liquidated. The hazard ratio is composed of two parts: a function of time, and an exponential form that includes all the firm characteristics we want to control for. Because we have monthly observations, we choose a discrete-survival time model with a piece-constant hazard. This means that the effect of time is the same for all firms that experienced a change of state after a same period of time. We study changes of states between April 201122 and April 2012. Observations from data show that the impact of time remains nearly constant after six months being at risk. We thus limit our time function to six occurrences: one for each month between the first month after the firm becomes at risk and the fifth and then a last occurrence ranging from the sixth month onward. We thus estimate:

h i,s,t = h 0 (t) exp(β * Échevinage + δ * Controls + i ) where h 0 (t) = 6 k=1 1 t=k

Alsace-Moselle as an identifying strategy

Chemin and Wasmer, 2009 use differences between Alsace-Moselle and the rest of France to measure the increase of employment after a decrease in maximum working hours. By doing so, they provide a list of the main drawbacks in using such comparison and in particular the vicinity of Germany with Alsace-Moselle. We thus decide to take into account how firms may differ the further we go from the administrative border because of this vicinity. To do so, we compare our overall results with a sub-sample of firms in a buffer zone around this separation. We build up our sample by creating quartiles in each area depending on the distance between the administrative border and the firm's location. Our sub-sample is only composed of the nearest quartile to the line.

In this chapter, we want to test the efficiency of the court on the decisions to file and on how the firms are treated along bankruptcy. It is possible that in Alsace-Moselle, debtors and creditors are more or less keen to accept out-of-court settlement compared to the rest of France. To ensure that the firms have no other alternative than filing for bankruptcy, we create another subsample with only the firms with that are in the highest bankruptcy risk bucket (very high risk ) before entering our sample23 . Considering this subsample is more convenient than including an interaction term. It allows differences in magnitude in the coefficients of the other variables. Otherwise we could not control potential structural discrepancies in the number of high risk firms within both sides of the administrative border. The signs of the coefficients may also differ for control variables such as the dummies for the business activity. For example, old mining industry in Alsace or construction firms that may be more at risk in less profitable area.

We reproduce these two sub-samples when we model endogeneity in the firm's location. The choice of location should indeed depend on the bankruptcy risk that the firm is facing. As soon as the bankruptcy risk exceeds a certain threshold, entrepreneurs would be better off outside Alsace-Moselle since they would rather have their firms reorganised. Yet, knowing this, creditors would rather finance firms in Alsace-Moselle where they would be less forced to agree upon reorganisation of firms, that is where they have less chances of being forced into negotiation over their exposures. We assume here that creditors have a liquidation bias : if a firm goes bankrupt, they would be better off after a liquidation than being forced to reorganise their credit towards it. Most empirical papers agree on this bias (see for example [START_REF] Blazy | un)secured debt and the likelihood of court-supervised reorganization[END_REF]. We use an instrumental variable, property tax which should give incentives for many firms to choose a location, because of their owner or because of their employees. Its effects on the risk of bankruptcy is small. We model this decision of the location of the firm with a 2SLS model which first models the location then the survival, assuming we can replace the logit model of time-discrete survival with a linear probability model. We assume it is is a first good approximation to tackle this possible endogeneity issue.

Main results

As mentioned above, we use the overall sample plus two subsampless to check for the effect of échevinage. Each of our estimation compares the same model for all the observations, then for the firms that are the nearest to the administrative border; and last for the firms belonging to the very high risk bucket before their rating decreased.

Filing for bankruptcy and filing for reorganisation

In table 4, we compare the filing for bankruptcy with the two other potential outcomes: decrease in the firm bankruptcy risk and the decision to simply shut down the firm24 . We provide our estimations for all the other outcomes in the Appendix. We then provide in Table 5 the chances to be reorganised in a Redressement Judiciaire for all the firms at risk25 .

All financial variables have expected coefficients and their coefficients are consistent across the three samples when significant. Meanwhile most financial ratios have non-significant coefficients. Profitability has a negative (as expected) and significant value. The more the firms are profitable, the more chances they have to avoid bankruptcy. It is especially true in the last subsample where the impact of profitability decreases (from -1.1% to -0.6%) with firms having less chance to be better off. The estimated risk plays a key role in explaining the decision to file for bankruptcy. It is also the case for the age of the firm : the older the firm, the less chance to file for bankruptcy when at risk. The younger firms must have less ability to recover when distressed. Older firms can ask for delays with their business partners or their banks.

The effect of mixed courts appears obvious on the first and third column.

The coefficient decreases from -0.24 to -0.30 between the two columns.

Firms with the most chances to file for bankruptcy should delay more their filing in Alsace-Moselle. In our first subsample, restricting to firms that are the closest to the administrative border, the coefficient is of the same magnitude but no longer significant.

The strong impact of our échevinage variable questions ex-ante efficiency of mixed courts : we wonder whether this delay is explained by a different bankruptcy policy between mixed and lay courts. We look at the results in Table 5 when we model only the filing for reorganisation (excluding liquidation) for the firms that file for bankruptcy looking at all the firms that are at risk. Due to the narrow time period, the estimation of this risk can only be limited to just a few observations (157 reorganisations over the whole sample). The coefficient associated with échevinage is strongly negative in all samples. When looking only at the closest firms to the administrative border in Table 4, the coefficient of échevinage remains at the same level but its significance level drops. This result questions the contrasts between the two areas, we could fear that our other results only reveal on structural differences between firms in the two regions. The results in Table 5 show that mixed court also plays a significant effect on the filing for reorganisation also in this subsample. The order of magnitude is in line with the one on the overall sample. The effect is once again higher for the sample with only high bankruptcy risk firm.

We must link this result with the one found in our previous regression on the impact of mixed courts on filing. Knowing they have fewer chances to be reorganised, they may hope for a reversal of their economic situation, and thus delay filing for bankruptcy. Because of fewer chances to be reorganised, courts in Alsace-Moselle incite firms to delay decisions in filing. This could lead to more failures in reorganisation: the firm could wait too long in an attempt to be reorganised leading to higher overall liquidation rate in mixed courts.

The coefficient of the estimated risk is also very strong in explaining filing for reorganisation. The rating and thus the estimated risk are indeed a good summary of the situation of the firm before the filing. And many papers such as [START_REF] Radulovic | The effect of section 363 sales on recovery rates: allowing for self-selection bias[END_REF] and [START_REF] Blazy | Employment preservation vs. creditors' repayment under bankruptcy law: the french dilemma?[END_REF] have already shown that the previous financial situation of the firm is the main driver of its fate in bankruptcy. The other financial variables and the profitability do not disoplay significant coefficient for the most part. The number of employees has a strong significant effect on the whole sample but its effect becomes non-significant on our two subsampless. As such, in the third column where we restrict our sample to very high risk firms, the magnitude and significance of the estimated risk drops while the coefficient of size -measured as total assets -becomes strongly positive and significant. It is usual for the relationship between size and bankruptcy to be positive as we control for profitability. Larger firm will attempt to reorganise.

Success of reorganisation and screening non-viable firms

We have shown that lay courts have a stronger "reorganisation-policy" than their mixed counterparts. Our second question is thus to check how thes two policies have effects on the success of reorganisation and bankruptcy in general, depending on the type of courts. We assume that the differences between mixed and lay courts may be linked with differences in their screening of non-viable firms.

Mixed courts may discourage viable firms to file for bankruptcy because of fewer chances of a reorganisation proceeding. Doing so, they could delay the filing for reorganisation of firms so much that these firms end up being too distressed to have a successful reorganisation. Meanwhile, lay courts could allow for too many firms to be reorganised even if they are not viable.

To test these questions, we model the failures in reorganisation process, that is reorganisation which end up being converted to liquidation (Table 6).

The results in Table 6 show that mixed courts do not harm the reorganisation process by delaying too much entry for viable firms. Rather than implying an increase in type II errors, i.e. allowing reorganisation for firms that would be liquidated in the end, mixed courts tend to have fewer failures when they agreed on the reorganisation. But this conclusion must be mitigated. The coefficients are hard to interpret because of their magnitude and the complete absence of significance. We can still rule out that the ex-ante fewer chances of reorganisation do not preclude the process to succeed.

Two sub-questions follow. Does the fact that lay courts tend to reorganise more often prevent them to liquidate reorganised firms that appear nonviable? If so, is there a persistence in potential type II errors from these courts ? On the other hand, does the lower reorganisation chance in mixed courts prevent them from liquidating non-viable firms out of the market?

Managers and shareholders may be incited to delay their entry in bankruptcy as much as they can, resulting in lessened overall liquidation rates.

To answer the above questions we compare overall liquidation, either directly at filing or once the firm has failed to reorganise. We use otherwise the same model as before and the results are reported in Table 7. Looking at the sign of the coefficient of the échevinage variable, mixed courts look like they ensure overall less frequent liquidation. The coefficient is stable over the whole sample and the subsamples. But the absence of significance and the magnitude of their standard deviation is most probably explained by the 20 lack of differences between the two types of courts.

We conclude that there is no over-liquidation after reorganisation in lay courts; but also that the mixed-courts policy does not harm the bankruptcy process in liquidating viable firms. Type-I errors are limited by the ability of both courts to liquidate firms through the whole bankruptcy process.

Conclusion

This chapter concludes with contrasted results. Though lay courts are more appealing ex-ante due to their reorganisation rates, they do not provide less overall liquidation (direct and after the filing) of distressed firms. The main difference between the types of courts, according to our results, is the way they deal with bankrupt firms: i) lay courts giving more time to firms during an observation period, while demonstrating their ability to prevent maintaining zombie firms as shown by their overall liquidation rate ; ii) mixed courts screen firm more harshly on filing, examining their financial statement but do not "over-liquidate" firms. To some extent, we could analyse these two courts' structures as being more or less reorganisation-oriented given a same bankruptcy law. And we see that the consequences of this conclusion depends on the creditors' reaction.

Our results are nonetheless lacking because of the absence of recovery rates for the creditors and follow-up of the entrepreneurs. Further research should build on these two subjects, how much our results affect credit conditions, and in particular interest rates, but also business creation. Both effects should be difficult to disentangled.

We use the French system to compare both lay courts and mixed courts.

Throughout the world, most bankruptcy courts are composed only of legal professionals. It would thus be all the more interesting to check whether we can derive similar results as in mixed courts, even if evidence has been provided that mixed courts with lay judges do not obviously differ from professional judges (see [START_REF] Philippe | Do jurors and professional judges differ in their treatment of crime?: evidence from french reform[END_REF]. This requires much anticipation by the firm.The court will appoint a judicial administrator to supervise or assist the debtor company's management in the drawing up of the safeguard plan.

When a firm becomes insolvent27 either creditors or debtors can ask for the filing for bankruptcy. Before 2012, the court could also decide for the firm to file for bankruptcy. When a debtor or a creditor seizes the court, the choice between the proceedings is made by the court only using the information at the time of the filing. After the firm has filed for bankruptcy, the debtor company is allowed a stay of payments and proceedings.

In both reorganisation proceedings, if the court considers that the business may be continued as a going concern, it will order an "observation period " that can be last for up to 18 months. In practice, it is common for reorganisation to last 24 months before a reorganisation plan is agreed upon. Despite these regular meetings, the reorganisation process can be interrupted at any time if the firm is deemed non-viable and then processed toward liquidation.

A court-appointed judicial administrator investigates the affairs of the debtor and make proposals for the reorganisation of its business. A creditors' representative in charge of collecting statements of claims and verifying the debtor's liabilities is also appointed. Members of the creditors' committee may also present their own alternative safeguard plan. While the two reorganisation proceedings mostly differ on the magnitude of the financial distress, Sauvegarde is a Chapter 11-inspired process where managers remain on charge of the firm's activity. Yet it is rarely used, only 2% of bankrupt firms file for this proceeding every year28 .

A debtor company that is insolvent must apply for the opening of insolvency proceedings within 45 days of the occurrence of cash-flow insolvency, unless it has requested the appointment of a conciliator or the opening of liquidation proceedings. At the end of the observation period, the court will make an order either for either (i) the continuation of the debtor's operations by way of a reorganisation plan; or (ii) the sale as a going concern or (iii) failing, the liquidation of the debtor company. More than 70 % of reorgani-sation filings ended up being liquidated afterwards in 2010 29 . In our chapter we regroup both liquidation and sale as going concern since they are both failures to reorganise. The table displays information on the dependent and control variables used in the tests. The risk variables contain the distribution in risk buckets, from very low to very high bankruptcy risk over the next twelve months. We also computed the estimated probability of bankruptcy derived with the firm scoring as decided when the scoring was implemented. The profitability ratio (Profit as a share of Sales) was cut on its first and last centile because of its effect on the mean value. We have checked it has no further impact on our model estimation. The table displays information on the dependent and control variables used in the tests for the closest firm to the administrative line. The risk variables contain the distribution in risk buckets, from very low to very high bankruptcy risk over the next twelve months. We also computed the estimated probability of bankruptcy derived with the firm scoring as decided when the scoring was implemented. The profitability ratio (Profit as a share of Sales) was cut on its first and last centile because of its effect on the mean value. We have checked it has no further impact on our model estimation.

( The table displays information on the dependent and control variables used in the tests for the firms the most at bankruptcy risk. The risk variables contain the distribution in risk buckets, from very low to very high bankruptcy risk over the next twelve months. We also computed the estimated probability of bankruptcy derived with the firm scoring as decided when the scoring was implemented. The profitability ratio (Profit as a share of Sales) was cut on its first and last centile because of its effect on the mean value. We have checked it has no further impact on our model estimation.

( This table provides an evaluation of échevinage on the sample and the two subsamples (closest to administrative line and very high risk). We add the same controls as those described in Table 1, business activity and legal form.

We compare filing with the other two possible outcomes: firm's shut down and decrease in bankruptcy risk. We do not provide the coefficients for the time dummies.

(

2. 1

 1 History of French bankruptcy/commercial courts Bankruptcy courts date back to the 15th century in France. They are first created due to the economic vitality of commercial fairs and the need to regulate conflicts between merchants in a fast way but also knowing the customs of each business activity. These two challenges drove the creation of the inspiring consular justice in Italy. Commercial courts start to appear in France in 1419 in Lyon, 1549 in Toulouse, 1536 in Rouen. The key year for bankruptcy courts is generally set to 1563. Under the impulse of the chancellor Michel de L'Hospital, Charles IX gives a royal edict which allows every city to have its bankruptcy court and creates the Parisian commercial court 15 . This royal edict first gives a legal framework inspired by local organisations. It sets the rules to elect the consular judges asking for merchants to rule benevolently. In 1673, Colbert extends commercial courts to the whole French territory. In 1721, there are already 73 courts 16 . Subsequently, in the XVIII th century, bankruptcy needs to be filed under ordinary justice, while debt inventory is done by consular judges. The French revolution maintains consular justice in 1790 and allows each French department to create commercial courts where they are deemed needed. The 1807 Code of Commerce is another milestone for commercial justice in France. In the article 615, the number and location of commercial courts is left to public administration. The Prussian victory over France leads to the annexation of Alsace-Moselle. Commercial courts are replaced as described by the Empire law of the 27th of January, 1877. Business disputes are given to regional courts consisting of a professional judge as president and two non-professional judges (Handelsrichter ) 17 . The latter are inspired by the French model of a specialised commercial justice.

  important. The 2016 reform in Justice lead to mandatory training starting November 2018 : 8-day initial training then 2 days per year. Professional judges consider that this training is not enough with a commercial law piling many different legal area (labour, finance, commercial per se) in such a short amount of time relative to their legal training.

20

  See Esquerre, 2014 for the breakdown by size. 21 Doubs, Meurthe-et-Moselle, Meuse, Haute-Saône, Vosges and Territoire de Belfort.

29

  Source :[START_REF] Battle | L'entreprise en difficulté en france. la fracture économique, Étude Deloitte Altares[END_REF]

Figure 2 -

 2 Figure 2 -Cumulative Incidence function on filing for bankruptcy

Table 1 -

 1 Summary statistics for all observations at risk

Table 2 -

 2 Summary statistics for sample A

Table 3 -

 3 Summary statistics for firms with very high bankruptcy risk

Table 4 -

 4 Modeling filing for bankruptcy

  Filing for reorganisation and risk of liquidation afterward

		1)	(2)	(3)
		All obs.	Low distance	High BR
	échevinage (1=yes)	-0.235 *	-0.239	-0.302 *
		(0.033)	(0.180)	(0.017)
	Estimated risk (%)	0.028 * * *	0.023 * * *	0.023 * * *
		(0.000)	(0.000)	(0.000)
	Log(1+size of assets)	-0.132	-0.156	0.021
		(0.061)	(0.195)	(0.815)
	Profitability (%)	-0.011 * * *	-0.013 * * *	-0.006 *
		(0.000)	(0.001)	(0.026)
	Log(1+sales)	0.144	0.200	0.112
		(0.108)	(0.173)	(0.316)
	Log(1+age)	-0.397 * * *	-0.357 * * *	-0.201 *
		(0.000)	(0.001)	(0.012)
	Log(1+nbr of empl.)	0.161	-0.015	0.037
		(0.068)	(0.918)	(0.722)
	Constant	-4.446 * * *	-5.382 * * *	-5.787 * * *
		(0.000)	(0.000)	(0.000)
	Controls		Yes
	Observations	26, 719	9, 134	13, 254
	Events	349	131	317

p-values in parentheses * p < 0.05, * * p < 0.01, * * * p < 0.001 33 7.2

Table 5 -

 5 Modeling filing for reorganisationThis table provides an evaluation of échevinage on the sample and the two subsamples (closest to administrative line and very high risk). We add the same controls as those described in Table1, business activity and legal form. -values in parentheses * p < 0.05, * * p < 0.01, * * * p < 0.001 34

	We compare filing with the other two possible outcomes: firm's shut down
	and decrease in bankruptcy risk
		(1)	(2)	(3)
		All obs.	Low distance	High BR
	Échevinage (1=yes)	-0.788 * * *	-0.637 *	-1.018 * * *
		(0.000)	(0.017)	(0.000)
	Estimated risk (%)	0.031 * * *	0.027 * * *	0.025 * * *
		(0.000)	(0.000)	(0.000)
	Log(1+size of assets)	0.185	0.170	0.339 * *
		(0.051)	(0.204)	(0.004)
	Profitability (%)	0.000	0.000	0.000
		(0.208)	(0.319)	(0.350)
	Log(1+sales)	-0.064	-0.144	-0.023
		(0.535)	(0.373)	(0.864)
	Log(1+age)	-0.410 * * *	-0.326 *	-0.179
		(0.000)	(0.048)	(0.128)
	Log(1+nbr of empl.)	0.248 *	0.096	0.042
		(0.031)	(0.621)	(0.763)
	Constant	-6.287 * * *	-5.306 * *	-8.525 * * *
		(0.000)	(0.003)	(0.000)
	Controls		Yes
	Observations	26, 719	9, 134	13, 254
	Events	157	61	142

p

Table 6 -

 6 Modeling failures in reorganisationThis table provides an evaluation of échevinage after a firm reorganisation was accepted by the Court and it finally fails. It is based on the whole sample and the two subsamples (closest to administrative line and very high risk).We add the same controls as those described in Table1, business activity and legal form. We compare filing with the other two possible outcomes: firm's shut down and decrease in bankruptcy risk -values in parentheses * p < 0.05, * * p < 0.01, * * * p < 0.001

		(1)	(2)	(3)
		All obs.	Low distance	High BR
	Échevinage (1=yes)	-0.399	-0.183	-0.551
		(0.200)	(0.723)	(0.116)
	Estimated risk (%)	0.013 *	0.035 * * *	0.012 *
		(0.015)	(0.000)	(0.035)
	Log(1+size of assets)	0.405 *	0.558	0.459
		(0.049)	(0.069)	(0.067)
	Profitability (%)	-0.011	-0.007	-0.016
		(0.135)	(0.582)	(0.059)
	Log(1+sales)	-0.129	-0.494	-0.265
		(0.588)	(0.134)	(0.380)
	Log(1+age)	-0.339 *	-0.570	-0.300
		(0.045)	(0.077)	(0.141)
	Log(1+nbr of empl.)	-0.098	-0.035	-0.142
		(0.662)	(0.911)	(0.597)
	Constant	-6.607 *	-0.944	-5.099
		(0.038)	(0.822)	(0.134)
	Controls		Yes
	Observations	157	61	142
	Events	58	25	53
		35

p

Table 7 -

 7 Modeling overall liquidationThis table provides an evaluation of échevinage on the sample and the two subsamples (closest to administrative line and very high risk). We add the same controls as those described in Table1, business activity and legal form. -values in parentheses * p < 0.05, * * p < 0.01, * * * p < 0.001

	We compare filing with the other two possible outcomes: firm's shut down
	and decrease in bankruptcy risk
		(1)	(2)	(3)
		All obs.	Low distance	High BR
	Échevinage (1=yes)	-0.062	-0.072	-0.080
		(0.639)	(0.729)	(0.598)
	Estimated risk (%)	0.027 * * *	0.025 * * *	0.021 * * *
		(0.000)	(0.000)	(0.000)
	Log(1+size of assets)	-0.129	-0.112	0.014
		(0.096)	(0.417)	(0.887)
	Profitability (%)	0.000 * * *	0.000	0.000 * * *
		(0.000)	(0.332)	(0.000)
	Log(1+sales)	-0.094	-0.097	-0.082
		(0.288)	(0.483)	(0.437)
	Log(1+age)	-0.445 * * *	-0.555 * * *	-0.273 * *
		(0.000)	(0.000)	(0.006)
	Log(1+nbr of empl.)	0.274 *	0.258	0.111
		(0.012)	(0.145)	(0.388)
	Constant	-2.125 *	-1.900	-3.744 * *
		(0.026)	(0.196)	(0.002)
	Controls		Yes
	Observations	26, 719	9, 134	13, 254
	Events	230	88	211

p

The French Commercial code states that bankruptcies must first safeguard employment, then promote business viability and last ensure debt collection.

Both arguments are stressed by Lazega and Mounier, 2009 following their interviews with Parisian consular judges.

Decret number 2018-664, 27 th July 2018.

See namely[START_REF] Deffains | Analyse économique de l'échevinage dans la justice commerciale[END_REF]

As threats also, see[START_REF] Vauchez | La justice face à ses réformateurs (1980-2006): entreprises de modernisation et logiques de résistance[END_REF] for more information on the failures of both 1985 and 2001 attempts to reform the status of bankruptcy judges in France.

It is similar to the cram-down procedure in the US Chapter 11.

As noted by[START_REF] Jean | Le modèle français des tribunaux de commerce peutil (et doit-il) être réformé?[END_REF]

We use the work of[START_REF] Coutant | Les tribunaux de commerce[END_REF] to build this historical perspective.

Article 100 of the organization law of the 27, January

This part was complete with the work of[START_REF] Strickler | La particularité de l'alsace-moselle[END_REF]

Except for the residing president of the court who can be reelected a fifth time.

Even though we have information starting March 2011, we study firm with an increase in risk, thus firms cannot enter our sample before April.

Their 20-buckets score is below 8, which means that they have a 2.56% chance to file for bankruptcy within the next 12 months. It is nearly four times more chances than the entire sample when the score was created (average of 0.71%).

Let us recall that the difference between this decision and filing for liquidation depends on the absence of unpaid creditors.

We focus only on this proceeding because of the very small number of filings in Sauvegarde which is usual in France.

Source: author's computation from Altares-D&B data.

As defined in art. 620-1 and following of the French Commercial Code, the cessation de paiement is a vague definition when a firm cannot pay the due liabilities. This can give power to the court to record insolvency or delay filing.

Source: author's computation from Altares-D&B data.

Appendix

French bankruptcy law

As of 2016, Firms that file for bankruptcy can decide between three proceedings : two reorganisation ones (Sauvegarde and Redressement Judiciaire) and a liquidation one (Liquidation Judiciaire). The latter is similar to the US Chapter 7 and only consists in ensuring debt collection by creditors. Like in the US, most firms are eventually liquidated. Overall, two-thirds of bankrupt firms file for direct liquidation 26 .

Only the legal representatives of a company can file for Sauvegarde, a solvent reorganisation proceedings, if the firm is not yet cash-flow insolvent.