{"id":15022318,"url":"https://github.com/php/pecl-search_engine-solr","last_synced_at":"2025-04-05T22:06:25.265Z","repository":{"id":13981918,"uuid":"16682782","full_name":"php/pecl-search_engine-solr","owner":"php","description":"The Apache Solr PHP extension is an extremely fast, light-weight, feature-rich library that allows PHP applications to communicate easily and efficiently with Apache Solr server instances using an object-oriented API.","archived":false,"fork":false,"pushed_at":"2024-12-30T15:16:55.000Z","size":1890,"stargazers_count":60,"open_issues_count":9,"forks_count":40,"subscribers_count":17,"default_branch":"master","last_synced_at":"2025-03-29T16:22:54.718Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://pecl.php.net/package/solr","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/php.png","metadata":{"files":{"readme":"README.ABOUT_SOLR_EXTENSION","changelog":"NEWS","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2014-02-10T03:04:19.000Z","updated_at":"2025-01-02T15:20:46.000Z","dependencies_parsed_at":"2023-01-11T20:21:34.675Z","dependency_job_id":"7730faae-9166-40cf-a0ce-eb7257a1c02e","html_url":"https://github.com/php/pecl-search_engine-solr","commit_stats":{"total_commits":859,"total_committers":24,"mean_commits":"35.791666666666664","dds":"0.38300349243306175","last_synced_commit":"96b8c32352cf350b705d2b39f7f3a770bed9aad3"},"previous_names":[],"tags_count":34,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/php%2Fpecl-search_engine-solr","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/php%2Fpecl-search_engine-solr/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/php%2Fpecl-search_engine-solr/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/php%2Fpecl-search_engine-solr/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/php","download_url":"https://codeload.github.com/php/pecl-search_engine-solr/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246912435,"owners_count":20853858,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-09-24T19:57:47.262Z","updated_at":"2025-04-05T22:06:25.243Z","avatar_url":"https://github.com/php.png","language":"C","readme":"================================================================================\nIntroducing the Solr PHP Extension\n================================================================================\nThe Solr extension is an extremely fast, light-weight, feature-rich library that\nallows PHP developers to communicate effectively with Solr server instances.\n\nThere are tools to add documents and make updates to the solr server.\n\nIt also contains tools that allows you to build advanced queries to the server\nwhen searching for documents.\n\nThere are also special objects that simplifies the sending of name-value requests\nto the server. This includes the SolrParams class and all its child classes.\n\nThe SolrClient object allows one to communicate with Solr containers that are\nbehind proxy servers or that require HTTP Authentication to proceed.\n\nThe SolrClient constructor accepts options such as\nhttp authentication username and passwor, proxy server name, port, login and\npasswords etc.\n\nUsing an advanced http client like libcurl allows us to leverage the features\navailable with the library. We can reuse the HTTP connections without having\nto create a separate one for each request.\n\n================================================================================\nHow to Install\n================================================================================\n\nPlease refer to the README.INSTALLATION file.\n\n================================================================================\nMagic Methods and Interfaces Implemented\n================================================================================\n\nSolrDocument implements the following interfaces.\n\n(1) ArrayAccess  - to access the fields as array keys using field names.\n(2) Iterator\t - to iterate over the document fields using foreach()\n(3) Serializable - provides custom serialization of the object.\n\nSolrDocument also contains the __get and __set magic methods which allows developers\nto access the fields directly. When setting fields, if the field already\nhas a value the new value will be appended to the list of values for that field.\n\nEach field is a SolrDocumentField object with the following public properties :\n\n(a) name - a string with name of the field.\n(b) boost - a double representing the boost value of the field (intentionally empty)\n(c) values - an array of all the field values as strings.\n\nCustom Serialization\n\nstring SolrDocument::serialize(void) returns an XML document representing a\nSolrDocument as shown below :\n\n\u003c?xml version=\"1.0\" encoding=\"UTF-8\"?\u003e\n\u003csolr_document\u003e\n  \u003cfields\u003e\n    \u003cfield name=\"id\"\u003e\n      \u003cfield_value\u003eA0F43D\u003c/field_value\u003e\n    \u003c/field\u003e\n    \u003cfield name=\"name\"\u003e\n      \u003cfield_value\u003eIsrael Ekpo\u003c/field_value\u003e\n    \u003c/field\u003e\n    \u003cfield name=\"email\"\u003e\n      \u003cfield_value\u003eIsrael.Ekpo@israel.ekpo.com\u003c/field_value\u003e\n    \u003c/field\u003e\n    \u003cfield name=\"skills\"\u003e\n      \u003cfield_value\u003eReading\u003c/field_value\u003e\n      \u003cfield_value\u003eWriting\u003c/field_value\u003e\n      \u003cfield_value\u003eSoccer\u003c/field_value\u003e\n      \u003cfield_value\u003eTeaching\u003c/field_value\u003e\n    \u003c/field\u003e\n    \u003cfield name=\"languages\"\u003e\n      \u003cfield_value\u003eInglés\u003c/field_value\u003e\n      \u003cfield_value\u003eEspanól\u003c/field_value\u003e\n    \u003c/field\u003e\n  \u003c/fields\u003e\n\u003c/solr_document\u003e\n\nHere is a complete example of a serialized SolrDocument object:\n\nC:12:\"SolrDocument\":679:{\u003c?xml version=\"1.0\" encoding=\"UTF-8\"?\u003e\n\u003csolr_document\u003e\n  \u003cfields\u003e\n    \u003cfield name=\"id\"\u003e\n      \u003cfield_value\u003eA0F43D\u003c/field_value\u003e\n    \u003c/field\u003e\n    \u003cfield name=\"name\"\u003e\n      \u003cfield_value\u003eIsrael Ekpo\u003c/field_value\u003e\n    \u003c/field\u003e\n    \u003cfield name=\"email\"\u003e\n      \u003cfield_value\u003eIsrael.Ekpo@israel.ekpo.com\u003c/field_value\u003e\n    \u003c/field\u003e\n    \u003cfield name=\"skills\"\u003e\n      \u003cfield_value\u003eReading\u003c/field_value\u003e\n      \u003cfield_value\u003eWriting\u003c/field_value\u003e\n      \u003cfield_value\u003eSoccer\u003c/field_value\u003e\n      \u003cfield_value\u003eTeaching\u003c/field_value\u003e\n    \u003c/field\u003e\n    \u003cfield name=\"languages\"\u003e\n      \u003cfield_value\u003eInglés\u003c/field_value\u003e\n      \u003cfield_value\u003eEspanól\u003c/field_value\u003e\n    \u003c/field\u003e\n  \u003c/fields\u003e\n\u003c/solr_document\u003e\n}\n\nOne of the items on my todo list is to create a response writer to return\nserialized SolrDocument objects instead of document arrays.\n\nSolrDocument::unserialize(string $serialized) accepts an XML document\nrepresenting the SolrDocument object. It will the bring the object back to live.\n\nThe SolrDocument class also has the method SolrDocument::getInputDocument() to\nallow one do get the SolrInputDocument version of a SolrDocument instance.\n\nThis method may be helpful if one needs to resubmit the document to the server to\nupdates.\n\nThe Solr extension has the SolrQuery object (a child of SolrParams) that enables\nthe developer to send custom advanced name-value requests to the solr server.\n\nThe SolrQuery object can also be serialized and reused later, which makes it very\nhelpful to saving the state of the application across multiple requests. This may be\nvery useful in cases such as facet browsing where additional parameters may need to be\nadded to the current object or removed from it to get the desired results without\nhaving to start over from scratch.\n\n================================================================================\nParsing of XML Responses from the Solr Server\n================================================================================\nXML responses from the solr server are expected to be formatted using version 2.2\nThese xml documents are parsed into serialized php code and returned as\nread-only SolrObject instances whose properties can also be accessed as array\nkeys in addition to being accessible directly via the object-\u003emember notation.\n\nHaving the properties accessible via object[member] notation is helpful in cases\nwhere the property name is not valid (contains dots and other characters not\nlegal in php.\n\n================================================================================\nHow to Report Bugs\n================================================================================\n\nPlease report bugs to http://bugs.php.net\n\nIf you experience a crash due to a segmentation fault, please follow the instructions on the link below\nto get a gdb backtrace and then submit the trace in your bug report as well\n\nhttp://bugs.php.net/bugs-generating-backtrace.php\n\nThank you for using PHP\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphp%2Fpecl-search_engine-solr","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fphp%2Fpecl-search_engine-solr","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphp%2Fpecl-search_engine-solr/lists"}