mirror of
https://github.com/ail-project/ail-framework.git
synced 2025-09-07 15:42:39 +00:00
chg: [ail sync server] add server controller + list connected clients ail_uuid->sync_modes
This commit is contained in:
parent
a1768e50da
commit
57f5afe831
4 changed files with 162 additions and 24 deletions
|
@ -56,8 +56,11 @@ def ail_2_ail_dashboard():
|
|||
ail_uuid = ail_2_ail.get_ail_uuid()
|
||||
l_servers = ail_2_ail.get_all_running_sync_servers()
|
||||
l_servers = ail_2_ail.get_ail_instances_metadata(l_servers)
|
||||
l_clients = ail_2_ail.get_server_all_connected_clients()
|
||||
l_clients = ail_2_ail.get_ail_instances_metadata(l_clients, sync_queues=False, client_sync_mode=True)
|
||||
return render_template("ail_2_ail_dashboard.html", ail_uuid=ail_uuid,
|
||||
l_servers=l_servers)
|
||||
l_servers=l_servers,
|
||||
l_clients=l_clients)
|
||||
|
||||
######################
|
||||
# #
|
||||
|
|
|
@ -84,6 +84,44 @@
|
|||
</tbody>
|
||||
</table>
|
||||
|
||||
|
||||
<h1>Connected Clients:</h3>
|
||||
|
||||
<table id="table_servers" class="table table-striped border-primary">
|
||||
<thead class="bg-dark text-white">
|
||||
<tr>
|
||||
<th>uuid</th>
|
||||
<th>url</th>
|
||||
<th>description</th>
|
||||
<th>sync mode</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody style="font-size: 15px;">
|
||||
{% for dict_server in l_clients %}
|
||||
<tr class="border-color: blue;">
|
||||
<td>
|
||||
<a href="{{ url_for('ail_2_ail_sync.ail_server_view') }}?uuid={{ dict_server['uuid'] }}">
|
||||
{{ dict_server['uuid']}}
|
||||
</a>
|
||||
</td>
|
||||
<td>{{ dict_server['url']}}</td>
|
||||
<td>{{ dict_server['description']}}</td>
|
||||
<td class="text-center">
|
||||
{% if dict_server['client_sync_mode']['api'] %}
|
||||
API
|
||||
{% endif %}
|
||||
{% if dict_server['client_sync_mode']['pull'] %}
|
||||
PULL
|
||||
{% endif %}
|
||||
{% if dict_server['client_sync_mode']['push'] %}
|
||||
PUSH
|
||||
{% endif %}
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue