Commit 2ce6c6e9 authored by Victor Toso's avatar Victor Toso
Browse files

jamendo: remove due API change v2->v3

We should port to v3. Disabling in the meanwhile.
Related: #76
parent e880c368
......@@ -117,7 +117,6 @@ plugins = [ # NAME, REQ_DEPS, OPT_DEPS
['flickr', [grilo_net_dep, libxml_dep, oauth_dep], [goa_dep]],
['freebox', [grilo_pls_dep, avahi_client_dep, avahi_glib_dep, avahi_gobject_dep], []],
['gravatar', [], []],
['jamendo', [grilo_net_dep, libxml_dep], []],
['local-metadata', [gio_dep, libmediaart_dep], []],
['lua-factory', [lua_dep, libarchive_dep, grilo_net_dep, json_glib_dep, libxml_dep], [goa_dep, totem_plparser_mini_dep]],
['magnatune', [sqlite3_dep, grilo_net_dep], []],
......
......@@ -7,7 +7,6 @@ option('enable-filesystem', type: 'combo', choices: [ 'auto', 'yes', 'no' ], val
option('enable-flickr', type: 'combo', choices: [ 'auto', 'yes', 'no' ], value: 'auto', description: 'Enable Flickr plugin')
option('enable-freebox', type: 'combo', choices: [ 'auto', 'yes', 'no' ], value: 'auto', description: 'Enable Freebox plugin')
option('enable-gravatar', type: 'combo', choices: [ 'auto', 'yes', 'no' ], value: 'auto', description: 'Enable Gravatar plugin')
option('enable-jamendo', type: 'combo', choices: [ 'auto', 'yes', 'no' ], value: 'auto', description: 'Enable Jamendo plugin')
option('enable-local-metadata', type: 'combo', choices: [ 'auto', 'yes', 'no' ], value: 'auto', description: 'Enable Local Metadata plugin')
option('enable-lua-factory', type: 'combo', choices: [ 'auto', 'yes', 'no' ], value: 'yes', description: 'Enable Lua Factory plugin')
option('enable-magnatune', type: 'combo', choices: [ 'auto', 'yes', 'no' ], value: 'auto', description: 'Enable Magnatune plugin')
......
Get global database and work locally
====================================
Actually all queries are on-line. But the whole database can be retrieved and
stored in local, so all operation can be performed off-line.
Doing it requires to implement the search in local. We should explore if either
moving to this approach or even creating a new derivative plugin that follows
this off-line approach worths it.
Implement childcount
====================
Implementing childcount would require, for each result doing another search and
retrieve all children, counting them.
Limit search-rate
=================
Jamendo terms of use states that applications should be limited to 1 query per
second. Some kind of control should be needed in the plugin.
Limit requested elements
========================
User can request any arbitrary number of elements, and this request is propagated to Jamendo.
Nevertheless, it would be better to break the request in smaller chunks, so
though user requests, for instance, 1000 albums, we do the query in steps of 25
elements.
This diff is collapsed.
/*
* Copyright (C) 2010 Igalia S.L.
*
* Contact: Iago Toral Quiroga <itoral@igalia.com>
*
* Authors: Juan A. Suarez Romero <jasuarez@igalia.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License
* as published by the Free Software Foundation; version 2.1 of
* the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
* 02110-1301 USA
*
*/
#ifndef _GRL_JAMENDO_SOURCE_H_
#define _GRL_JAMENDO_SOURCE_H_
#include <grilo.h>
#define GRL_JAMENDO_SOURCE_TYPE \
(grl_jamendo_source_get_type ())
#define GRL_JAMENDO_SOURCE(obj) \
(G_TYPE_CHECK_INSTANCE_CAST ((obj), \
GRL_JAMENDO_SOURCE_TYPE, \
GrlJamendoSource))
#define GRL_IS_JAMENDO_SOURCE(obj) \
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), \
GRL_JAMENDO_SOURCE_TYPE))
#define GRL_JAMENDO_SOURCE_CLASS(klass) \
(G_TYPE_CHECK_CLASS_CAST((klass), \
GRL_JAMENDO_SOURCE_TYPE, \
GrlJamendoSourceClass))
#define GRL_IS_JAMENDO_SOURCE_CLASS(klass) \
(G_TYPE_CHECK_CLASS_TYPE((klass), \
GRL_JAMENDO_SOURCE_TYPE))
#define GRL_JAMENDO_SOURCE_GET_CLASS(obj) \
(G_TYPE_INSTANCE_GET_CLASS ((obj), \
GRL_JAMENDO_SOURCE_TYPE, \
GrlJamendoSourceClass))
typedef struct _GrlJamendoSource GrlJamendoSource;
typedef struct _GrlJamendoSourcePriv GrlJamendoSourcePrivate;
struct _GrlJamendoSource {
GrlSource parent;
/*< private >*/
GrlJamendoSourcePrivate *priv;
};
typedef struct _GrlJamendoSourceClass GrlJamendoSourceClass;
struct _GrlJamendoSourceClass {
GrlSourceClass parent_class;
};
GType grl_jamendo_source_get_type (void);
#endif /* _GRL_JAMENDO_SOURCE_H_ */
#
# meson.build
#
# Author: Juan A. Suarez Romero <jasuarez@igalia.com>
#
# Copyright (C) 2016 Igalia S.L. All rights reserved.
jamendo_sources = [
'grl-jamendo.c',
'grl-jamendo.h',
]
configure_file(output: 'config.h',
configuration: cdata)
shared_library('grljamendo',
sources: jamendo_sources,
install: true,
install_dir: pluginsdir,
dependencies: must_deps + plugins[jamendo_idx][REQ_DEPS] + plugins[jamendo_idx][OPT_DEPS],
c_args: [
'-DG_LOG_DOMAIN="GrlJamendo"',
'-DHAVE_CONFIG_H',
])
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment